Skip to content

Commit

Permalink
'Close' now uses QMainWindow's 'close' slot
Browse files Browse the repository at this point in the history
  • Loading branch information
pinkwah authored and markusdregi committed Nov 15, 2019
1 parent f35ac75 commit 11f6e08
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions ert_gui/main_window.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ def addTool(self, tool):

def __createMenu(self):
file_menu = self.menuBar().addMenu("&File")
file_menu.addAction("Close", self.__quit)
file_menu.addAction("Close", self.close)
self.__view_menu = self.menuBar().addMenu("&View")
self.__help_menu = self.menuBar().addMenu("&Help")
""":type: QMenu"""
Expand All @@ -95,12 +95,6 @@ def __createMenu(self):
help_link_item.triggered.connect(functools.partial(webbrowser.open, link))


def __quit(self):
self.__saveSettings()
self._clear_global_state()
qApp.quit()


def __saveSettings(self):
settings = QSettings("Equinor", "Ert-Gui")
settings.setValue("geometry", self.saveGeometry())
Expand Down

0 comments on commit 11f6e08

Please sign in to comment.