Plugins/VcsPlugins/vcsMercurial/QueuesExtension/ProjectHelper.py

Sat, 08 Mar 2014 20:09:41 +0100

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Sat, 08 Mar 2014 20:09:41 +0100
changeset 3345
071afe8be2a1
parent 3314
be841c05a7f3
child 3396
5320ecd70fdb
permissions
-rw-r--r--

Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.

1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
1 # -*- coding: utf-8 -*-
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
2
3160
209a07d7e401 Updated copyright for 2014.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3023
diff changeset
3 # Copyright (c) 2011 - 2014 Detlev Offenbach <detlev@die-offenbachs.de>
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
4 #
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
5
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
6 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
7 Module implementing the queues extension project helper.
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
8 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
9
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
10 from PyQt4.QtGui import QMenu
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
11
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
12 from E5Gui.E5Action import E5Action
1068
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
13 from E5Gui import E5MessageBox
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
14
1087
fb8cd56819a9 Changed the Mercurial extension interface code to use custom base classes instead of inheriting QObject directly.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1074
diff changeset
15 from ..HgExtensionProjectHelper import HgExtensionProjectHelper
fb8cd56819a9 Changed the Mercurial extension interface code to use custom base classes instead of inheriting QObject directly.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1074
diff changeset
16
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
17 from .queues import Queues
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
18
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
19
1087
fb8cd56819a9 Changed the Mercurial extension interface code to use custom base classes instead of inheriting QObject directly.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1074
diff changeset
20 class QueuesProjectHelper(HgExtensionProjectHelper):
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
21 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
22 Class implementing the queues extension project helper.
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
23 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
24 def __init__(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
25 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
26 Constructor
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
27 """
1087
fb8cd56819a9 Changed the Mercurial extension interface code to use custom base classes instead of inheriting QObject directly.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1074
diff changeset
28 super().__init__()
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
29
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
30 def initActions(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
31 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
32 Public method to generate the action objects.
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
33 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
34 self.hgQueueInitAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
35 self.tr('Init Queue Repository'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
36 self.tr('Init Queue Repository'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
37 0, 0, self, 'mercurial_queues_init')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
38 self.hgQueueInitAct.setStatusTip(self.tr(
2815
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
39 'Initialize a new versioned queue repository'
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
40 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
41 self.hgQueueInitAct.setWhatsThis(self.tr(
2815
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
42 """<b>Init Queue Repository</b>"""
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
43 """<p>This initializes a new versioned queue repository inside"""
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
44 """ the current repository.</p>"""
2815
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
45 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
46 self.hgQueueInitAct.triggered.connect(self.__hgQueueInit)
2815
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
47 self.actions.append(self.hgQueueInitAct)
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
48
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
49 self.hgQueueCommitAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
50 self.tr('Commit changes'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
51 self.tr('Commit changes...'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
52 0, 0, self, 'mercurial_queues_commit')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
53 self.hgQueueCommitAct.setStatusTip(self.tr(
2815
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
54 'Commit changes in the queue repository'
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
55 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
56 self.hgQueueCommitAct.setWhatsThis(self.tr(
2815
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
57 """<b>Commit changes...</b>"""
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
58 """<p>This commits changes in the queue repository.</p>"""
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
59 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
60 self.hgQueueCommitAct.triggered.connect(self.__hgQueueCommit)
2815
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
61 self.actions.append(self.hgQueueCommitAct)
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
62
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
63 self.hgQueueNewAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
64 self.tr('New Patch'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
65 self.tr('New Patch...'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
66 0, 0, self, 'mercurial_queues_new')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
67 self.hgQueueNewAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
68 'Create a new patch'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
69 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
70 self.hgQueueNewAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
71 """<b>New Patch</b>"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
72 """<p>This creates a new named patch.</p>"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
73 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
74 self.hgQueueNewAct.triggered.connect(self.__hgQueueNewPatch)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
75 self.actions.append(self.hgQueueNewAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
76
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
77 self.hgQueueRefreshAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
78 self.tr('Update Current Patch'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
79 self.tr('Update Current Patch'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
80 0, 0, self, 'mercurial_queues_refresh')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
81 self.hgQueueRefreshAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
82 'Update the current patch'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
83 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
84 self.hgQueueRefreshAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
85 """<b>Update Current Patch</b>"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
86 """<p>This updates the current patch.</p>"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
87 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
88 self.hgQueueRefreshAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
89 self.__hgQueueRefreshPatch)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
90 self.actions.append(self.hgQueueRefreshAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
91
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
92 self.hgQueueRefreshMessageAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
93 self.tr('Update Current Patch (with Message)'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
94 self.tr('Update Current Patch (with Message)'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
95 0, 0, self, 'mercurial_queues_refresh_message')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
96 self.hgQueueRefreshMessageAct.setStatusTip(self.tr(
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
97 'Update the current patch and edit commit message'
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
98 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
99 self.hgQueueRefreshMessageAct.setWhatsThis(self.tr(
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
100 """<b>Update Current Patch (with Message)</b>"""
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
101 """<p>This updates the current patch after giving the chance"""
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
102 """ to change the current commit message.</p>"""
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
103 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
104 self.hgQueueRefreshMessageAct.triggered.connect(
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
105 self.__hgQueueRefreshPatchMessage)
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
106 self.actions.append(self.hgQueueRefreshMessageAct)
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
107
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
108 self.hgQueueDiffAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
109 self.tr('Show Current Patch'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
110 self.tr('Show Current Patch...'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
111 0, 0, self, 'mercurial_queues_show')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
112 self.hgQueueDiffAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
113 'Show the contents the current patch'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
114 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
115 self.hgQueueDiffAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
116 """<b>Show Current Patch</b>"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
117 """<p>This shows the contents of the current patch including"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
118 """ any changes which have been made in the working directory"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
119 """ since the last refresh.</p>"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
120 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
121 self.hgQueueDiffAct.triggered.connect(self.__hgQueueShowPatch)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
122 self.actions.append(self.hgQueueDiffAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
123
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
124 self.hgQueueHeaderAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
125 self.tr('Show Current Message'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
126 self.tr('Show Current Message...'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
127 0, 0, self, 'mercurial_queues_show_message')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
128 self.hgQueueHeaderAct.setStatusTip(self.tr(
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
129 'Show the commit message of the current patch'
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
130 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
131 self.hgQueueHeaderAct.setWhatsThis(self.tr(
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
132 """<b>Show Current Message</b>"""
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
133 """<p>This shows the commit message of the current patch.</p>"""
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
134 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
135 self.hgQueueHeaderAct.triggered.connect(self.__hgQueueShowHeader)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
136 self.actions.append(self.hgQueueHeaderAct)
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
137
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
138 self.hgQueueListAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
139 self.tr('List Patches'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
140 self.tr('List Patches...'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
141 0, 0, self, 'mercurial_queues_list')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
142 self.hgQueueListAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
143 'List applied and unapplied patches'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
144 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
145 self.hgQueueListAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
146 """<b>List Patches</b>"""
1036
1922b6ce2a57 Updated translations.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1035
diff changeset
147 """<p>This lists all applied and unapplied patches.</p>"""
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
148 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
149 self.hgQueueListAct.triggered.connect(self.__hgQueueListPatches)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
150 self.actions.append(self.hgQueueListAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
151
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
152 self.hgQueueFinishAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
153 self.tr('Finish Applied Patches'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
154 self.tr('Finish Applied Patches'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
155 0, 0, self, 'mercurial_queues_finish_applied')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
156 self.hgQueueFinishAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
157 'Finish applied patches'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
158 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
159 self.hgQueueFinishAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
160 """<b>Finish Applied Patches</b>"""
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
161 """<p>This finishes the applied patches by moving them out of"""
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
162 """ mq control into regular repository history.</p>"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
163 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
164 self.hgQueueFinishAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
165 self.__hgQueueFinishAppliedPatches)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
166 self.actions.append(self.hgQueueFinishAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
167
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
168 self.hgQueueRenameAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
169 self.tr('Rename Patch'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
170 self.tr('Rename Patch'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
171 0, 0, self, 'mercurial_queues_rename')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
172 self.hgQueueRenameAct.setStatusTip(self.tr(
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
173 'Rename a patch'
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
174 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
175 self.hgQueueRenameAct.setWhatsThis(self.tr(
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
176 """<b>Rename Patch</b>"""
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
177 """<p>This renames the current or a named patch.</p>"""
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
178 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
179 self.hgQueueRenameAct.triggered.connect(self.__hgQueueRenamePatch)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
180 self.actions.append(self.hgQueueRenameAct)
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
181
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
182 self.hgQueueDeleteAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
183 self.tr('Delete Patch'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
184 self.tr('Delete Patch'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
185 0, 0, self, 'mercurial_queues_delete')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
186 self.hgQueueDeleteAct.setStatusTip(self.tr(
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
187 'Delete unapplied patch'
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
188 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
189 self.hgQueueDeleteAct.setWhatsThis(self.tr(
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
190 """<b>Delete Patch</b>"""
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
191 """<p>This deletes an unapplied patch.</p>"""
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
192 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
193 self.hgQueueDeleteAct.triggered.connect(self.__hgQueueDeletePatch)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
194 self.actions.append(self.hgQueueDeleteAct)
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
195
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
196 self.hgQueueFoldAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
197 self.tr('Fold Patches'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
198 self.tr('Fold Patches'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
199 0, 0, self, 'mercurial_queues_fold')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
200 self.hgQueueFoldAct.setStatusTip(self.tr(
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
201 'Fold unapplied patches into the current patch'
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
202 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
203 self.hgQueueFoldAct.setWhatsThis(self.tr(
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
204 """<b>Fold Patches</b>"""
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
205 """<p>This folds unapplied patches into the current patch.</p>"""
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
206 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
207 self.hgQueueFoldAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
208 self.__hgQueueFoldUnappliedPatches)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
209 self.actions.append(self.hgQueueFoldAct)
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
210
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
211 self.hgQueueStatusAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
212 self.tr('Show Status'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
213 self.tr('Show &Status...'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
214 0, 0, self, 'mercurial_queues_status')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
215 self.hgQueueStatusAct.setStatusTip(self.tr(
2815
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
216 'Show the status of the queue repository'
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
217 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
218 self.hgQueueStatusAct.setWhatsThis(self.tr(
2815
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
219 """<b>Show Status</b>"""
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
220 """<p>This shows the status of the queue repository.</p>"""
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
221 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
222 self.hgQueueStatusAct.triggered.connect(self.__hgQueueStatus)
2815
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
223 self.actions.append(self.hgQueueStatusAct)
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
224
3314
be841c05a7f3 Added a TODO in the Mercurial queues project helper.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3190
diff changeset
225 # TODO: add support for hg summary --mq
be841c05a7f3 Added a TODO in the Mercurial queues project helper.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3190
diff changeset
226
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
227 self.__initPushPopActions()
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
228 self.__initPushPopForceActions()
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
229 self.__initGuardsActions()
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
230 self.__initQueuesMgmtActions()
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
231
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
232 def __initPushPopActions(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
233 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
234 Public method to generate the push and pop action objects.
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
235 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
236 self.hgQueuePushAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
237 self.tr('Push Next Patch'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
238 self.tr('Push Next Patch'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
239 0, 0, self, 'mercurial_queues_push_next')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
240 self.hgQueuePushAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
241 'Push the next patch onto the stack'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
242 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
243 self.hgQueuePushAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
244 """<b>Push Next Patch</b>"""
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
245 """<p>This pushes the next patch onto the stack of applied"""
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
246 """ patches.</p>"""
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
247 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
248 self.hgQueuePushAct.triggered.connect(self.__hgQueuePushPatch)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
249 self.actions.append(self.hgQueuePushAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
250
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
251 self.hgQueuePushAllAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
252 self.tr('Push All Patches'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
253 self.tr('Push All Patches'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
254 0, 0, self, 'mercurial_queues_push_all')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
255 self.hgQueuePushAllAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
256 'Push all patches onto the stack'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
257 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
258 self.hgQueuePushAllAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
259 """<b>Push All Patches</b>"""
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
260 """<p>This pushes all patches onto the stack of applied"""
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
261 """ patches.</p>"""
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
262 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
263 self.hgQueuePushAllAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
264 self.__hgQueuePushAllPatches)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
265 self.actions.append(self.hgQueuePushAllAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
266
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
267 self.hgQueuePushUntilAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
268 self.tr('Push Patches'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
269 self.tr('Push Patches'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
270 0, 0, self, 'mercurial_queues_push_until')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
271 self.hgQueuePushUntilAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
272 'Push patches onto the stack'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
273 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
274 self.hgQueuePushUntilAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
275 """<b>Push Patches</b>"""
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
276 """<p>This pushes patches onto the stack of applied patches"""
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
277 """ until a named patch is at the top of the stack.</p>"""
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
278 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
279 self.hgQueuePushUntilAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
280 self.__hgQueuePushPatches)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
281 self.actions.append(self.hgQueuePushUntilAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
282
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
283 self.hgQueuePopAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
284 self.tr('Pop Current Patch'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
285 self.tr('Pop Current Patch'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
286 0, 0, self, 'mercurial_queues_pop_current')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
287 self.hgQueuePopAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
288 'Pop the current patch off the stack'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
289 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
290 self.hgQueuePopAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
291 """<b>Pop Current Patch</b>"""
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
292 """<p>This pops the current patch off the stack of applied"""
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
293 """ patches.</p>"""
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
294 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
295 self.hgQueuePopAct.triggered.connect(self.__hgQueuePopPatch)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
296 self.actions.append(self.hgQueuePopAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
297
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
298 self.hgQueuePopAllAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
299 self.tr('Pop All Patches'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
300 self.tr('Pop All Patches'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
301 0, 0, self, 'mercurial_queues_pop_all')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
302 self.hgQueuePopAllAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
303 'Pop all patches off the stack'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
304 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
305 self.hgQueuePopAllAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
306 """<b>Pop All Patches</b>"""
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
307 """<p>This pops all patches off the stack of applied"""
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
308 """ patches.</p>"""
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
309 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
310 self.hgQueuePopAllAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
311 self.__hgQueuePopAllPatches)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
312 self.actions.append(self.hgQueuePopAllAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
313
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
314 self.hgQueuePopUntilAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
315 self.tr('Pop Patches'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
316 self.tr('Pop Patches'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
317 0, 0, self, 'mercurial_queues_pop_until')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
318 self.hgQueuePopUntilAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
319 'Pop patches off the stack'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
320 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
321 self.hgQueuePopUntilAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
322 """<b>Pop Patches</b>"""
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
323 """<p>This pops patches off the stack of applied patches"""
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
324 """ until a named patch is at the top of the stack.</p>"""
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
325 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
326 self.hgQueuePopUntilAct.triggered.connect(self.__hgQueuePopPatches)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
327 self.actions.append(self.hgQueuePopUntilAct)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
328
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
329 self.hgQueueGotoAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
330 self.tr('Go to Patch'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
331 self.tr('Go to Patch'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
332 0, 0, self, 'mercurial_queues_goto')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
333 self.hgQueueGotoAct.setStatusTip(self.tr(
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
334 'Push or pop patches until named patch is at top of stack'
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
335 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
336 self.hgQueueGotoAct.setWhatsThis(self.tr(
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
337 """<b>Go to Patch</b>"""
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
338 """<p>This pushes or pops patches until a named patch is at the"""
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
339 """ top of the stack.</p>"""
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
340 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
341 self.hgQueueGotoAct.triggered.connect(self.__hgQueueGotoPatch)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
342 self.actions.append(self.hgQueueGotoAct)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
343
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
344 def __initPushPopForceActions(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
345 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
346 Public method to generate the push and pop (force) action objects.
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
347 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
348 self.hgQueuePushForceAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
349 self.tr('Push Next Patch'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
350 self.tr('Push Next Patch'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
351 0, 0, self, 'mercurial_queues_push_next_force')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
352 self.hgQueuePushForceAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
353 'Push the next patch onto the stack on top of local changes'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
354 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
355 self.hgQueuePushForceAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
356 """<b>Push Next Patch</b>"""
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
357 """<p>This pushes the next patch onto the stack of applied"""
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
358 """ patches on top of local changes.</p>"""
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
359 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
360 self.hgQueuePushForceAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
361 self.__hgQueuePushPatchForced)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
362 self.actions.append(self.hgQueuePushForceAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
363
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
364 self.hgQueuePushAllForceAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
365 self.tr('Push All Patches'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
366 self.tr('Push All Patches'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
367 0, 0, self, 'mercurial_queues_push_all_force')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
368 self.hgQueuePushAllForceAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
369 'Push all patches onto the stack on top of local changes'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
370 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
371 self.hgQueuePushAllForceAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
372 """<b>Push All Patches</b>"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
373 """<p>This pushes all patches onto the stack of applied patches"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
374 """ on top of local changes.</p>"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
375 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
376 self.hgQueuePushAllForceAct.triggered.connect(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
377 self.__hgQueuePushAllPatchesForced)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
378 self.actions.append(self.hgQueuePushAllForceAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
379
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
380 self.hgQueuePushUntilForceAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
381 self.tr('Push Patches'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
382 self.tr('Push Patches'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
383 0, 0, self, 'mercurial_queues_push_until_force')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
384 self.hgQueuePushUntilForceAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
385 'Push patches onto the stack on top of local changes'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
386 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
387 self.hgQueuePushUntilForceAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
388 """<b>Push Patches</b>"""
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
389 """<p>This pushes patches onto the stack of applied patches"""
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
390 """ until a named patch is at the top of the stack on top of"""
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
391 """ local changes.</p>"""
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
392 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
393 self.hgQueuePushUntilForceAct.triggered.connect(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
394 self.__hgQueuePushPatchesForced)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
395 self.actions.append(self.hgQueuePushUntilForceAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
396
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
397 self.hgQueuePopForceAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
398 self.tr('Pop Current Patch'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
399 self.tr('Pop Current Patch'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
400 0, 0, self, 'mercurial_queues_pop_current_force')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
401 self.hgQueuePopForceAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
402 'Pop the current patch off the stack forgetting local changes'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
403 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
404 self.hgQueuePopForceAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
405 """<b>Pop Current Patch</b>"""
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
406 """<p>This pops the current patch off the stack of applied"""
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
407 """ patches"""
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
408 """ forgetting local changes.</p>"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
409 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
410 self.hgQueuePopForceAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
411 self.__hgQueuePopPatchForced)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
412 self.actions.append(self.hgQueuePopForceAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
413
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
414 self.hgQueuePopAllForceAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
415 self.tr('Pop All Patches'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
416 self.tr('Pop All Patches'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
417 0, 0, self, 'mercurial_queues_pop_all_force')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
418 self.hgQueuePopAllForceAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
419 'Pop all patches off the stack forgetting local changes'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
420 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
421 self.hgQueuePopAllForceAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
422 """<b>Pop All Patches</b>"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
423 """<p>This pops all patches off the stack of applied patches"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
424 """ forgetting local changes.</p>"""
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
425 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
426 self.hgQueuePopAllForceAct.triggered.connect(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
427 self.__hgQueuePopAllPatchesForced)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
428 self.actions.append(self.hgQueuePopAllForceAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
429
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
430 self.hgQueuePopUntilForceAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
431 self.tr('Pop Patches'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
432 self.tr('Pop Patches'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
433 0, 0, self, 'mercurial_queues_pop_until_force')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
434 self.hgQueuePopUntilForceAct.setStatusTip(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
435 'Pop patches off the stack forgetting local changes'
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
436 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
437 self.hgQueuePopUntilForceAct.setWhatsThis(self.tr(
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
438 """<b>Pop Patches</b>"""
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
439 """<p>This pops patches off the stack of applied patches until"""
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
440 """ a named patch is at the top of the stack forgetting local"""
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
441 """ changes.</p>"""
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
442 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
443 self.hgQueuePopUntilForceAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
444 self.__hgQueuePopPatchesForced)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
445 self.actions.append(self.hgQueuePopUntilForceAct)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
446
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
447 self.hgQueueGotoForceAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
448 self.tr('Go to Patch'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
449 self.tr('Go to Patch'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
450 0, 0, self, 'mercurial_queues_goto_force')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
451 self.hgQueueGotoForceAct.setStatusTip(self.tr(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
452 'Push or pop patches until named patch is at top of stack'
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
453 ' overwriting any local changes'
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
454 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
455 self.hgQueueGotoForceAct.setWhatsThis(self.tr(
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
456 """<b>Go to Patch</b>"""
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
457 """<p>This pushes or pops patches until a named patch is at the"""
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
458 """ top of the stack overwriting any local changes.</p>"""
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
459 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
460 self.hgQueueGotoForceAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
461 self.__hgQueueGotoPatchForced)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
462 self.actions.append(self.hgQueueGotoForceAct)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
463
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
464 def __initGuardsActions(self):
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
465 """
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
466 Public method to generate the guards action objects.
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
467 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
468 self.hgQueueDefineGuardsAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
469 self.tr('Define Guards'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
470 self.tr('Define Guards...'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
471 0, 0, self, 'mercurial_queues_guards_define')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
472 self.hgQueueDefineGuardsAct.setStatusTip(self.tr(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
473 'Define guards for the current or a named patch'
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
474 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
475 self.hgQueueDefineGuardsAct.setWhatsThis(self.tr(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
476 """<b>Define Guards</b>"""
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
477 """<p>This opens a dialog to define guards for the current"""
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
478 """ or a named patch.</p>"""
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
479 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
480 self.hgQueueDefineGuardsAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
481 self.__hgQueueGuardsDefine)
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
482 self.actions.append(self.hgQueueDefineGuardsAct)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
483
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
484 self.hgQueueDropAllGuardsAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
485 self.tr('Drop All Guards'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
486 self.tr('Drop All Guards...'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
487 0, 0, self, 'mercurial_queues_guards_drop_all')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
488 self.hgQueueDropAllGuardsAct.setStatusTip(self.tr(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
489 'Drop all guards of the current or a named patch'
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
490 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
491 self.hgQueueDropAllGuardsAct.setWhatsThis(self.tr(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
492 """<b>Drop All Guards</b>"""
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
493 """<p>This drops all guards of the current or a named patch.</p>"""
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
494 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
495 self.hgQueueDropAllGuardsAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
496 self.__hgQueueGuardsDropAll)
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
497 self.actions.append(self.hgQueueDropAllGuardsAct)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
498
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
499 self.hgQueueListGuardsAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
500 self.tr('List Guards'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
501 self.tr('List Guards...'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
502 0, 0, self, 'mercurial_queues_guards_list')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
503 self.hgQueueListGuardsAct.setStatusTip(self.tr(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
504 'List guards of the current or a named patch'
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
505 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
506 self.hgQueueListGuardsAct.setWhatsThis(self.tr(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
507 """<b>List Guards</b>"""
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
508 """<p>This lists the guards of the current or a named patch.</p>"""
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
509 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
510 self.hgQueueListGuardsAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
511 self.__hgQueueGuardsList)
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
512 self.actions.append(self.hgQueueListGuardsAct)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
513
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
514 self.hgQueueListAllGuardsAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
515 self.tr('List All Guards'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
516 self.tr('List All Guards...'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
517 0, 0, self, 'mercurial_queues_guards_list_all')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
518 self.hgQueueListAllGuardsAct.setStatusTip(self.tr(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
519 'List all guards of all patches'
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
520 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
521 self.hgQueueListAllGuardsAct.setWhatsThis(self.tr(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
522 """<b>List All Guards</b>"""
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
523 """<p>This lists all guards of all patches.</p>"""
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
524 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
525 self.hgQueueListAllGuardsAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
526 self.__hgQueueGuardsListAll)
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
527 self.actions.append(self.hgQueueListAllGuardsAct)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
528
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
529 self.hgQueueActivateGuardsAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
530 self.tr('Set Active Guards'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
531 self.tr('Set Active Guards...'),
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
532 0, 0, self, 'mercurial_queues_guards_set_active')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
533 self.hgQueueActivateGuardsAct.setStatusTip(self.tr(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
534 'Set the list of active guards'
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
535 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
536 self.hgQueueActivateGuardsAct.setWhatsThis(self.tr(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
537 """<b>Set Active Guards</b>"""
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
538 """<p>This opens a dialog to set the active guards.</p>"""
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
539 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
540 self.hgQueueActivateGuardsAct.triggered.connect(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
541 self.__hgQueueGuardsSetActive)
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
542 self.actions.append(self.hgQueueActivateGuardsAct)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
543
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
544 self.hgQueueDeactivateGuardsAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
545 self.tr('Deactivate Guards'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
546 self.tr('Deactivate Guards...'),
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
547 0, 0, self, 'mercurial_queues_guards_deactivate')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
548 self.hgQueueDeactivateGuardsAct.setStatusTip(self.tr(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
549 'Deactivate all active guards'
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
550 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
551 self.hgQueueDeactivateGuardsAct.setWhatsThis(self.tr(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
552 """<b>Deactivate Guards</b>"""
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
553 """<p>This deactivates all active guards.</p>"""
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
554 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
555 self.hgQueueDeactivateGuardsAct.triggered.connect(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
556 self.__hgQueueGuardsDeactivate)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
557 self.actions.append(self.hgQueueDeactivateGuardsAct)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
558
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
559 self.hgQueueIdentifyActiveGuardsAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
560 self.tr('Identify Active Guards'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
561 self.tr('Identify Active Guards...'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
562 0, 0, self, 'mercurial_queues_guards_identify_active')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
563 self.hgQueueIdentifyActiveGuardsAct.setStatusTip(self.tr(
1047
b41a36b201e4 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1046
diff changeset
564 'Show a list of active guards'
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
565 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
566 self.hgQueueIdentifyActiveGuardsAct.setWhatsThis(self.tr(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
567 """<b>Identify Active Guards</b>"""
1047
b41a36b201e4 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1046
diff changeset
568 """<p>This opens a dialog showing a list of active guards.</p>"""
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
569 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
570 self.hgQueueIdentifyActiveGuardsAct.triggered.connect(
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
571 self.__hgQueueGuardsIdentifyActive)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
572 self.actions.append(self.hgQueueIdentifyActiveGuardsAct)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
573
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
574 def __initQueuesMgmtActions(self):
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
575 """
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
576 Public method to generate the queues management action objects.
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
577 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
578 self.hgQueueCreateQueueAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
579 self.tr('Create Queue'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
580 self.tr('Create Queue'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
581 0, 0, self, 'mercurial_queues_create_queue')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
582 self.hgQueueCreateQueueAct.setStatusTip(self.tr(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
583 'Create a new patch queue'
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
584 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
585 self.hgQueueCreateQueueAct.setWhatsThis(self.tr(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
586 """<b>Create Queue</b>"""
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
587 """<p>This creates a new patch queue.</p>"""
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
588 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
589 self.hgQueueCreateQueueAct.triggered.connect(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
590 self.__hgQueueCreateQueue)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
591 self.actions.append(self.hgQueueCreateQueueAct)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
592
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
593 self.hgQueueRenameQueueAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
594 self.tr('Rename Queue'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
595 self.tr('Rename Queue'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
596 0, 0, self, 'mercurial_queues_rename_queue')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
597 self.hgQueueRenameQueueAct.setStatusTip(self.tr(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
598 'Rename the active patch queue'
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
599 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
600 self.hgQueueRenameQueueAct.setWhatsThis(self.tr(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
601 """<b>Rename Queue</b>"""
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
602 """<p>This renames the active patch queue.</p>"""
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
603 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
604 self.hgQueueRenameQueueAct.triggered.connect(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
605 self.__hgQueueRenameQueue)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
606 self.actions.append(self.hgQueueRenameQueueAct)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
607
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
608 self.hgQueueDeleteQueueAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
609 self.tr('Delete Queue'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
610 self.tr('Delete Queue'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
611 0, 0, self, 'mercurial_queues_delete_queue')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
612 self.hgQueueDeleteQueueAct.setStatusTip(self.tr(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
613 'Delete the reference to a patch queue'
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
614 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
615 self.hgQueueDeleteQueueAct.setWhatsThis(self.tr(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
616 """<b>Delete Queue</b>"""
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
617 """<p>This deletes the reference to a patch queue.</p>"""
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
618 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
619 self.hgQueueDeleteQueueAct.triggered.connect(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
620 self.__hgQueueDeleteQueue)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
621 self.actions.append(self.hgQueueDeleteQueueAct)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
622
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
623 self.hgQueuePurgeQueueAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
624 self.tr('Purge Queue'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
625 self.tr('Purge Queue'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
626 0, 0, self, 'mercurial_queues_purge_queue')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
627 self.hgQueuePurgeQueueAct.setStatusTip(self.tr(
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
628 'Delete the reference to a patch queue and remove the patch'
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
629 ' directory'
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
630 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
631 self.hgQueuePurgeQueueAct.setWhatsThis(self.tr(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
632 """<b>Purge Queue</b>"""
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
633 """<p>This deletes the reference to a patch queue and removes"""
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
634 """ the patch directory.</p>"""
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
635 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
636 self.hgQueuePurgeQueueAct.triggered.connect(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
637 self.__hgQueuePurgeQueue)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
638 self.actions.append(self.hgQueuePurgeQueueAct)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
639
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
640 self.hgQueueActivateQueueAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
641 self.tr('Activate Queue'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
642 self.tr('Activate Queue'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
643 0, 0, self, 'mercurial_queues_activate_queue')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
644 self.hgQueueActivateQueueAct.setStatusTip(self.tr(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
645 'Set the active queue'
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
646 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
647 self.hgQueueActivateQueueAct.setWhatsThis(self.tr(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
648 """<b>Activate Queue</b>"""
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
649 """<p>This sets the active queue.</p>"""
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
650 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
651 self.hgQueueActivateQueueAct.triggered.connect(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
652 self.__hgQueueActivateQueue)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
653 self.actions.append(self.hgQueueActivateQueueAct)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
654
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
655 self.hgQueueListQueuesAct = E5Action(
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
656 self.tr('List Queues'),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
657 self.tr('List Queues...'),
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
658 0, 0, self, 'mercurial_queues_list_queues')
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
659 self.hgQueueListQueuesAct.setStatusTip(self.tr(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
660 'List the available queues'
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
661 ))
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
662 self.hgQueueListQueuesAct.setWhatsThis(self.tr(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
663 """<b>List Queues</b>"""
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
664 """<p>This opens a dialog showing all available queues.</p>"""
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
665 ))
3345
071afe8be2a1 Changed signal/slot usage to not use constructs like 'triggered[()].connect(...)' anymore.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3314
diff changeset
666 self.hgQueueListQueuesAct.triggered.connect(
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
667 self.__hgQueueListQueues)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
668 self.actions.append(self.hgQueueListQueuesAct)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
669
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
670 def initMenu(self, mainMenu):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
671 """
1066
a3dd41fd9ea8 Added support for the Mercurial fetch extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1061
diff changeset
672 Public method to generate the extension menu.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
673
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
674 @param mainMenu reference to the main menu (QMenu)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
675 @return populated menu (QMenu)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
676 """
1074
ed2585464f12 Changed the logic of the Mercurials extension menu creation.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1073
diff changeset
677 menu = QMenu(self.menuTitle(), mainMenu)
1073
9f0c4b4eccb1 Made a few of the Mercurial menus tearable.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1068
diff changeset
678 menu.setTearOffEnabled(True)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
679
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
680 pushPopMenu = QMenu(self.tr("Push/Pop"), menu)
1073
9f0c4b4eccb1 Made a few of the Mercurial menus tearable.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1068
diff changeset
681 pushPopMenu.setTearOffEnabled(True)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
682 pushPopMenu.addAction(self.hgQueuePushAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
683 pushPopMenu.addAction(self.hgQueuePushUntilAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
684 pushPopMenu.addAction(self.hgQueuePushAllAct)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
685 pushPopMenu.addSeparator()
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
686 pushPopMenu.addAction(self.hgQueuePopAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
687 pushPopMenu.addAction(self.hgQueuePopUntilAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
688 pushPopMenu.addAction(self.hgQueuePopAllAct)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
689 pushPopMenu.addSeparator()
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
690 pushPopMenu.addAction(self.hgQueueGotoAct)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
691
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
692 pushPopForceMenu = QMenu(self.tr("Push/Pop (force)"), menu)
1073
9f0c4b4eccb1 Made a few of the Mercurial menus tearable.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1068
diff changeset
693 pushPopForceMenu.setTearOffEnabled(True)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
694 pushPopForceMenu.addAction(self.hgQueuePushForceAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
695 pushPopForceMenu.addAction(self.hgQueuePushUntilForceAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
696 pushPopForceMenu.addAction(self.hgQueuePushAllForceAct)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
697 pushPopForceMenu.addSeparator()
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
698 pushPopForceMenu.addAction(self.hgQueuePopForceAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
699 pushPopForceMenu.addAction(self.hgQueuePopUntilForceAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
700 pushPopForceMenu.addAction(self.hgQueuePopAllForceAct)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
701 pushPopForceMenu.addSeparator()
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
702 pushPopForceMenu.addAction(self.hgQueueGotoForceAct)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
703
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
704 guardsMenu = QMenu(self.tr("Guards"), menu)
1073
9f0c4b4eccb1 Made a few of the Mercurial menus tearable.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1068
diff changeset
705 guardsMenu.setTearOffEnabled(True)
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
706 guardsMenu.addAction(self.hgQueueDefineGuardsAct)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
707 guardsMenu.addAction(self.hgQueueDropAllGuardsAct)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
708 guardsMenu.addSeparator()
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
709 guardsMenu.addAction(self.hgQueueListGuardsAct)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
710 guardsMenu.addAction(self.hgQueueListAllGuardsAct)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
711 guardsMenu.addSeparator()
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
712 guardsMenu.addAction(self.hgQueueActivateGuardsAct)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
713 guardsMenu.addAction(self.hgQueueDeactivateGuardsAct)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
714 guardsMenu.addSeparator()
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
715 guardsMenu.addAction(self.hgQueueIdentifyActiveGuardsAct)
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
716
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
717 queuesMenu = QMenu(self.tr("Queue Management"), menu)
1073
9f0c4b4eccb1 Made a few of the Mercurial menus tearable.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1068
diff changeset
718 queuesMenu.setTearOffEnabled(True)
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
719 queuesMenu.addAction(self.hgQueueCreateQueueAct)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
720 queuesMenu.addAction(self.hgQueueRenameQueueAct)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
721 queuesMenu.addAction(self.hgQueueDeleteQueueAct)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
722 queuesMenu.addAction(self.hgQueuePurgeQueueAct)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
723 queuesMenu.addSeparator()
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
724 queuesMenu.addAction(self.hgQueueActivateQueueAct)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
725 queuesMenu.addSeparator()
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
726 queuesMenu.addAction(self.hgQueueListQueuesAct)
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
727
2815
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
728 menu.addAction(self.hgQueueInitAct)
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
729 menu.addAction(self.hgQueueCommitAct)
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
730 menu.addSeparator()
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
731 menu.addAction(self.hgQueueNewAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
732 menu.addAction(self.hgQueueRefreshAct)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
733 menu.addAction(self.hgQueueRefreshMessageAct)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
734 menu.addAction(self.hgQueueFinishAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
735 menu.addSeparator()
2815
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
736 menu.addAction(self.hgQueueStatusAct)
53c1d1f9ec86 Started to implement support for Mercurial queue repositories.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2763
diff changeset
737 menu.addSeparator()
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
738 menu.addAction(self.hgQueueDiffAct)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
739 menu.addAction(self.hgQueueHeaderAct)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
740 menu.addSeparator()
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
741 menu.addAction(self.hgQueueListAct)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
742 menu.addSeparator()
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
743 menu.addMenu(pushPopMenu)
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
744 menu.addMenu(pushPopForceMenu)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
745 menu.addSeparator()
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
746 menu.addAction(self.hgQueueRenameAct)
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
747 menu.addAction(self.hgQueueDeleteAct)
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
748 menu.addSeparator()
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
749 menu.addAction(self.hgQueueFoldAct)
1046
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
750 menu.addSeparator()
5dd14be5d6a1 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1036
diff changeset
751 menu.addMenu(guardsMenu)
1053
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
752 menu.addSeparator()
c54aa980ea8e Added an interface to the Mercurial patch queue management.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1047
diff changeset
753 menu.addMenu(queuesMenu)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
754
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
755 return menu
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
756
1074
ed2585464f12 Changed the logic of the Mercurials extension menu creation.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1073
diff changeset
757 def menuTitle(self):
ed2585464f12 Changed the logic of the Mercurials extension menu creation.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1073
diff changeset
758 """
ed2585464f12 Changed the logic of the Mercurials extension menu creation.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1073
diff changeset
759 Public method to get the menu title.
1087
fb8cd56819a9 Changed the Mercurial extension interface code to use custom base classes instead of inheriting QObject directly.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1074
diff changeset
760
fb8cd56819a9 Changed the Mercurial extension interface code to use custom base classes instead of inheriting QObject directly.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1074
diff changeset
761 @return title of the menu (string)
1074
ed2585464f12 Changed the logic of the Mercurials extension menu creation.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1073
diff changeset
762 """
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
763 return self.tr("Queues")
1074
ed2585464f12 Changed the logic of the Mercurials extension menu creation.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1073
diff changeset
764
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
765 def __hgQueueNewPatch(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
766 """
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
767 Private slot used to create a new named patch.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
768 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
769 self.vcs.getExtensionObject("mq")\
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
770 .hgQueueNewPatch(self.project.getProjectPath())
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
771
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
772 def __hgQueueRefreshPatch(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
773 """
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
774 Private slot used to refresh the current patch.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
775 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
776 self.vcs.getExtensionObject("mq")\
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
777 .hgQueueRefreshPatch(self.project.getProjectPath())
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
778
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
779 def __hgQueueRefreshPatchMessage(self):
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
780 """
2763
e4794166ad70 Fixed a serious typo.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2632
diff changeset
781 Private slot used to refresh the current patch and its commit message.
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
782 """
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
783 self.vcs.getExtensionObject("mq")\
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
784 .hgQueueRefreshPatch(self.project.getProjectPath(),
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
785 editMessage=True)
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
786
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
787 def __hgQueueShowPatch(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
788 """
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
789 Private slot used to show the contents of the current patch.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
790 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
791 self.vcs.getExtensionObject("mq")\
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
792 .hgQueueShowPatch(self.project.getProjectPath())
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
793
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
794 def __hgQueueShowHeader(self):
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
795 """
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
796 Private slot used to show the commit message of the current patch.
1035
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
797 """
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
798 self.vcs.getExtensionObject("mq")\
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
799 .hgQueueShowHeader(self.project.getProjectPath())
2cd7817ac659 Continued with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1034
diff changeset
800
1068
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
801 def __hgQueuePushPopPatches(self, name, operation, all=False, named=False,
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
802 force=False):
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
803 """
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
804 Private method to push patches onto the stack or pop patches off the
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
805 stack.
1068
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
806
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
807 @param name file/directory name (string)
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
808 @param operation operation type to be performed (Queues.POP,
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
809 Queues.PUSH, Queues.GOTO)
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
810 @keyparam all flag indicating to push/pop all (boolean)
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
811 @keyparam named flag indicating to push/pop until a named patch
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
812 is at the top of the stack (boolean)
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
813 @keyparam force flag indicating a forceful pop (boolean)
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
814 """
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
815 shouldReopen = self.vcs.getExtensionObject("mq")\
3008
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
816 .hgQueuePushPopPatches(name, operation=operation, all=all,
7848489bcb92 Continued to shorten the code lines to max. 79 characters.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 2962
diff changeset
817 named=named, force=force)
1068
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
818 if shouldReopen:
3020
542e97d4ecb3 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3008
diff changeset
819 res = E5MessageBox.yesNo(
542e97d4ecb3 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3008
diff changeset
820 None,
3190
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
821 self.tr("Changing Applied Patches"),
a9a94491c4fd Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3160
diff changeset
822 self.tr("""The project should be reread. Do this now?"""),
1068
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
823 yesDefault=True)
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
824 if res:
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
825 self.project.reopenProject()
090e5be55051 Change qpush/qpop/qgoto code to be able to detect changes of the project file (in case MQ will report the changed files one day).
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1066
diff changeset
826
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
827 def __hgQueuePushPatch(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
828 """
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
829 Private slot used to push the next patch onto the stack.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
830 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
831 self.__hgQueuePushPopPatches(
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
832 self.project.getProjectPath(),
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
833 operation=Queues.PUSH, all=False, named=False)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
834
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
835 def __hgQueuePushPatchForced(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
836 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
837 Private slot used to push the next patch onto the stack on top
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
838 of local changes.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
839 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
840 self.__hgQueuePushPopPatches(
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
841 self.project.getProjectPath(),
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
842 operation=Queues.PUSH, all=False, named=False, force=True)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
843
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
844 def __hgQueuePushAllPatches(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
845 """
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
846 Private slot used to push all patches onto the stack.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
847 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
848 self.__hgQueuePushPopPatches(
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
849 self.project.getProjectPath(),
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
850 operation=Queues.PUSH, all=True, named=False)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
851
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
852 def __hgQueuePushAllPatchesForced(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
853 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
854 Private slot used to push all patches onto the stack on top
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
855 of local changes.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
856 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
857 self.__hgQueuePushPopPatches(
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
858 self.project.getProjectPath(),
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
859 operation=Queues.PUSH, all=True, named=False, force=True)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
860
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
861 def __hgQueuePushPatches(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
862 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
863 Private slot used to push patches onto the stack until a named
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
864 one is at the top.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
865 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
866 self.__hgQueuePushPopPatches(
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
867 self.project.getProjectPath(),
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
868 operation=Queues.PUSH, all=False, named=True)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
869
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
870 def __hgQueuePushPatchesForced(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
871 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
872 Private slot used to push patches onto the stack until a named
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
873 one is at the top on top of local changes.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
874 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
875 self.__hgQueuePushPopPatches(
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
876 self.project.getProjectPath(),
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
877 operation=Queues.PUSH, all=False, named=True, force=True)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
878
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
879 def __hgQueuePopPatch(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
880 """
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
881 Private slot used to pop the current patch off the stack.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
882 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
883 self.__hgQueuePushPopPatches(
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
884 self.project.getProjectPath(),
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
885 operation=Queues.POP, all=False, named=False)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
886
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
887 def __hgQueuePopPatchForced(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
888 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
889 Private slot used to pop the current patch off the stack forgetting
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
890 any local changes to patched files.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
891 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
892 self.__hgQueuePushPopPatches(
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
893 self.project.getProjectPath(),
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
894 operation=Queues.POP, all=False, named=False, force=True)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
895
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
896 def __hgQueuePopAllPatches(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
897 """
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
898 Private slot used to pop all patches off the stack.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
899 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
900 self.__hgQueuePushPopPatches(
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
901 self.project.getProjectPath(),
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
902 operation=Queues.POP, all=True, named=False)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
903
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
904 def __hgQueuePopAllPatchesForced(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
905 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
906 Private slot used to pop all patches off the stack forgetting
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
907 any local changes to patched files.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
908 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
909 self.__hgQueuePushPopPatches(
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
910 self.project.getProjectPath(),
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
911 operation=Queues.POP, all=True, named=False, force=True)
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
912
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
913 def __hgQueuePopPatches(self):
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
914 """
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
915 Private slot used to pop patches off the stack until a named
1061
3e21869872e3 Fixed PEP-8 related issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 1053
diff changeset
916 one is at the top.
1034
8a7fa049e9d3 Started with support for Mercurial queues extension.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff changeset
917 """
3023
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
918 self.__hgQueuePushPopPatches(
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
919 self.project.getProjectPath(),
34ce20603bf7 Fixed a bunch of visible indentation issues.
Detlev Offenbach <detlev@die-offenbachs.de>
parents: 3020
diff changeset
920 operation=Queues.POP, all=False, named=True)
1034
8a7fa049e9d3 Started with support for Mercurial queues ext