eric6/Project/ProjectProtocolsBrowser.py

changeset 7955
567f2ec958c3
parent 7923
91e843545d9a
child 7959
44e15eda6506
diff -r d32319ede131 -r 567f2ec958c3 eric6/Project/ProjectProtocolsBrowser.py
--- a/eric6/Project/ProjectProtocolsBrowser.py	Mon Jan 04 16:39:09 2021 +0100
+++ b/eric6/Project/ProjectProtocolsBrowser.py	Mon Jan 04 16:39:37 2021 +0100
@@ -547,41 +547,27 @@
                 fileList += glob.glob(os.path.join(path, "*_pb2_grpc.py"))
             for file in fileList:
                 self.project.appendFile(file)
-            if not self.noDialog and not ui.notificationsEnabled():
-                E5MessageBox.information(
-                    self,
-                    self.tr("Protocol Compilation"),
-                    self.tr(
-                        "The compilation of the protocol file was"
-                        " successful."))
+            if grpc:
+                icon = UI.PixmapCache.getPixmap("gRPC48")
             else:
-                if grpc:
-                    icon = UI.PixmapCache.getPixmap("gRPC48")
-                else:
-                    icon = UI.PixmapCache.getPixmap("protobuf48")
-                ui.showNotification(
-                    icon,
-                    self.tr("Protocol Compilation"),
-                    self.tr(
-                        "The compilation of the protocol file was"
-                        " successful."))
+                icon = UI.PixmapCache.getPixmap("protobuf48")
+            ui.showNotification(
+                icon,
+                self.tr("Protocol Compilation"),
+                self.tr(
+                    "The compilation of the protocol file was"
+                    " successful."))
         else:
-            if not self.noDialog:
-                E5MessageBox.information(
-                    self,
-                    self.tr("Protocol Compilation"),
-                    self.tr(
-                        "The compilation of the protocol file failed."))
+            if grpc:
+                icon = UI.PixmapCache.getPixmap("gRPC48")
             else:
-                if grpc:
-                    icon = UI.PixmapCache.getPixmap("gRPC48")
-                else:
-                    icon = UI.PixmapCache.getPixmap("protobuf48")
-                ui.showNotification(
-                    icon,
-                    self.tr("Protocol Compilation"),
-                    self.tr(
-                        "The compilation of the protocol file failed."))
+                icon = UI.PixmapCache.getPixmap("protobuf48")
+            ui.showNotification(
+                icon,
+                self.tr("Protocol Compilation"),
+                self.tr(
+                    "The compilation of the protocol file failed."),
+                timeout=0)
         self.compileProc = None
         
     def __compileProto(self, fn, noDialog=False, progress=None, grpc=False):

eric ide

mercurial