summaryrefslogtreecommitdiff
path: root/gtk2_ardour/editor_mouse.cc
diff options
context:
space:
mode:
authorSampo Savolainen <v2@iki.fi>2008-02-03 20:19:38 +0000
committerSampo Savolainen <v2@iki.fi>2008-02-03 20:19:38 +0000
commit43ccd2d7e59032a573b54fa8ab7db7a2e9128f3b (patch)
tree1538c8401db84f4cc579fba72a61f47f1213ed0b /gtk2_ardour/editor_mouse.cc
parent06d8efc22869100c83ff49d485b1e16334be4ef2 (diff)
Workaround for gui hang when adding gain points (#2048)
git-svn-id: svn://localhost/ardour2/branches/2.0-ongoing@2999 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/editor_mouse.cc')
-rw-r--r--gtk2_ardour/editor_mouse.cc14
1 files changed, 11 insertions, 3 deletions
diff --git a/gtk2_ardour/editor_mouse.cc b/gtk2_ardour/editor_mouse.cc
index a357a2d1ed..a7dd976266 100644
--- a/gtk2_ardour/editor_mouse.cc
+++ b/gtk2_ardour/editor_mouse.cc
@@ -1141,6 +1141,11 @@ Editor::enter_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemType item_
Marker * marker;
double fraction;
+ if (last_item_entered != item) {
+ last_item_entered = item;
+ last_item_entered_n = 0;
+ }
+
switch (item_type) {
case GainControlPointItem:
if (mouse_mode == MouseGain) {
@@ -1156,12 +1161,15 @@ Editor::enter_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemType item_
fraction = 1.0 - (cp->get_y() / cp->line.height());
- set_verbose_canvas_cursor (cp->line.get_verbose_cursor_string (fraction), at_x, at_y);
- show_verbose_canvas_cursor ();
-
if (is_drawable() && !_scrubbing) {
track_canvas.get_window()->set_cursor (*fader_cursor);
}
+
+ last_item_entered_n++;
+ set_verbose_canvas_cursor (cp->line.get_verbose_cursor_string (fraction), at_x, at_y);
+ if (last_item_entered_n < 10) {
+ show_verbose_canvas_cursor ();
+ }
}
break;