src/eric7/QScintilla/EditorAssembly.py

branch
eric7
changeset 9687
3a240d3f3b8c
parent 9653
e67609152c5e
child 9688
f3817c476a62
--- a/src/eric7/QScintilla/EditorAssembly.py	Mon Jan 09 11:22:56 2023 +0100
+++ b/src/eric7/QScintilla/EditorAssembly.py	Tue Jan 10 09:19:32 2023 +0100
@@ -79,7 +79,7 @@
 
         self.__module = None
 
-        self.__shutdownTimerCalled = False
+        self.__aboutToBeClosedCalled = False
         self.__parseTimer = QTimer(self)
         self.__parseTimer.setSingleShot(True)
         self.__parseTimer.setInterval(5 * 1000)
@@ -98,15 +98,17 @@
             self.__preferencesChanged
         )
 
-    def shutdownTimer(self):
+    def aboutToBeClosed(self):
         """
-        Public method to stop and disconnect the timer.
+        Public method to stop and disconnect the timer and disconnect some signals.
         """
         self.__parseTimer.stop()
-        if not self.__shutdownTimerCalled:
+        if not self.__aboutToBeClosedCalled:
             self.__editor.textChanged.disconnect(self.__resetParseTimer)
             self.__editor.refreshed.disconnect(self.__resetParseTimer)
-            self.__shutdownTimerCalled = True
+            ericApp().getObject("UserInterface").preferencesChanged.disconnect()
+
+            self.__aboutToBeClosedCalled = True
 
     def getEditor(self):
         """

eric ide

mercurial