Improved the context menu of the task viewer.

Sun, 20 Mar 2016 10:01:54 +0100

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Sun, 20 Mar 2016 10:01:54 +0100
changeset 4883
ae0ee88c9d62
parent 4878
8701872bb336
child 4887
e10234bb547c

Improved the context menu of the task viewer.
(grafted from 742af9854449ba6d819d3f08f09b7501a42d17a4)

Tasks/TaskViewer.py file | annotate | diff | comparison | revisions
--- a/Tasks/TaskViewer.py	Sat Mar 19 18:12:26 2016 +0100
+++ b/Tasks/TaskViewer.py	Sun Mar 20 10:01:54 2016 +0100
@@ -140,7 +140,7 @@
         self.backPasteMainItem = self.__backMenu.addAction(
             self.tr("Paste as &Main Task"), self.__pasteMainTask)
         self.__backMenu.addSeparator()
-        self.__backMenu.addAction(
+        self.backDeleteCompletedItem = self.__backMenu.addAction(
             self.tr("Delete Completed &Tasks"), self.__deleteCompleted)
         self.__backMenu.addSeparator()
         self.__backMenuFilteredAct = self.__backMenu.addAction(
@@ -273,6 +273,8 @@
             else:
                 self.backPasteItem.setEnabled(False)
                 self.backPasteMainItem.setEnabled(False)
+            self.backDeleteCompletedItem.setEnabled(
+                bool(self.tasks))
             self.__backMenu.popup(coord)
         else:
             self.projectTasksMenuItem.setEnabled(self.projectOpen)

eric ide

mercurial