Plugins/VcsPlugins/vcsMercurial/ProjectBrowserHelper.py

changeset 3591
2f2a4a76dd22
parent 3586
6e3a6c5b58bf
child 3656
441956d8fce5
child 3810
ca370b397c9e
equal deleted inserted replaced
3590:5280e37405b8 3591:2f2a4a76dd22
85 .isTearOffMenuVisible()): 85 .isTearOffMenuVisible()):
86 self.__extensionMenus[extensionName][key].hideTearOffMenu() 86 self.__extensionMenus[extensionName][key].hideTearOffMenu()
87 87
88 def showContextMenu(self, menu, standardItems): 88 def showContextMenu(self, menu, standardItems):
89 """ 89 """
90 Slot called before the context menu is shown. 90 Public slot called before the context menu is shown.
91 91
92 It enables/disables the VCS menu entries depending on the overall 92 It enables/disables the VCS menu entries depending on the overall
93 VCS status and the file status. 93 VCS status and the file status.
94 94
95 @param menu reference to the menu to be shown 95 @param menu reference to the menu to be shown
116 act.setEnabled(True) 116 act.setEnabled(True)
117 self.__showExtensionMenu("mainMenu", controlled) 117 self.__showExtensionMenu("mainMenu", controlled)
118 118
119 def showContextMenuMulti(self, menu, standardItems): 119 def showContextMenuMulti(self, menu, standardItems):
120 """ 120 """
121 Slot called before the context menu (multiple selections) is shown. 121 Public slot called before the context menu (multiple selections) is
122 shown.
122 123
123 It enables/disables the VCS menu entries depending on the overall 124 It enables/disables the VCS menu entries depending on the overall
124 VCS status and the files status. 125 VCS status and the files status.
125 126
126 @param menu reference to the menu to be shown 127 @param menu reference to the menu to be shown
157 act.setEnabled(True) 158 act.setEnabled(True)
158 self.__showExtensionMenu("multiMenu", controlled) 159 self.__showExtensionMenu("multiMenu", controlled)
159 160
160 def showContextMenuDir(self, menu, standardItems): 161 def showContextMenuDir(self, menu, standardItems):
161 """ 162 """
162 Slot called before the context menu is shown. 163 Public slot called before the context menu is shown.
163 164
164 It enables/disables the VCS menu entries depending on the overall 165 It enables/disables the VCS menu entries depending on the overall
165 VCS status and the directory status. 166 VCS status and the directory status.
166 167
167 @param menu reference to the menu to be shown 168 @param menu reference to the menu to be shown
186 act.setEnabled(True) 187 act.setEnabled(True)
187 self.__showExtensionMenu("dirMenu", controlled) 188 self.__showExtensionMenu("dirMenu", controlled)
188 189
189 def showContextMenuDirMulti(self, menu, standardItems): 190 def showContextMenuDirMulti(self, menu, standardItems):
190 """ 191 """
191 Slot called before the context menu is shown. 192 Public slot called before the context menu is shown.
192 193
193 It enables/disables the VCS menu entries depending on the overall 194 It enables/disables the VCS menu entries depending on the overall
194 VCS status and the directory status. 195 VCS status and the directory status.
195 196
196 @param menu reference to the menu to be shown 197 @param menu reference to the menu to be shown
679 ## Menu handling methods below 680 ## Menu handling methods below
680 ########################################################################### 681 ###########################################################################
681 682
682 def __HgRevert(self): 683 def __HgRevert(self):
683 """ 684 """
684 Protected slot called by the context menu to revert changes made. 685 Private slot called by the context menu to revert changes made.
685 """ 686 """
686 names = [] 687 names = []
687 for itm in self.browser.getSelectedItems(): 688 for itm in self.browser.getSelectedItems():
688 try: 689 try:
689 name = itm.fileName() 690 name = itm.fileName()

eric ide

mercurial