comparison src/mainwindow.cpp @ 530:2262f753b19e

Add more useful message for merge with working directory ancestor
author Chris Cannam
date Wed, 23 Nov 2011 11:24:23 +0000
parents 49bddabad719
children a4e699d32a9a
comparison
equal deleted inserted replaced
529:4276c7923d65 530:2262f753b19e
2208 // external program, unlikely to be anything useful in stderr 2208 // external program, unlikely to be anything useful in stderr
2209 // and some return with failure codes when something as basic 2209 // and some return with failure codes when something as basic
2210 // as the user closing the window via the wm happens 2210 // as the user closing the window via the wm happens
2211 return; 2211 return;
2212 case ACT_MERGE: 2212 case ACT_MERGE:
2213 if (output.contains("working directory ancestor")) {
2214 // arguably we should prevent this upfront, but that's
2215 // trickier!
2216 MoreInformationDialog::information
2217 (this, tr("Merge"), tr("Merge has no effect"),
2218 tr("You asked to merge a revision with one of its ancestors.<p>This has no effect, because the ancestor's changes already exist in both revisions."),
2219 output);
2220 return;
2221 }
2222 // else fall through
2213 case ACT_RETRY_MERGE: 2223 case ACT_RETRY_MERGE:
2214 MoreInformationDialog::information 2224 MoreInformationDialog::information
2215 (this, tr("Merge"), tr("Merge failed"), 2225 (this, tr("Merge"), tr("Merge failed"),
2216 tr("Some files were not merged successfully.<p>You can Merge again to repeat the interactive merge; use Revert to abandon the merge entirely; or edit the files that are in conflict in an editor and, when you are happy with them, choose Mark Resolved in each file's right-button menu."), 2226 tr("Some files were not merged successfully.<p>You can Merge again to repeat the interactive merge; use Revert to abandon the merge entirely; or edit the files that are in conflict in an editor and, when you are happy with them, choose Mark Resolved in each file's right-button menu."),
2217 output); 2227 output);