eric6/QScintilla/APIsManager.py

changeset 7267
aedc309827c7
parent 7229
53054eb5b15a
child 7360
9190402e4505
diff -r d001bc703c29 -r aedc309827c7 eric6/QScintilla/APIsManager.py
--- a/eric6/QScintilla/APIsManager.py	Wed Sep 25 18:25:43 2019 +0200
+++ b/eric6/QScintilla/APIsManager.py	Wed Sep 25 18:37:35 2019 +0200
@@ -80,22 +80,28 @@
         """
         if self.__apis.isPrepared():
             # load a prepared API file
-            if not self.__forPreparation and \
-                    Preferences.getEditor("AutoPrepareAPIs"):
+            if (
+                not self.__forPreparation and
+                Preferences.getEditor("AutoPrepareAPIs")
+            ):
                 self.prepareAPIs()
             self.__apis.loadPrepared(self.__preparedName())
         else:
             # load the raw files and prepare the API file
-            if not self.__forPreparation and \
-                    Preferences.getEditor("AutoPrepareAPIs"):
+            if (
+                not self.__forPreparation and
+                Preferences.getEditor("AutoPrepareAPIs")
+            ):
                 self.prepareAPIs(ondemand=True)
     
     def reloadAPIs(self):
         """
         Public method to reload the API information.
         """
-        if not self.__forPreparation and \
-                Preferences.getEditor("AutoPrepareAPIs"):
+        if (
+            not self.__forPreparation and
+            Preferences.getEditor("AutoPrepareAPIs")
+        ):
             self.prepareAPIs()
         self.__loadAPIs()
     
@@ -105,8 +111,10 @@
         
         @return reference to the QsciAPIs object (QsciAPIs)
         """
-        if not self.__forPreparation and \
-                Preferences.getEditor("AutoPrepareAPIs"):
+        if (
+            not self.__forPreparation and
+            Preferences.getEditor("AutoPrepareAPIs")
+        ):
             self.prepareAPIs()
         return self.__apis
     
@@ -168,8 +176,10 @@
                     if self.__apifiles != apifiles:
                         needsPreparation = True
                     for apifile in apifiles:
-                        if QFileInfo(apifile).lastModified() > \
-                                preparedAPIsTime:
+                        if (
+                            QFileInfo(apifile).lastModified() >
+                            preparedAPIsTime
+                        ):
                             needsPreparation = True
                             break
         
@@ -288,8 +298,8 @@
             except KeyError:
                 if language in Lexers.getSupportedApiLanguages():
                     # create the api object
-                    self.__apis[(language, projectType)] = \
-                        APIs(language, projectType=projectType)
+                    self.__apis[(language, projectType)] = APIs(
+                        language, projectType=projectType)
                     return self.__apis[(language, projectType)]
                 else:
                     return None

eric ide

mercurial