diff options
Diffstat (limited to 'gtk2_ardour')
-rw-r--r-- | gtk2_ardour/editor.cc | 4 | ||||
-rw-r--r-- | gtk2_ardour/editor_canvas.cc | 4 | ||||
-rw-r--r-- | gtk2_ardour/editor_keyboard.cc | 2 | ||||
-rw-r--r-- | gtk2_ardour/editor_mouse.cc | 3 | ||||
-rw-r--r-- | gtk2_ardour/editor_ops.cc | 6 |
5 files changed, 15 insertions, 4 deletions
diff --git a/gtk2_ardour/editor.cc b/gtk2_ardour/editor.cc index eb611ab066..3036bd55d4 100644 --- a/gtk2_ardour/editor.cc +++ b/gtk2_ardour/editor.cc @@ -537,8 +537,8 @@ Editor::Editor (AudioEngine& eng) // GTK2FIX // route_list_display.signal_rows_reordered().connect (mem_fun (*this, &Editor::queue_route_list_reordered)); - // GTK2FIX - // route_display_model->set_sort_func (0, mem_fun (*this, &Editor::route_list_compare_func)); + route_display_model->set_sort_func (0, mem_fun (*this, &Editor::route_list_compare_func)); + route_display_model->set_sort_column (0, SORT_ASCENDING); route_list_scroller.add (route_list_display); route_list_scroller.set_policy (Gtk::POLICY_NEVER, Gtk::POLICY_AUTOMATIC); diff --git a/gtk2_ardour/editor_canvas.cc b/gtk2_ardour/editor_canvas.cc index 8b496f170f..c1762a4149 100644 --- a/gtk2_ardour/editor_canvas.cc +++ b/gtk2_ardour/editor_canvas.cc @@ -441,7 +441,9 @@ Editor::drop_paths (const RefPtr<Gdk::DragContext>& context, double wx; double wy; - track_canvas.window_to_world ( x, y, wx, wy); + track_canvas.window_to_world (x, y, wx, wy); + wx += horizontal_adjustment.get_value(); + wy += vertical_adjustment.get_value(); ev.type = GDK_BUTTON_RELEASE; ev.button.x = wx; diff --git a/gtk2_ardour/editor_keyboard.cc b/gtk2_ardour/editor_keyboard.cc index abc9466af5..43935752f0 100644 --- a/gtk2_ardour/editor_keyboard.cc +++ b/gtk2_ardour/editor_keyboard.cc @@ -47,6 +47,8 @@ Editor::kbd_driver (sigc::slot<void,GdkEvent*> theslot, bool use_track_canvas, b } track_canvas.window_to_world (x, y, worldx, worldy); + worldx += horizontal_adjustment.get_value(); + worldy += vertical_adjustment.get_value(); ev.type = GDK_BUTTON_PRESS; ev.button.x = worldx; diff --git a/gtk2_ardour/editor_mouse.cc b/gtk2_ardour/editor_mouse.cc index 4f93ba65e5..65f1f7a6cb 100644 --- a/gtk2_ardour/editor_mouse.cc +++ b/gtk2_ardour/editor_mouse.cc @@ -103,7 +103,7 @@ Editor::event_frame (GdkEvent* event, double* pcx, double* pcy) position is negative (as can be the case with motion events in particular), the frame location is always positive. */ - + return pixel_to_frame (*pcx); } @@ -1483,6 +1483,7 @@ Editor::motion_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemType item drag_info.current_pointer_frame = event_frame (event, &drag_info.current_pointer_x, &drag_info.current_pointer_y); + if (drag_info.item) { /* item != 0 is the best test i can think of for dragging. diff --git a/gtk2_ardour/editor_ops.cc b/gtk2_ardour/editor_ops.cc index 68baba3061..aa8eec8df3 100644 --- a/gtk2_ardour/editor_ops.cc +++ b/gtk2_ardour/editor_ops.cc @@ -1468,6 +1468,8 @@ Editor::insert_region_list_drag (AudioRegion& region, int x, int y) Playlist *playlist; track_canvas.window_to_world (x, y, wx, wy); + wx += horizontal_adjustment.get_value(); + wy += vertical_adjustment.get_value(); GdkEvent event; event.type = GDK_BUTTON_RELEASE; @@ -3154,8 +3156,12 @@ Editor::mouse_paste () { int x, y; double wx, wy; + track_canvas.get_pointer (x, y); track_canvas.window_to_world (x, y, wx, wy); + wx += horizontal_adjustment.get_value(); + wy += vertical_adjustment.get_value(); + GdkEvent event; event.type = GDK_BUTTON_RELEASE; event.button.x = wx; |