Perhaps you could use wx.EventFilter?
wx.EventFilter
See the example in: wx.EventFilter — wxPython Phoenix 4.2.1 documentation
Also: How to work with wx.EventFilter