2871 pass |
2871 pass |
2872 |
2872 |
2873 if not self.__fromEric: |
2873 if not self.__fromEric: |
2874 Preferences.syncPreferences() |
2874 Preferences.syncPreferences() |
2875 if not WebBrowserWindow._performingShutdown and \ |
2875 if not WebBrowserWindow._performingShutdown and \ |
2876 len(WebBrowserWindow.BrowserWindows) == 0: |
2876 len(WebBrowserWindow.BrowserWindows) == 1: |
2877 # shut down the browser in case the last window was |
2877 # shut down the browser in case the last window was |
2878 # simply closed |
2878 # simply closed |
2879 self.shutdown() |
2879 self.shutdown() |
2880 |
2880 |
2881 return True |
2881 return True |
2924 @return flag indicating successful shutdown (boolean) |
2924 @return flag indicating successful shutdown (boolean) |
2925 """ |
2925 """ |
2926 if not self.__shallShutDown(): |
2926 if not self.__shallShutDown(): |
2927 return False |
2927 return False |
2928 |
2928 |
2929 if not self.downloadManager().allowQuit(): |
2929 if WebBrowserWindow._downloadManager is not None and \ |
|
2930 not self.downloadManager().allowQuit(): |
2930 return False |
2931 return False |
2931 |
2932 |
2932 WebBrowserWindow._performingShutdown = True |
2933 WebBrowserWindow._performingShutdown = True |
2933 |
2934 |
2934 self.sessionManager().shutdown() |
2935 self.sessionManager().shutdown() |
2935 |
2936 |
2936 self.downloadManager().shutdown() |
2937 if WebBrowserWindow._downloadManager is not None: |
|
2938 self.downloadManager().shutdown() |
2937 |
2939 |
2938 self.cookieJar().close() |
2940 self.cookieJar().close() |
2939 |
2941 |
2940 self.bookmarksManager().close() |
2942 self.bookmarksManager().close() |
2941 |
2943 |