836 self.hgImportAct.triggered[()].connect(self.__hgImport) |
836 self.hgImportAct.triggered[()].connect(self.__hgImport) |
837 self.actions.append(self.hgImportAct) |
837 self.actions.append(self.hgImportAct) |
838 |
838 |
839 self.hgExportAct = E5Action(self.trUtf8('Export Patches'), |
839 self.hgExportAct = E5Action(self.trUtf8('Export Patches'), |
840 self.trUtf8('Export Patches...'), |
840 self.trUtf8('Export Patches...'), |
841 0, 0, self, 'mercurial_import') |
841 0, 0, self, 'mercurial_export') |
842 self.hgExportAct.setStatusTip(self.trUtf8( |
842 self.hgExportAct.setStatusTip(self.trUtf8( |
843 'Export revisions to patch files' |
843 'Export revisions to patch files' |
844 )) |
844 )) |
845 self.hgExportAct.setWhatsThis(self.trUtf8( |
845 self.hgExportAct.setWhatsThis(self.trUtf8( |
846 """<b>Export Patches</b>""" |
846 """<b>Export Patches</b>""" |
847 """<p>This exports revisions of the project to patch files.</p>""" |
847 """<p>This exports revisions of the project to patch files.</p>""" |
848 )) |
848 )) |
849 self.hgExportAct.triggered[()].connect(self.__hgExport) |
849 self.hgExportAct.triggered[()].connect(self.__hgExport) |
850 self.actions.append(self.hgExportAct) |
850 self.actions.append(self.hgExportAct) |
|
851 |
|
852 self.hgPhaseAct = E5Action(self.trUtf8('Change Phase'), |
|
853 self.trUtf8('Change Phase...'), |
|
854 0, 0, self, 'mercurial_change_phase') |
|
855 self.hgPhaseAct.setStatusTip(self.trUtf8( |
|
856 'Change the phase of revisions' |
|
857 )) |
|
858 self.hgPhaseAct.setWhatsThis(self.trUtf8( |
|
859 """<b>Change Phase</b>""" |
|
860 """<p>This changes the phase of revisions.</p>""" |
|
861 )) |
|
862 self.hgPhaseAct.triggered[()].connect(self.__hgPhase) |
|
863 self.actions.append(self.hgPhaseAct) |
851 |
864 |
852 def initMenu(self, menu): |
865 def initMenu(self, menu): |
853 """ |
866 """ |
854 Public method to generate the VCS menu. |
867 Public method to generate the VCS menu. |
855 |
868 |
963 menu.addAction(self.vcsStatusAct) |
976 menu.addAction(self.vcsStatusAct) |
964 menu.addSeparator() |
977 menu.addSeparator() |
965 menu.addAction(self.vcsDiffAct) |
978 menu.addAction(self.vcsDiffAct) |
966 menu.addAction(self.hgExtDiffAct) |
979 menu.addAction(self.hgExtDiffAct) |
967 menu.addSeparator() |
980 menu.addSeparator() |
|
981 if self.vcs.version >= (2, 1): |
|
982 menu.addAction(self.hgPhaseAct) |
|
983 menu.addSeparator() |
968 menu.addAction(self.vcsRevertAct) |
984 menu.addAction(self.vcsRevertAct) |
969 menu.addAction(self.vcsMergeAct) |
985 menu.addAction(self.vcsMergeAct) |
970 menu.addAction(self.vcsResolveAct) |
986 menu.addAction(self.vcsResolveAct) |
971 menu.addSeparator() |
987 menu.addSeparator() |
972 menu.addAction(self.vcsSwitchAct) |
988 menu.addAction(self.vcsSwitchAct) |
1286 self.trUtf8("Revert Changes"), |
1302 self.trUtf8("Revert Changes"), |
1287 self.trUtf8("""The project should be reread. Do this now?"""), |
1303 self.trUtf8("""The project should be reread. Do this now?"""), |
1288 yesDefault=True) |
1304 yesDefault=True) |
1289 if res: |
1305 if res: |
1290 self.project.reopenProject() |
1306 self.project.reopenProject() |
|
1307 |
|
1308 def __hgPhase(self): |
|
1309 """ |
|
1310 Private slot used to change the phase of revisions. |
|
1311 """ |
|
1312 self.vcs.hgPhase(self.project.ppath) |
|
1313 |