Project/ProjectResourcesBrowser.py

changeset 2192
61b3849df76d
parent 1676
54f387117fee
child 2302
f29e9405c851
diff -r 7c7251ce9497 -r 61b3849df76d Project/ProjectResourcesBrowser.py
--- a/Project/ProjectResourcesBrowser.py	Sun Nov 04 17:39:08 2012 +0100
+++ b/Project/ProjectResourcesBrowser.py	Mon Nov 05 16:55:16 2012 +0100
@@ -21,6 +21,7 @@
 from .ProjectBaseBrowser import ProjectBaseBrowser
 
 from UI.DeleteFilesConfirmationDialog import DeleteFilesConfirmationDialog
+import UI.PixmapCache
 
 import Preferences
 import Utilities
@@ -507,6 +508,7 @@
         """
         self.compileRunning = False
         e5App().getObject("ViewManager").enableEditorsCheckFocusIn(True)
+        ui = e5App().getObject("UserInterface")
         if exitStatus == QProcess.NormalExit and exitCode == 0 and self.buf:
             ofn = os.path.join(self.project.ppath, self.compiledFile)
             try:
@@ -520,11 +522,17 @@
                 f.close()
                 if self.compiledFile not in self.project.pdata["SOURCES"]:
                     self.project.appendFile(ofn)
-                if not self.noDialog:
+                if not self.noDialog and not ui.notificationsEnabled():
                     E5MessageBox.information(self,
                         self.trUtf8("Resource Compilation"),
                         self.trUtf8("The compilation of the resource file"
                             " was successful."))
+                else:
+                    ui.showNotification(
+                        UI.PixmapCache.getPixmap("resourcesCompiler48.png"),
+                        self.trUtf8("Resource Compilation"),
+                        self.trUtf8("The compilation of the resource file"
+                            " was successful."))
             except IOError as msg:
                 if not self.noDialog:
                     E5MessageBox.information(self,
@@ -536,6 +544,10 @@
                 E5MessageBox.information(self,
                     self.trUtf8("Resource Compilation"),
                     self.trUtf8("The compilation of the resource file failed."))
+            else:
+                ui.showNotification(UI.PixmapCache.getPixmap("resourcesCompiler48.png"),
+                    self.trUtf8("Resource Compilation"),
+                    self.trUtf8("The compilation of the resource file failed."))
         self.compileProc = None
         
     def __compileQRC(self, fn, noDialog=False, progress=None):

eric ide

mercurial