AUPluginUI::on_focus_in_event (GdkEventFocus* ev)
{
cerr << "au plugin focus in\n";
+ Keyboard::magic_widget_grab_focus ();
return false;
}
AUPluginUI::on_focus_out_event (GdkEventFocus* ev)
{
cerr << "au plugin focus out\n";
+ Keyboard::magic_widget_drop_focus ();
return false;
}
GtkWindow* win = window.gobj();
GtkWidget* focus = gtk_window_get_focus (win);
bool special_handling_of_unmodified_accelerators = false;
+#ifdef GTKOSX
+ bool allow_forwarding = true;
+#endif
#undef DEBUG_ACCELERATOR_HANDLING
#ifdef DEBUG_ACCELERATOR_HANDLING
}
}
+#ifdef GTKOSX
+ if (Keyboard::some_magic_widget_has_focus ()) {
+ allow_forwarding = false;
+ }
+#endif
+
#ifdef DEBUG_ACCELERATOR_HANDLING
if (debug) {
cerr << "Win = " << win << " Key event: code = " << ev->keyval << " state = " << hex << ev->state << dec << " special handling ? "
cerr << "\tactivate, then propagate\n";
}
#endif
+
#ifdef GTKOSX
- if (gdk_quartz_possibly_forward ((GdkEvent*) ev)) {
+ if (allow_forwarding && gdk_quartz_possibly_forward ((GdkEvent*) ev)) {
return true;
}
#endif