eric6/Tools/UIPreviewer.py

changeset 8205
4a0f1f896341
parent 8151
8c1445825e7b
child 8218
7c09585bd960
--- a/eric6/Tools/UIPreviewer.py	Thu Apr 08 17:27:12 2021 +0200
+++ b/eric6/Tools/UIPreviewer.py	Thu Apr 08 18:27:47 2021 +0200
@@ -337,7 +337,8 @@
         """
         Private slot to load a ui file.
         
-        @param fn name of the ui file to be laoded (string)
+        @param fn name of the ui file to be laoded
+        @type str
         """
         if self.mainWidget:
             self.mainWidget.close()
@@ -354,10 +355,7 @@
         if self.mainWidget:
             self.currentFile = fn
             self.__updateChildren(self.styleCombo.currentText())
-            if (
-                isinstance(self.mainWidget, QDialog) or
-                isinstance(self.mainWidget, QMainWindow)
-            ):
+            if isinstance(self.mainWidget, (QDialog, QMainWindow)):
                 self.mainWidget.show()
                 self.mainWidget.installEventFilter(self)
             else:

eric ide

mercurial