You can know if the event stack is empty calling the gtk.events_pending() method, but I want to manipulate the pending events and filter it before the next gtk loop cycle, this data must be stored somewhere, but where?
Thanks.
You can know if the event stack is empty calling the gtk.events_pending() method, but I want to manipulate the pending events and filter it before the next gtk loop cycle, this data must be stored somewhere, but where?
Thanks.
You can control the event loop yourself. Rather than calling gtk.main()
, you can use gtk.main_iteration
.
Your loop could then be:
while running:
#filter events here
gtk.main_iteration(true)
see here for more info.