summaryrefslogtreecommitdiff
path: root/gtk2_ardour/canvas-note.cc
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2009-07-28 20:51:28 +0000
committerPaul Davis <paul@linuxaudiosystems.com>2009-07-28 20:51:28 +0000
commit3ae28868ff02abf44102fff9954e7e8d6359867f (patch)
tree6202724eba77a9844d9079614c5ea91f91c110e5 /gtk2_ardour/canvas-note.cc
parent5eaf61242f16c7638c0e71a9c82af5a781c24e87 (diff)
remove all MIDI-specific editing modes by making standard work either at object level or within (e.g. notes, etc) ; make tool buttons proxies for GtkActions ; internal sends have their own BufferSet now, instead of using Session ones; don't make internal sends to the monitor bus active when added to the Route
git-svn-id: svn://localhost/ardour2/branches/3.0@5434 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/canvas-note.cc')
-rw-r--r--gtk2_ardour/canvas-note.cc9
1 files changed, 7 insertions, 2 deletions
diff --git a/gtk2_ardour/canvas-note.cc b/gtk2_ardour/canvas-note.cc
index 06234e3e55..f51a58ff5f 100644
--- a/gtk2_ardour/canvas-note.cc
+++ b/gtk2_ardour/canvas-note.cc
@@ -11,16 +11,21 @@ namespace Canvas {
bool
CanvasNote::on_event(GdkEvent* ev)
{
+ PublicEditor& editor (_region.get_trackview().editor());
+
+ if (!editor.internal_editing()) {
+ return false;
+ }
+
double event_x;
static double middle_point, last_x;
Gdk::Cursor cursor;
static NoteEnd note_end;
- Editing::MidiEditMode edit_mode = _region.get_trackview().editor().current_midi_edit_mode();
switch (ev->type) {
case GDK_BUTTON_PRESS:
if (ev->button.button == 2 ||
- (ev->button.button == 1 && edit_mode == Editing::MidiEditResize)) {
+ (ev->button.button == 1 && editor.current_mouse_mode() == Editing::MouseTimeFX)) {
double region_start = _region.get_position_pixels();
event_x = ev->button.x;
middle_point = region_start + x1() + (x2() - x1()) / 2.0L;