From 119e610a3e2387e8ec60e2c627676f3684938605 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sun, 7 Mar 2010 21:05:29 +0000 Subject: Fix module context menus (only steal patch window events for key events). git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@2538 a436a847-0d15-0410-975c-d299462d15a1 --- src/gui/PatchWindow.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/gui') diff --git a/src/gui/PatchWindow.cpp b/src/gui/PatchWindow.cpp index 61ca446d..42e5c6f4 100644 --- a/src/gui/PatchWindow.cpp +++ b/src/gui/PatchWindow.cpp @@ -619,7 +619,12 @@ PatchWindow::on_hide() bool PatchWindow::on_event(GdkEvent* event) { - return (_view->canvas()->canvas_event(event)) ? true : Gtk::Window::on_event(event); + if ((event->type == GDK_KEY_PRESS || event->type == GDK_KEY_RELEASE) + && _view->canvas()->canvas_event(event)) { + return true; + } else { + return Gtk::Window::on_event(event); + } } -- cgit v1.2.1