facelessuser / Rummage

Rummage is a GUI for grep like searches in Python
https://facelessuser.github.io/Rummage/
MIT License
75 stars 10 forks source link

Latest wxpython keyevent changes popup lineage #408

Closed facelessuser closed 4 years ago

facelessuser commented 4 years ago

We used to get the escape key event on the AutoCompleteCombo object. Now we get it on AutoCompleteCombo -> PopupTransientWindow -> ListCtrl.

We used to use this event to

  1. cancel a search only if we didn't have a combo box open, if we did, we assume they meant to close the history popup.

  2. We used the capture the key event to dismiss the history.

Now it's all messed up in the latest wxpython. So use the original esc hotkey of the main window to check the hierarchy, and do what we were doing before (cancel search if conditions are right), but we also need to capture the escape on the list now or send it down from the escape hotkey; the first would be much cleaner.