mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-16 11:46:25 +01:00
fixes, hopefully, for canvas cursor misbehaviour near/in regionviews
This commit is contained in:
parent
f6129ed0f4
commit
36160b88cd
1 changed files with 18 additions and 6 deletions
|
|
@ -1348,7 +1348,7 @@ Editor::button_press_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemTyp
|
||||||
}
|
}
|
||||||
|
|
||||||
pre_press_cursor = current_canvas_cursor;
|
pre_press_cursor = current_canvas_cursor;
|
||||||
|
|
||||||
_track_canvas->grab_focus();
|
_track_canvas->grab_focus();
|
||||||
|
|
||||||
if (_session && _session->actively_recording()) {
|
if (_session && _session->actively_recording()) {
|
||||||
|
|
@ -1902,6 +1902,17 @@ Editor::enter_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemType item_
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case RegionItem:
|
||||||
|
switch (effective_mouse_mode()) {
|
||||||
|
case MouseRange:
|
||||||
|
set_canvas_cursor (_cursors->selector);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
set_canvas_cursor (which_grabber_cursor());
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
|
||||||
case StartSelectionTrimItem:
|
case StartSelectionTrimItem:
|
||||||
if (is_drawable()) {
|
if (is_drawable()) {
|
||||||
set_canvas_cursor (_cursors->left_side_trim);
|
set_canvas_cursor (_cursors->left_side_trim);
|
||||||
|
|
@ -1926,6 +1937,7 @@ Editor::enter_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemType item_
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|
||||||
case RegionViewName:
|
case RegionViewName:
|
||||||
|
|
||||||
/* when the name is not an active item, the entire name highlight is for trimming */
|
/* when the name is not an active item, the entire name highlight is for trimming */
|
||||||
|
|
@ -2016,7 +2028,7 @@ Editor::enter_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemType item_
|
||||||
line->set_outline_color (0xFF0000FF);
|
line->set_outline_color (0xFF0000FF);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case SelectionItem:
|
case SelectionItem:
|
||||||
if ( get_smart_mode() ) {
|
if ( get_smart_mode() ) {
|
||||||
set_canvas_cursor ();
|
set_canvas_cursor ();
|
||||||
|
|
@ -2920,15 +2932,15 @@ Editor::set_canvas_cursor_for_region_view (double x, RegionView* rv)
|
||||||
Trimmable::CanTrim ct = rv->region()->can_trim ();
|
Trimmable::CanTrim ct = rv->region()->can_trim ();
|
||||||
if (x <= h) {
|
if (x <= h) {
|
||||||
if (ct & Trimmable::FrontTrimEarlier) {
|
if (ct & Trimmable::FrontTrimEarlier) {
|
||||||
set_canvas_cursor (_cursors->left_side_trim);
|
set_canvas_cursor (_cursors->left_side_trim, true);
|
||||||
} else {
|
} else {
|
||||||
set_canvas_cursor (_cursors->left_side_trim_right_only);
|
set_canvas_cursor (_cursors->left_side_trim_right_only, true);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (ct & Trimmable::EndTrimLater) {
|
if (ct & Trimmable::EndTrimLater) {
|
||||||
set_canvas_cursor (_cursors->right_side_trim);
|
set_canvas_cursor (_cursors->right_side_trim, true);
|
||||||
} else {
|
} else {
|
||||||
set_canvas_cursor (_cursors->right_side_trim_left_only);
|
set_canvas_cursor (_cursors->right_side_trim_left_only, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue