def _closeWindow(self) -> None: self._cleanup_preview() self.editor.cleanup() saveSplitter(self.form.splitter, "editor3") saveGeom(self, "editor") saveState(self, "editor") saveHeader(self.form.tableView.horizontalHeader(), "editor") self.teardownHooks() self.mw.maybeReset() aqt.dialogs.markClosed("Browser") self._closeEventHasCleanedUp = True self.mw.deferred_delete_and_garbage_collect(self) self.close()
def closeEvent(self, evt): saveSplitter(self.form.splitter_2, "editor2") saveSplitter(self.form.splitter, "editor3") self.editor.saveNow() self.editor.setNote(None) saveGeom(self, "editor") saveState(self, "editor") saveHeader(self.form.tableView.horizontalHeader(), "editor") self.col.conf['activeCols'] = self.model.activeCols self.hide() aqt.dialogs.close("Browser") self.teardownHooks() self.mw.maybeReset() evt.accept()
def cleanup(self): remHook("reset", self.onReset) self.browser.organizer = None saveGeom(self, "organizer") saveHeader(self.hh, "organizer")
def _save_header(self) -> None: saveHeader(self._view.horizontalHeader(), self._state.config_key_prefix)
def _save_header(self) -> None: saveHeader(self._view.horizontalHeader(), self._state.GEOMETRY_KEY_PREFIX)