1
0
mirror of https://invent.kde.org/system/dolphin synced 2024-07-04 17:30:55 +00:00

update to changes in class KGlobal (kdelibs)

svn path=/trunk/playground/utils/dolphin/; revision=628641
This commit is contained in:
Peter Penz 2007-01-30 19:31:37 +00:00
parent d71de955f4
commit e181654494
3 changed files with 7 additions and 6 deletions

View File

@ -324,7 +324,7 @@ void DolphinMainWindow::closeEvent(QCloseEvent* event)
// TODO: I assume there will be a generic way in KDE 4 to store the docks
// of the main window. In the meantime they are stored manually:
QString filename = KStandardDirs::locateLocal("data", KGlobal::instance()->instanceName());
QString filename = KStandardDirs::locateLocal("data", KGlobal::mainComponent().componentName());
filename.append("/panels_layout");
QFile file(filename);
if (file.open(QIODevice::WriteOnly)) {
@ -924,8 +924,7 @@ void DolphinMainWindow::loadSettings()
// TODO: I assume there will be a generic way in KDE 4 to restore the docks
// of the main window. In the meantime they are restored manually (see also
// DolphinMainWindow::closeEvent() for more details):
QString filename = KStandardDirs::locateLocal("data", KGlobal::instance()->instanceName());
filename.append("/panels_layout");
QString filename = KStandardDirs::locateLocal("data", KGlobal::mainComponent().componentName()); filename.append("/panels_layout");
QFile file(filename);
if (file.open(QIODevice::ReadOnly)) {
QByteArray data = file.readAll();

View File

@ -25,6 +25,7 @@
#include <kbookmark.h>
#include <kbookmarkmanager.h>
#include <kcomponentdata.h>
#include <kicontheme.h>
#include <kinstance.h>
#include <klocale.h>
@ -63,7 +64,7 @@ KBookmark DolphinSettings::bookmark(int index) const
KBookmarkManager* DolphinSettings::bookmarkManager() const
{
QString basePath = KGlobal::instance()->instanceName();
QString basePath = KGlobal::mainComponent().componentName();
basePath.append("/bookmarks.xml");
const QString file = KStandardDirs::locateLocal("data", basePath);
@ -76,7 +77,7 @@ void DolphinSettings::save()
m_iconsModeSettings->writeConfig();
m_detailsModeSettings->writeConfig();
QString basePath = KGlobal::instance()->instanceName();
QString basePath = KGlobal::mainComponent().componentName();
basePath.append("/bookmarks.xml");
const QString file = KStandardDirs::locateLocal( "data", basePath);

View File

@ -23,6 +23,7 @@
#include <QDateTime>
#include <QFile>
#include <kcomponentdata.h>
#include <klocale.h>
#include <kstandarddirs.h>
#include <kurl.h>
@ -178,7 +179,7 @@ void ViewProperties::save()
QString ViewProperties::destinationDir(const QString& subDir) const
{
QString basePath = KGlobal::instance()->instanceName();
QString basePath = KGlobal::mainComponent().componentName();
basePath.append("/view_properties/").append(subDir);
return KStandardDirs::locateLocal("data", basePath);
}