mirror of
https://bitbucket.org/smil3y/kdelibs.git
synced 2025-02-24 10:52:49 +00:00
kutils: show error message if kcmshell4 is not found from KEMailDialog
Signed-off-by: Ivailo Monev <xakepa10@gmail.com>
This commit is contained in:
parent
6a3062953f
commit
4987a519ca
1 changed files with 7 additions and 1 deletions
|
@ -18,6 +18,7 @@
|
||||||
|
|
||||||
#include "kemaildialog.h"
|
#include "kemaildialog.h"
|
||||||
#include "klocale.h"
|
#include "klocale.h"
|
||||||
|
#include "kstandarddirs.h"
|
||||||
#include "kmessagebox.h"
|
#include "kmessagebox.h"
|
||||||
#include "kdebug.h"
|
#include "kdebug.h"
|
||||||
|
|
||||||
|
@ -203,8 +204,13 @@ bool KEMailDialog::setAttach(const QStringList &attach)
|
||||||
|
|
||||||
void KEMailDialog::_slotSettings()
|
void KEMailDialog::_slotSettings()
|
||||||
{
|
{
|
||||||
|
const QString kcmshell4exe = KStandardDirs::findExe(QString::fromLatin1("kcmshell4"));
|
||||||
|
if (kcmshell4exe.isEmpty()) {
|
||||||
|
KMessageBox::error(this, i18n("kcmshell4 not found"));
|
||||||
|
return;
|
||||||
|
}
|
||||||
QProcess::startDetached(
|
QProcess::startDetached(
|
||||||
QString::fromLatin1("kcmshell4"),
|
kcmshell4exe,
|
||||||
QStringList() << QString::fromLatin1("useraccount")
|
QStringList() << QString::fromLatin1("useraccount")
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue