summaryrefslogtreecommitdiffstats
path: root/kioslave/media/mounthelper
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2012-05-25 22:05:06 -0500
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2012-05-25 22:05:06 -0500
commite13c01e6863b7384e70f10068c6b76c1d24d9945 (patch)
treeab0ce94f927b81b0c1fc6b963bb11145f33f9ac7 /kioslave/media/mounthelper
parentf70bd6c7c09395d93474424371b40b0db7a76bd2 (diff)
downloadtdebase-e13c01e6863b7384e70f10068c6b76c1d24d9945.tar.gz
tdebase-e13c01e6863b7384e70f10068c6b76c1d24d9945.zip
Clean up ugly error message
Diffstat (limited to 'kioslave/media/mounthelper')
-rw-r--r--kioslave/media/mounthelper/kio_media_mounthelper.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/kioslave/media/mounthelper/kio_media_mounthelper.cpp b/kioslave/media/mounthelper/kio_media_mounthelper.cpp
index 07588e867..7a2b2b78f 100644
--- a/kioslave/media/mounthelper/kio_media_mounthelper.cpp
+++ b/kioslave/media/mounthelper/kio_media_mounthelper.cpp
@@ -208,7 +208,7 @@ void MountHelper::ejectFinished(KProcess* proc)
else
m_errorStr = i18n("The device was successfully unmounted, but could not be ejected");
}
-//X Comment this because the error is useless as long as the unmount is successfull.
+//X Comment this because the error is useless as long as the unmount is successful.
//X TQTimer::singleShot(0, this, TQT_SLOT(error()));
::exit(0);
}
@@ -216,7 +216,13 @@ void MountHelper::ejectFinished(KProcess* proc)
void MountHelper::error()
{
- KMessageBox::error(0, m_errorStr);
+ TQString prettyErrorString = m_errorStr;
+ if (m_errorStr.contains("<") && m_errorStr.contains(">")) {
+ if (!m_errorStr.contains("<qt>")) {
+ prettyErrorString = TQString("<qt>%1</qt>").arg(m_errorStr);
+ }
+ }
+ KMessageBox::error(0, prettyErrorString);
::exit(1);
}