The Birdfont Source Code


All Repositories / birdfont.git / blobdiff – RSS feed

Consume key strokes in key bindings

Changes made to libbirdfont/TabContent.vala

Contributing

Send patches or pull requests to johan.mattsson.m@gmail.com.
Clone this repository: git clone https://github.com/johanmattssonm/birdfont.git
--- libbirdfont/TabContent.vala +++ libbirdfont/TabContent.vala @@ -144,8 +144,12 @@ KeyBindings.add_modifier_from_keyval (keyval); if (!text_input_visible) { - MainWindow.get_menu ().process_key_binding_events (keyval); - GlyphCanvas.current_display.key_press (keyval); + AbstractMenu menu = MainWindow.get_menu (); + bool consumed = menu.process_key_binding_events (keyval); + + if (!consumed) { + GlyphCanvas.current_display.key_press (keyval); + } } else { text_input.key_press (keyval); }