src/eric7/Project/ProjectTranslationsBrowser.py

branch
server
changeset 10708
a6094987c1be
parent 10704
27d21e5163b8
child 11050
f0b91a949398
--- a/src/eric7/Project/ProjectTranslationsBrowser.py	Wed May 15 10:58:12 2024 +0200
+++ b/src/eric7/Project/ProjectTranslationsBrowser.py	Wed May 15 11:01:48 2024 +0200
@@ -768,20 +768,19 @@
         """
         Private slot called by the dirMenu aboutToShow signal.
         """
-        if (
-            FileSystemUtilities.isPlainFileName(self.project.getProjectPath())
-            and self.project.getProjectType() in [
-                "PyQt5",
-                "PyQt5C",
-                "PyQt6",
-                "PyQt6C",
-                "E7Plugin",
-                "PySide2",
-                "PySide2C",
-                "PySide6",
-                "PySide6C",
-            ]
-        ):
+        if FileSystemUtilities.isPlainFileName(
+            self.project.getProjectPath()
+        ) and self.project.getProjectType() in [
+            "PyQt5",
+            "PyQt5C",
+            "PyQt6",
+            "PyQt6C",
+            "E7Plugin",
+            "PySide2",
+            "PySide2C",
+            "PySide6",
+            "PySide6C",
+        ]:
             if self.pylupdateProcRunning:
                 for act in self.tsprocDirMenuActions:
                     act.setEnabled(False)
@@ -800,20 +799,19 @@
         """
         Private slot called by the backMenu aboutToShow signal.
         """
-        if (
-            FileSystemUtilities.isPlainFileName(self.project.getProjectPath())
-            and self.project.getProjectType() in [
-                "PyQt5",
-                "PyQt5C",
-                "PyQt6",
-                "PyQt6C",
-                "E7Plugin",
-                "PySide2",
-                "PySide2C",
-                "PySide6",
-                "PySide6C",
-            ]
-        ):
+        if FileSystemUtilities.isPlainFileName(
+            self.project.getProjectPath()
+        ) and self.project.getProjectType() in [
+            "PyQt5",
+            "PyQt5C",
+            "PyQt6",
+            "PyQt6C",
+            "E7Plugin",
+            "PySide2",
+            "PySide2C",
+            "PySide6",
+            "PySide6C",
+        ]:
             if self.pylupdateProcRunning:
                 for act in self.tsprocBackMenuActions:
                     act.setEnabled(False)
@@ -842,9 +840,8 @@
                 # hook support
                 if self.hooks["open"] is not None:
                     self.hooks["open"](itm.fileName())
-                elif (
-                    itm.isLinguistFile()
-                    and FileSystemUtilities.isPlainFileName(itm.fileName())
+                elif itm.isLinguistFile() and FileSystemUtilities.isPlainFileName(
+                    itm.fileName()
                 ):
                     if itm.fileExt() == ".ts":
                         self.linguistFile.emit(itm.fileName())

eric ide

mercurial