From 99b2d9283f5bb1b8d4c2d51438802ce5e9dca5a6 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Wed, 5 Apr 2023 22:02:13 +0200 Subject: [PATCH] Remove incorrect GC translation. This appears not to be necessary, and if present it messes up the scrollbars so that scrolling fully right shows a big empty space at the end of the timeline items. --- src/wx/timeline.cc | 6 ------ 1 file changed, 6 deletions(-) diff --git a/src/wx/timeline.cc b/src/wx/timeline.cc index de83e6ba3..d8e0e692e 100644 --- a/src/wx/timeline.cc +++ b/src/wx/timeline.cc @@ -190,10 +190,6 @@ Timeline::paint_main () ScopeGuard sg = [gc]() { delete gc; }; - int vsx, vsy; - _main_canvas->GetViewStart (&vsx, &vsy); - gc->Translate (-vsx * _x_scroll_rate, -vsy * _y_scroll_rate); - gc->SetAntialiasMode (wxANTIALIAS_DEFAULT); for (auto i: _views) { @@ -219,8 +215,6 @@ Timeline::paint_main () } if (_zoom_point) { - /* Translate back as _down_point and _zoom_point do not take scroll into account */ - gc->Translate (vsx * _x_scroll_rate, vsy * _y_scroll_rate); gc->SetPen(gui_is_dark() ? *wxWHITE_PEN : *wxBLACK_PEN); gc->SetBrush (*wxTRANSPARENT_BRUSH); gc->DrawRectangle ( -- 2.30.2