changeset 312:f98c8ece3035

Merge from branch "new-branches-with-status-outside-tabs"
author Chris Cannam
date Tue, 01 Mar 2011 14:22:53 +0000
parents b8ed12c2035f (diff) 4811eb34e819 (current diff)
children 4b9656471303
files mainwindow.cpp
diffstat 1 files changed, 8 insertions(+), 16 deletions(-) [+]
line wrap: on
line diff
--- a/mainwindow.cpp	Tue Mar 01 14:22:29 2011 +0000
+++ b/mainwindow.cpp	Tue Mar 01 14:22:53 2011 +0000
@@ -1759,11 +1759,11 @@
         settings();
         return;
     case ACT_TEST_HG_EXT:
-        QMessageBox::warning
+        MoreInformationDialog::warning
             (this,
              tr("Failed to run Mercurial"),
              tr("Failed to run Mercurial with extension enabled"),
-             tr("The Mercurial program failed to run with the EasyMercurial interaction extension enabled.<br>This may indicate an installation problem with EasyMercurial.<br><br>You may be able to continue working if you switch off &ldquo;Use EasyHg Mercurial Extension&rdquo; in %1.  Note that remote repositories that require authentication may not work if you do this.").arg(setstr),
+             tr("The Mercurial program failed to run with the EasyMercurial interaction extension enabled.<br>This may indicate an installation problem.<br><br>You may be able to continue working if you switch off &ldquo;Use EasyHg Mercurial Extension&rdquo; in %1.  Note that remote repositories that require authentication might not work if you do this.").arg(setstr),
              output);
         settings();
         return;
@@ -1810,20 +1810,12 @@
         command += " " + arg;
     }
 
-    //!!!
-
-    QString message = tr("<qt><h3>Command failed</h3>"
-                         "<p>The following command failed:</p>"
-                         "<code>%1</code>"
-                         "%2</qt>")
-        .arg(command)
-        .arg((output.trimmed() != "") ?
-             tr("<p>Its output said:</p><code>%1</code>")
-             .arg(xmlEncode(output.left(800))
-                  .replace("\n", "<br>"))
-             : "");
-
-    QMessageBox::warning(this, tr("Command failed"), message);
+    MoreInformationDialog::warning
+        (this,
+         tr("Command failed"),
+         tr("Command failed"),
+         tr("A Mercurial command failed to run correctly.  This may indicate an installation problem or some other problem with EasyMercurial.<br><br>See &ldquo;More Details&rdquo; for the command output."),
+         output);
 }
 
 void MainWindow::commandCompleted(HgAction completedAction, QString output)