def open(self): """ Opens a contextual menu by calling creator:: yield self.open() """ windows = Gtk.Window.list_toplevels() yield idle_modal_dialog(self.creator) self.menu = [ w for w in Gtk.Window.list_toplevels() if w not in windows and w.get_mapped() ] if gps_not_null(self.menu, 'Contextual menu not created'): self.menu = self.menu[0]
def yield_replace_and_find(self): yield idle_modal_dialog(self.replace_and_find.clicked)
def yield_replace_all(self): yield idle_modal_dialog(self.replace_all.clicked)
def yield_find_all(self): yield idle_modal_dialog(self.find_all.clicked)
def yield_find(self): # Could open a modal dialog to warn that we reached the end yield idle_modal_dialog(self.find.clicked)
def yield_modify(self): yield idle_modal_dialog(self.modify_button.clicked)