diff options
Diffstat (limited to 'src/frontend/bookshelfmanager/btmodulemanagerdialog.cpp')
-rw-r--r-- | src/frontend/bookshelfmanager/btmodulemanagerdialog.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/frontend/bookshelfmanager/btmodulemanagerdialog.cpp b/src/frontend/bookshelfmanager/btmodulemanagerdialog.cpp index 42febaa..8eebde6 100644 --- a/src/frontend/bookshelfmanager/btmodulemanagerdialog.cpp +++ b/src/frontend/bookshelfmanager/btmodulemanagerdialog.cpp @@ -2,20 +2,24 @@ * * This file is part of BibleTime's source code, http://www.bibletime.info/. * -* Copyright 1999-2011 by the BibleTime developers. +* Copyright 1999-2014 by the BibleTime developers. * The BibleTime source code is licensed under the GNU General Public License version 2.0. * **********/ #include "frontend/bookshelfmanager/btmodulemanagerdialog.h" -#include "backend/config/cbtconfig.h" +#include "backend/config/btconfig.h" #include "backend/managers/cswordbackend.h" #include "frontend/bookshelfmanager/indexpage/btindexpage.h" #include "frontend/bookshelfmanager/installpage/btinstallpage.h" #include "frontend/bookshelfmanager/removepage/btremovepage.h" +namespace { +const QString GeometryKey = "GUI/BookshelfManager/ModuleManagerDialog/geometry"; +} // anonymous namespace + static BtModuleManagerDialog *m_staticModuleManagerDialog = 0; BtModuleManagerDialog* BtModuleManagerDialog::getInstance(QWidget *parent, @@ -59,13 +63,9 @@ BtModuleManagerDialog::~BtModuleManagerDialog() { } void BtModuleManagerDialog::loadDialogSettings() { - resize(CBTConfig::get(CBTConfig::bookshelfWidth), CBTConfig::get(CBTConfig::bookshelfHeight)); - move(CBTConfig::get(CBTConfig::bookshelfPosX), CBTConfig::get(CBTConfig::bookshelfPosY)); + restoreGeometry(btConfig().value<QByteArray>(GeometryKey, QByteArray())); } void BtModuleManagerDialog::saveDialogSettings() const { - CBTConfig::set(CBTConfig::bookshelfWidth, size().width()); - CBTConfig::set(CBTConfig::bookshelfHeight, size().height()); - CBTConfig::set(CBTConfig::bookshelfPosX, x()); - CBTConfig::set(CBTConfig::bookshelfPosY, y()); + btConfig().setValue(GeometryKey, saveGeometry()); } |