mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-15 19:16:40 +01:00
Pass whole GdkEventButton into port matrix button
press/release handlers, rather than just selected highlights. Remove port in the port matrix on Keyboard is_delete_event (part of #4536). git-svn-id: svn://localhost/ardour2/branches/3.0@10920 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
790d9042c6
commit
668c8b1f9e
8 changed files with 28 additions and 23 deletions
|
|
@ -18,6 +18,7 @@
|
|||
*/
|
||||
|
||||
#include <iostream>
|
||||
#include "gtkmm2ext/keyboard.h"
|
||||
#include "ardour/bundle.h"
|
||||
#include "ardour/types.h"
|
||||
#include "port_matrix_column_labels.h"
|
||||
|
|
@ -451,7 +452,7 @@ PortMatrixColumnLabels::position_to_channel (double p, double o, boost::shared_p
|
|||
}
|
||||
|
||||
void
|
||||
PortMatrixColumnLabels::button_press (double x, double y, int b, uint32_t t, guint)
|
||||
PortMatrixColumnLabels::button_press (double x, double y, GdkEventButton* ev)
|
||||
{
|
||||
ARDOUR::BundleChannel w = position_to_channel (x, y, _matrix->visible_columns());
|
||||
|
||||
|
|
@ -463,11 +464,13 @@ PortMatrixColumnLabels::button_press (double x, double y, int b, uint32_t t, gui
|
|||
w.channel = -1;
|
||||
}
|
||||
|
||||
if (b == 3) {
|
||||
if (Gtkmm2ext::Keyboard::is_delete_event (ev) && w.channel != -1) {
|
||||
_matrix->remove_channel (w);
|
||||
} else if (ev->button == 3) {
|
||||
_matrix->popup_menu (
|
||||
w,
|
||||
ARDOUR::BundleChannel (),
|
||||
t
|
||||
ev->time
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue