def do_cleanup(self): self.cancel_resize_timer() X11ServerBase.do_cleanup(self) remove_catchall_receiver("xpra-motion-event", self) cleanup_x11_filter() with xswallow: cleanup_all_event_receivers()
def do_cleanup(self): log("do_cleanup() x11_filter=%s", self.x11_filter) if self.x11_filter: self.x11_filter = False cleanup_x11_filter() #try a few times: #errors happen because windows are being destroyed #(even more so when we cleanup) #and we don't really care too much about this for l in (log, log, log, log, log.warn): try: with xsync: cleanup_all_event_receivers() #all went well, we're done log("all event receivers have been removed") break except Exception as e: l("failed to remove event receivers: %s", e) if self.fake_xinerama: cleanup_fakeXinerama() with xlog: clean_keyboard_state() #prop_del does its own xsync: self.clean_x11_properties() super().do_cleanup() log("close_gdk_display_source()") close_gdk_display_source()
def cleanup(self, *args): if self._tray: self._tray.cleanup() self._tray = None X11ServerBase.cleanup(self) cleanup_x11_filter() cleanup_all_event_receivers() if self._wm: self._wm.cleanup() self._wm = None if self._has_grab: #normally we set this value when we receive the NotifyUngrab #but at this point in the cleanup, we probably won't, so force set it: self._has_grab = 0 self.X11_ungrab()
def cleanup(self): #this must be called from the UI thread! remove_event_receiver(self._root, self) self._root.set_events(self._saved_event_mask) #try a few times: #errors happen because windows are being destroyed #(even more so when we cleanup) #and we don't really care too much about this for l in (log, log, log, log, log.warn): try: with xsync: cleanup_all_event_receivers() #all went well, we're done return except Exception as e: l("failed to remove event receivers: %s", e)
def cleanup(self): #this must be called from the UI thread! remove_event_receiver(self._root, self) self._root.set_events(self._saved_event_mask) if self._own_x11_filter: #only remove the x11 filter if we initialized it (ie: when running in client) try: with xsync: cleanup_x11_filter() except Exception as e: log.error("failed to remove x11 event filter: %s", e) try: with xsync: cleanup_all_event_receivers() except Exception as e: log.error("failed to remove event receivers: %s", e)
def do_cleanup(self): self.cancel_resize_timer() X11ServerBase.do_cleanup(self) remove_catchall_receiver("xpra-motion-event", self) cleanup_x11_filter() #try a few times: #errors happen because windows are being destroyed #(even more so when we cleanup) #and we don't really care too much about this for l in (log, log, log, log, log.warn): try: with xsync: cleanup_all_event_receivers() #all went well, we're done return except Exception as e: l("failed to remove event receivers: %s", e)
def do_cleanup(self): if self.x11_filter: self.x11_filter = False cleanup_x11_filter() #try a few times: #errors happen because windows are being destroyed #(even more so when we cleanup) #and we don't really care too much about this for l in (log, log, log, log, log.warn): try: with xsync: cleanup_all_event_receivers() #all went well, we're done break except Exception as e: l("failed to remove event receivers: %s", e) if self.fake_xinerama: cleanup_fakeXinerama() with xswallow: clean_keyboard_state() GTKServerBase.do_cleanup(self) log("close_gdk_display_source()") close_gdk_display_source()