def linkActivated(self, cmd): if cmd == 'resolve': dlg = resolve.ResolveDialog(self._repoagent, self) dlg.exec_() self.checkResolve() elif cmd == 'commit': dlg = commit.CommitDialog(self._repoagent, [], {}, self) dlg.finished.connect(dlg.deleteLater) dlg.exec_() self.destcsinfo.update(self.repo['.']) self.checkStatus() elif cmd == 'discard': labels = [(QMessageBox.Yes, _('&Discard')), (QMessageBox.No, _('Cancel'))] if not qtlib.QuestionMsgBox( _('Confirm Discard'), _('Discard outstanding changes to working directory?'), labels=labels, parent=self): return def finished(ret): self.repo.decrementBusyCount() if ret == 0: self.checkStatus() cmdline = [ 'update', '--clean', '--repository', self.repo.root, '--rev', '.' ] self.runner = cmdui.Runner(True, self) self.runner.commandFinished.connect(finished) self.repo.incrementBusyCount() self.runner.run(cmdline)
def onLinkActivated(self, cmd): if cmd == 'resolve': dlg = resolve.ResolveDialog(self._repoagent, self) dlg.finished.connect(dlg.deleteLater) dlg.exec_() if self.autonext.isChecked(): self.tryAutoAdvance(True) self.completeChanged.emit()
def accept(self): for root, path, status in thgrepo.recursiveMergeStatus(self.repo): if status == 'u': qtlib.InfoMsgBox(_('Merge caused file conflicts'), _('File conflicts need to be resolved')) dlg = resolve.ResolveDialog(self._repoagent, self) dlg.finished.connect(dlg.deleteLater) dlg.exec_() break super(UpdateDialog, self).accept()
def resolve(ui, repoagent, *pats, **opts): """resolve dialog""" from tortoisehg.hgqt import resolve as resolvemod return resolvemod.ResolveDialog(repoagent)