diff options
author | François Andriot <albator78@libertysurf.fr> | 2014-06-12 14:17:21 +0900 |
---|---|---|
committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2014-06-12 14:17:21 +0900 |
commit | 5723220017e3dfbd02136d58c0fc7032d7a0a2ca (patch) | |
tree | 5a23dbb42cde8f114a22e59db78e6e846b8204ae /kicker | |
parent | 134b34ee503a241bc00a2f2f1d3c15b29d7d5966 (diff) | |
download | tdebase-5723220017e3dfbd02136d58c0fc7032d7a0a2ca.tar.gz tdebase-5723220017e3dfbd02136d58c0fc7032d7a0a2ca.zip |
Added Music, Pictures, Videos and Download folders to the Computer tab in kickoff menu.
This relates to bug 1499.
Diffstat (limited to 'kicker')
-rw-r--r-- | kicker/kicker/ui/k_new_mnu.cpp | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/kicker/kicker/ui/k_new_mnu.cpp b/kicker/kicker/ui/k_new_mnu.cpp index 1aa68a9aa..500bc5485 100644 --- a/kicker/kicker/ui/k_new_mnu.cpp +++ b/kicker/kicker/ui/k_new_mnu.cpp @@ -1436,6 +1436,42 @@ void KMenu::insertStaticItems() m_systemView->insertItem( "folder_man", i18n( "My Documents" ), documentPath, documentPath, nId++, index++ ); } + if ( TDEStandardDirs::exists( TDEGlobalSettings::picturesPath() + "/" ) ) + { + TQString picturesPath = TDEGlobalSettings::picturesPath(); + if ( picturesPath.endsWith( "/" ) ) + picturesPath = picturesPath.left( picturesPath.length() - 1 ); + if (picturesPath!=TQDir::homeDirPath()) + m_systemView->insertItem( "folder_image", i18n( "My Images" ), picturesPath, picturesPath, nId++, index++ ); + } + + if ( TDEStandardDirs::exists( TDEGlobalSettings::musicPath() + "/" ) ) + { + TQString musicPath = TDEGlobalSettings::musicPath(); + if ( musicPath.endsWith( "/" ) ) + musicPath = musicPath.left( musicPath.length() - 1 ); + if (musicPath!=TQDir::homeDirPath()) + m_systemView->insertItem( "folder_sound", i18n( "My Music" ), musicPath, musicPath, nId++, index++ ); + } + + if ( TDEStandardDirs::exists( TDEGlobalSettings::videosPath() + "/" ) ) + { + TQString videosPath = TDEGlobalSettings::videosPath(); + if ( videosPath.endsWith( "/" ) ) + videosPath = videosPath.left( videosPath.length() - 1 ); + if (videosPath!=TQDir::homeDirPath()) + m_systemView->insertItem( "folder_video", i18n( "My Videos" ), videosPath, videosPath, nId++, index++ ); + } + + if ( TDEStandardDirs::exists( TDEGlobalSettings::downloadPath() + "/" ) ) + { + TQString downloadPath = TDEGlobalSettings::downloadPath(); + if ( downloadPath.endsWith( "/" ) ) + downloadPath = downloadPath.left( downloadPath.length() - 1 ); + if (downloadPath!=TQDir::homeDirPath()) + m_systemView->insertItem( "folder_inbox", i18n( "My Downloads" ), downloadPath, downloadPath, nId++, index++ ); + } + m_systemView->insertItem( "network", i18n( "Network Folders" ), "remote:/", "remote:/", nId++, index++ ); |