1
mirror of https://github.com/lalbornoz/roar.git synced 2025-04-04 19:18:22 +00:00

libgui/GuiFrame.py:onMenu(): only dispatch events via itemsById[eventId] if present, skip otherwise.

This commit is contained in:
Lucio Andrés Illanes Albornoz 2019-09-11 14:43:55 +02:00
parent e30628f28d
commit 3be34bc657

View File

@ -152,7 +152,11 @@ class GuiFrame(wx.Frame):
# }}}
# {{{ onMenu(self, event)
def onMenu(self, event):
eventId = event.GetId(); self.itemsById[eventId](event);
eventId = event.GetId()
if eventId in self.itemsById:
self.itemsById[eventId](event)
else:
event.Skip()
# }}}
# {{{ onMouseWheel(self, event)
def onMouseWheel(self, event):