Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 1.9, 1.9.1, and 1.9.2

repoview, repowidget: add qfinish to context menu

Finish the patches for the selected revision and all anscestors up to
and including qbase.

Changeset 060b95d5b22c

Parent bcd5bf01f114

by David Wilhelm

Changes to 2 files · Browse files at 060b95d5b22c Showing diff from parent bcd5bf01f114 Diff from another changeset...

 
129
130
131
 
 
132
133
134
 
182
183
184
 
 
 
185
186
187
 
196
197
198
 
199
200
201
 
129
130
131
132
133
134
135
136
 
184
185
186
187
188
189
190
191
192
 
201
202
203
204
205
206
207
@@ -129,6 +129,8 @@
  if 'mq' in exs:   a.append(('qimport', _('Import Revision to MQ'), None, None, None,   self.qimport)) + a.append(('qfinish', _('Finish patch'), None, None, None, + self.qfinish))   return a     def createActions(self): @@ -182,6 +184,9 @@
  def qimport(self):   self.emit(SIGNAL('qimportRevision'), self.current_rev)   + def qfinish(self): + self.emit(SIGNAL('qfinishRevision'), self.current_rev) +   def contextMenuEvent(self, event):   menu = QMenu(self)   for act in ['update', 'manifest', 'merge', 'tag', 'backout', @@ -196,6 +201,7 @@
  menu.addAction(self._actions['rebase'])   if 'mq' in exs:   menu.addAction(self._actions['qimport']) + menu.addAction(self._actions['qfinish'])   menu.exec_(event.globalPos())     def init_variables(self):
 
164
165
166
 
167
168
169
 
288
289
290
 
 
 
 
 
 
 
 
 
 
 
 
291
292
293
 
164
165
166
167
168
169
170
 
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
@@ -164,6 +164,7 @@
  connect(view, SIGNAL('copyHash'), self.copyHash)   connect(view, SIGNAL('rebaseRevision'), self.rebaseRevision)   connect(view, SIGNAL('qimportRevision'), self.qimportRevision) + connect(view, SIGNAL('qfinishRevision'), self.qfinishRevision)   #self.attachQuickBar(view.goto_toolbar)   gotoaction = view.goto_toolbar.toggleViewAction()   gotoaction.setIcon(geticon('goto')) @@ -288,6 +289,18 @@
  self.runner.commandFinished.connect(finished)   self.runner.run(cmdline)   + def qfinishRevision(self, rev): + """Finish applied patches up to and including selected revision""" + saved = self.setScanForRepoChanges(False) + cmdline = ['qfinish', 'qbase::%s' % rev, + '--repository', self.repo.root] + self.runner = cmdui.Runner(_('QFinish - TortoiseHg'), self) + def finished(ret): + self.reload() + self.setScanForRepoChanges(saved) + self.runner.commandFinished.connect(finished) + self.runner.run(cmdline) +   def revision_selected(self, rev):   if self.workbench.getCurentRepoRoot() != self.repo.root:   return