diff options
| author | Peter Penz <[email protected]> | 2008-02-14 21:35:57 +0000 |
|---|---|---|
| committer | Peter Penz <[email protected]> | 2008-02-14 21:35:57 +0000 |
| commit | 227ebb98eb03ae3b676c1459533d3522543818da (patch) | |
| tree | bf4104982ad70468d18ffd1f637a2b74888e777d /src | |
| parent | e43bc5a6f6db5bedf491710b1d68855ab52d36c7 (diff) | |
display an error message if the the user tries to set an invalid home URL in the settings dialog
svn path=/trunk/KDE/kdebase/apps/; revision=775098
Diffstat (limited to 'src')
| -rw-r--r-- | src/startupsettingspage.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/startupsettingspage.cpp b/src/startupsettingspage.cpp index e3f237ca9..a7c62254e 100644 --- a/src/startupsettingspage.cpp +++ b/src/startupsettingspage.cpp @@ -29,6 +29,7 @@ #include <kdialog.h> #include <kfiledialog.h> #include <klocale.h> +#include <kmessagebox.h> #include <kvbox.h> #include <QCheckBox> @@ -103,9 +104,11 @@ void StartupSettingsPage::applySettings() GeneralSettings* settings = DolphinSettings::instance().generalSettings(); const KUrl url(m_homeUrl->text()); - KFileItem fileItem(S_IFDIR, KFileItem::Unknown, url); + KFileItem fileItem(KFileItem::Unknown, KFileItem::Unknown, url); if (url.isValid() && fileItem.isDir()) { settings->setHomeUrl(url.prettyUrl()); + } else { + KMessageBox::error(this, i18n("The location for the home folder is invalid and will not get applied.")); } settings->setSplitView(m_splitView->isChecked()); |
