diff --git a/dolphin/src/dolphinpart.cpp b/dolphin/src/dolphinpart.cpp index 7c0382ec..e1b779e6 100644 --- a/dolphin/src/dolphinpart.cpp +++ b/dolphin/src/dolphinpart.cpp @@ -27,7 +27,6 @@ #include #include #include -#include #include #include #include @@ -196,9 +195,6 @@ void DolphinPart::createActions() createGoAction("go_trash", "user-trash", i18nc("@action:inmenu Go", "Trash"), QString("trash:/"), goActionGroup); - createGoAction("go_autostart", "", - i18nc("@action:inmenu Go", "Autostart"), KGlobalSettings::autostartPath(), - goActionGroup); // Tools menu m_findFileAction = actionCollection()->addAction("find_file"); diff --git a/kcontrol/desktoppaths/globalpaths.cpp b/kcontrol/desktoppaths/globalpaths.cpp index ef04ecba..d66b7e61 100644 --- a/kcontrol/desktoppaths/globalpaths.cpp +++ b/kcontrol/desktoppaths/globalpaths.cpp @@ -84,13 +84,6 @@ DesktopPathConfig::DesktopPathConfig(QWidget *parent, const QVariantList &) " folder if you want to, and the contents will move automatically" " to the new location as well.")); - urAutostart = addRow(lay, i18n("Autostart path:"), - i18n("This folder contains applications or" - " links to applications (shortcuts) that you want to have started" - " automatically whenever KDE starts. You can change the location of this" - " folder if you want to, and the contents will move automatically" - " to the new location as well.")); - urDocument = addRow(lay, i18n("Documents path:"), i18n("This folder will be used by default to " "load or save documents from or to.")); @@ -127,7 +120,6 @@ void DesktopPathConfig::load() { // Desktop Paths urDesktop->setUrl( KGlobalSettings::desktopPath() ); - urAutostart->setUrl( KGlobalSettings::autostartPath() ); urDocument->setUrl( KGlobalSettings::documentPath() ); urDownload->setUrl( KGlobalSettings::downloadPath() ); urMovie->setUrl( KGlobalSettings::videosPath() ); @@ -140,7 +132,6 @@ void DesktopPathConfig::defaults() { // Desktop Paths - keep defaults in sync with kglobalsettings.cpp urDesktop->setUrl( QString(QDir::homePath() + "/Desktop") ); - urAutostart->setUrl( QString(KGlobal::dirs()->localkdedir() + "Autostart/") ); urDocument->setUrl( QString(QDir::homePath() + "/Documents") ); urDownload->setUrl( QString(QDir::homePath() + "/Downloads") ); urMovie->setUrl( QString(QDir::homePath() + "/Movies") ); @@ -194,13 +185,9 @@ void DesktopPathConfig::save() KConfigGroup configGroup( config, "Paths" ); bool pathChanged = false; - bool autostartMoved = false; KUrl desktopURL( KGlobalSettings::desktopPath() ); - KUrl autostartURL( KGlobalSettings::autostartPath() ); - KUrl newAutostartURL = urAutostart->url(); - if ( !urDesktop->url().equals( desktopURL, KUrl::CompareWithoutTrailingSlash ) ) { // Test which other paths were inside this one (as it is by default) @@ -213,30 +200,6 @@ void DesktopPathConfig::save() if ( !urlDesktop.endsWith('/')) urlDesktop+='/'; - if ( desktopURL.isParentOf( autostartURL ) ) - { - kDebug() << "Autostart is on the desktop"; - - // Either the Autostart field wasn't changed (-> need to update it) - if ( newAutostartURL.equals( autostartURL, KUrl::CompareWithoutTrailingSlash ) ) - { - // Hack. It could be in a subdir inside desktop. Hmmm... Argl. - urAutostart->setUrl( QString(urlDesktop + "Autostart/") ); - kDebug() << "Autostart is moved with the desktop"; - autostartMoved = true; - } - // or it has been changed (->need to move it from here) - else - { - KUrl futureAutostartURL; - futureAutostartURL.setUrl( urlDesktop + "Autostart/" ); - if ( newAutostartURL.equals( futureAutostartURL, KUrl::CompareWithoutTrailingSlash ) ) - autostartMoved = true; - else - autostartMoved = moveDir( KUrl( KGlobalSettings::autostartPath() ), KUrl( urAutostart->url() ), i18n("Autostart") ); - } - } - if ( moveDir( KUrl( KGlobalSettings::desktopPath() ), KUrl( urlDesktop ), i18n("Desktop") ) ) { //save in XDG path @@ -248,17 +211,6 @@ void DesktopPathConfig::save() } } - if ( !newAutostartURL.equals( autostartURL, KUrl::CompareWithoutTrailingSlash ) ) - { - if (!autostartMoved) - autostartMoved = moveDir( KUrl( KGlobalSettings::autostartPath() ), KUrl( urAutostart->url() ), i18n("Autostart") ); - if (autostartMoved) - { - configGroup.writePathEntry( "Autostart", urAutostart->url().toLocalFile(), KConfigBase::Normal | KConfigBase::Global ); - pathChanged = true; - } - } - config->sync(); if (xdgSavePath(urDocument, KGlobalSettings::documentPath(), "XDG_DOCUMENTS_DIR", i18n("Documents"))) diff --git a/kcontrol/desktoppaths/globalpaths.h b/kcontrol/desktoppaths/globalpaths.h index 848ea713..b27224e9 100644 --- a/kcontrol/desktoppaths/globalpaths.h +++ b/kcontrol/desktoppaths/globalpaths.h @@ -64,7 +64,6 @@ private: // Desktop Paths KUrlRequester *urDesktop; - KUrlRequester *urAutostart; KUrlRequester *urDocument; KUrlRequester *urDownload; KUrlRequester *urMovie; diff --git a/libs/plasmagenericshell/scripting/scriptengine.cpp b/libs/plasmagenericshell/scripting/scriptengine.cpp index 82259bc6..117297ce 100644 --- a/libs/plasmagenericshell/scripting/scriptengine.cpp +++ b/libs/plasmagenericshell/scripting/scriptengine.cpp @@ -388,8 +388,6 @@ QScriptValue ScriptEngine::userDataPath(QScriptContext *context, QScriptEngine * if (type.compare("desktop", Qt::CaseInsensitive) == 0) { return KGlobalSettings::desktopPath(); - } else if (type.compare("autostart", Qt::CaseInsensitive) == 0) { - return KGlobalSettings::autostartPath(); } else if (type.compare("documents", Qt::CaseInsensitive) == 0) { return KGlobalSettings::documentPath(); } else if (type.compare("music", Qt::CaseInsensitive) == 0) { diff --git a/plasma/scriptengine/common/extension_io.cpp b/plasma/scriptengine/common/extension_io.cpp index 7e43efff..02a83653 100644 --- a/plasma/scriptengine/common/extension_io.cpp +++ b/plasma/scriptengine/common/extension_io.cpp @@ -171,8 +171,6 @@ QScriptValue ScriptEnv::userDataPath(QScriptContext *context, QScriptEngine *eng if (type.compare("desktop", Qt::CaseInsensitive) == 0) { return KGlobalSettings::desktopPath(); - } else if (type.compare("autostart", Qt::CaseInsensitive) == 0) { - return KGlobalSettings::autostartPath(); } else if (type.compare("documents", Qt::CaseInsensitive) == 0) { return KGlobalSettings::documentPath(); } else if (type.compare("music", Qt::CaseInsensitive) == 0) {