13
0

Virtual MIDI keyboard, when visible, gets to handle keyboard input first

This commit is contained in:
Robin Gareus 2019-11-22 22:11:55 +01:00
parent 98bcfb1485
commit ceee42f7af
Signed by: rgareus
GPG Key ID: A090BCE02CF57F04

View File

@ -40,6 +40,7 @@
#include "debug.h" #include "debug.h"
#include "keyboard.h" #include "keyboard.h"
#include "public_editor.h" #include "public_editor.h"
#include "virtual_keyboard_window.h"
using namespace ARDOUR; using namespace ARDOUR;
using namespace PBD; using namespace PBD;
@ -54,6 +55,12 @@ ARDOUR_UI::key_event_handler (GdkEventKey* ev, Gtk::Window* event_window)
Gtkmm2ext::Bindings* bindings = 0; Gtkmm2ext::Bindings* bindings = 0;
Gtk::Window* window = 0; Gtk::Window* window = 0;
if (virtual_keyboard_window && virtual_keyboard_window->is_visible()) {
if (gtk_window_propagate_key_event (virtual_keyboard_window->gobj(), ev)) {
return true;
}
}
/* until we get ardour bindings working, we are not handling key /* until we get ardour bindings working, we are not handling key
* releases yet. * releases yet.
*/ */