-rw-r--r-- | pwmanager/pwmanager/configwnd.cpp | 11 | ||||
-rw-r--r-- | pwmanager/pwmanager/pwm.cpp | 35 | ||||
-rw-r--r-- | pwmanager/pwmanager/pwmanagerE.pro | 27 | ||||
-rw-r--r-- | pwmanager/pwmanager/pwmdoc.cpp | 2 | ||||
-rw-r--r-- | pwmanager/pwmanager/pwmdoc.h | 2 | ||||
-rw-r--r-- | pwmanager/pwmanager/pwmdocui.cpp | 1 | ||||
-rw-r--r-- | pwmanager/pwmanager/pwminit.cpp | 19 | ||||
-rw-r--r-- | pwmanager/pwmanager/pwmtray.cpp | 4 | ||||
-rw-r--r-- | pwmanager/pwmanager/pwmview.cpp | 4 | ||||
-rw-r--r-- | pwmanager/pwmanager/serializer.cpp | 1 |
10 files changed, 83 insertions, 23 deletions
diff --git a/pwmanager/pwmanager/configwnd.cpp b/pwmanager/pwmanager/configwnd.cpp index 230ca1b..108c40f 100644 --- a/pwmanager/pwmanager/configwnd.cpp +++ b/pwmanager/pwmanager/configwnd.cpp @@ -46,2 +46,3 @@ configWnd::configWnd( QWidget* parent, const char* name, bool modal, WFlags fl ) + ////////////////////////////// tab = new QWidget( tabWidget2, "tab" ); @@ -64,3 +65,3 @@ configWnd::configWnd( QWidget* parent, const char* name, bool modal, WFlags fl ) tabWidget2->insertTab( tab, QString("") ); - + ////////////////////////////////////// TabPage = new QWidget( tabWidget2, "TabPage" ); @@ -85,3 +86,3 @@ configWnd::configWnd( QWidget* parent, const char* name, bool modal, WFlags fl ) tabWidget2->insertTab( TabPage, QString("") ); - + ////////////////////////////////////// tab_2 = new QWidget( tabWidget2, "tab_2" ); @@ -105,3 +106,3 @@ configWnd::configWnd( QWidget* parent, const char* name, bool modal, WFlags fl ) tabWidget2->insertTab( tab_2, QString("") ); - + /////////////////////////////////////////// tab_3 = new QWidget( tabWidget2, "tab_3" ); @@ -120,3 +121,3 @@ configWnd::configWnd( QWidget* parent, const char* name, bool modal, WFlags fl ) tabWidget2->insertTab( tab_3, QString("") ); - + //////////////////////////////////////////// tab_4 = new QWidget( tabWidget2, "tab_4" ); @@ -137,3 +138,3 @@ configWnd::configWnd( QWidget* parent, const char* name, bool modal, WFlags fl ) tabWidget2->insertTab( tab_4, QString("") ); - + /////////////////////////////////////////////// tab_5 = new QWidget( tabWidget2, "tab_5" ); diff --git a/pwmanager/pwmanager/pwm.cpp b/pwmanager/pwmanager/pwm.cpp index e5579f8..08fcb25 100644 --- a/pwmanager/pwmanager/pwm.cpp +++ b/pwmanager/pwmanager/pwm.cpp @@ -30,2 +30,4 @@ #include <dcopclient.h> +#include "configwndimpl.h" +#include "configuration.h" #else @@ -33,2 +35,7 @@ #include <qmessagebox.h> +#include <pwmprefs.h> +#include <kpimglobalprefs.h> +#include <kcmconfigs/kcmpwmconfig.h> +#include <kcmconfigs/kcmkdepimconfig.h> +#include <kcmultidialog.h> #endif @@ -47,3 +54,2 @@ #include "pwminit.h" -#include "configwndimpl.h" #include "pwmprint.h" @@ -52,3 +58,2 @@ #include "findwndimpl.h" -#include "configuration.h" @@ -753,10 +758,26 @@ void PwM::config_slot() { - Configuration *conf = Configuration::obj(); - int oldStyle = conf->confWndMainViewStyle(); + int oldStyle = conf()->confWndMainViewStyle(); +#ifdef PWM_EMBEDDED + KCMultiDialog* ConfigureDialog = new KCMultiDialog( "PIM", this ,"pwmconfigdialog", true ); + + KCMPwmConfig* pwmcfg = new KCMPwmConfig( ConfigureDialog->getNewVBoxPage(i18n( "PwManager")) , "KCMPwmConfig" ); + ConfigureDialog->addModule(pwmcfg ); + KCMKdePimConfig* kdelibcfg = new KCMKdePimConfig( ConfigureDialog->getNewVBoxPage(i18n( "Global")) , "KCMKdeLibConfig" ); + ConfigureDialog->addModule(kdelibcfg ); + +#ifndef DESKTOP_VERSION + ConfigureDialog->showMaximized(); +#endif + if ( ConfigureDialog->exec() ) + KMessageBox::information( this, i18n("Some changes are only\neffective after a restart!\n") ); + delete ConfigureDialog; + +#else //PWM_EMBEDDED // display the configuration window (modal mode) - if (!conf->showConfWnd(this)) + if (!conf()->showConfWnd(this)) return; +#endif - int newStyle = conf->confWndMainViewStyle(); + int newStyle = conf()->confWndMainViewStyle(); // reinitialize tray @@ -795,3 +816,3 @@ void PwM::config_slot() // set the new font - pwm->curView()->setFont(conf->confGlobEntryFont()); + pwm->curView()->setFont(conf()->confGlobEntryFont()); ++i2; diff --git a/pwmanager/pwmanager/pwmanagerE.pro b/pwmanager/pwmanager/pwmanagerE.pro index 2cd69a5..5c29ea4 100644 --- a/pwmanager/pwmanager/pwmanagerE.pro +++ b/pwmanager/pwmanager/pwmanagerE.pro @@ -9,3 +9,3 @@ DESTDIR=$(QPEDIR)/bin -INCLUDEPATH += . ../../qtcompat ../../qtcompat/xml ../../microkde ../../microkde/kdecore ../../microkde/kdeui $(QPEDIR)/include +INCLUDEPATH += . ../../qtcompat ../../qtcompat/xml ../../libkdepim ../../microkde ../../microkde/kdecore ../../microkde/kdeui ../../microkde/kutils $(QPEDIR)/include DEFINES += PWM_EMBEDDED PWM_DEBUG @@ -13,2 +13,3 @@ LIBS += -lmicrokde LIBS += -lmicroqtcompat +LIBS += -lmicrokdepim LIBS += -L$(QPEDIR)/lib @@ -33,2 +34,6 @@ LIBS += $(QTOPIALIB) #HEADERS = \ +#configuration_31compat.h \ +#configuration.h \ +#configwnd.h \ +#configwndimpl.h \ #selftest.h @@ -45,6 +50,2 @@ compressbzip2.h \ compressgzip.h \ -configuration_31compat.h \ -configuration.h \ -configwnd.h \ -configwndimpl.h \ findwnd.h \ @@ -70,2 +71,3 @@ pwm.h \ pwminit.h \ +pwmprefs.h \ pwmprint.h \ @@ -85,6 +87,12 @@ subtbledit.h \ subtbleditimpl.h \ -waitwnd.h +waitwnd.h \ +kcmconfigs/kcmpwmconfig.h \ +kcmconfigs/pwmconfigwidget.h \ +#sources that need not be build #SOURCES = \ #advcommeditimpl.cpp \ +#configuration.cpp \ +#configwnd.cpp \ +#configwndimpl.cpp \ #configuration_31compat.cpp \ @@ -105,5 +113,2 @@ compressbzip2.cpp \ compressgzip.cpp \ -configuration.cpp \ -configwnd.cpp \ -configwndimpl.cpp \ findwnd.cpp \ @@ -128,2 +133,3 @@ pwmexception.cpp \ pwminit.cpp \ +pwmprefs.cpp \ pwmtray.cpp \ @@ -143,2 +149,5 @@ subtbleditimpl.cpp \ waitwnd.cpp \ +kcmconfigs/kcmpwmconfig.cpp \ +kcmconfigs/pwmconfigwidget.cpp \ + diff --git a/pwmanager/pwmanager/pwmdoc.cpp b/pwmanager/pwmanager/pwmdoc.cpp index 04af360..9fe4809 100644 --- a/pwmanager/pwmanager/pwmdoc.cpp +++ b/pwmanager/pwmanager/pwmdoc.cpp @@ -33,2 +33,4 @@ #else +#include "pwmprefs.h" +#include "kglobal.h" #endif diff --git a/pwmanager/pwmanager/pwmdoc.h b/pwmanager/pwmanager/pwmdoc.h index 9650d55..193247e 100644 --- a/pwmanager/pwmanager/pwmdoc.h +++ b/pwmanager/pwmanager/pwmdoc.h @@ -50,3 +50,2 @@ #include "pwmdocui.h" -#include "configuration.h" @@ -59,2 +58,3 @@ #ifndef PWM_EMBEDDED +#include "configuration.h" #else diff --git a/pwmanager/pwmanager/pwmdocui.cpp b/pwmanager/pwmanager/pwmdocui.cpp index b308b40..3993fa8 100644 --- a/pwmanager/pwmanager/pwmdocui.cpp +++ b/pwmanager/pwmanager/pwmdocui.cpp @@ -38,2 +38,3 @@ #include <qdir.h> +#include "pwmprefs.h" #endif diff --git a/pwmanager/pwmanager/pwminit.cpp b/pwmanager/pwmanager/pwminit.cpp index 2f1aa4e..8946443 100644 --- a/pwmanager/pwmanager/pwminit.cpp +++ b/pwmanager/pwmanager/pwminit.cpp @@ -20,3 +20,2 @@ #include "pwminit.h" -#include "configuration.h" #include "randomizer.h" @@ -25,2 +24,5 @@ #include "selftest.h" +#include "configuration.h" +#else +#include "pwmprefs.h" #endif @@ -121,3 +123,5 @@ PwMInit::~PwMInit() Randomizer::cleanup(); +#ifndef PWM_EMBEDDED Configuration::cleanup(); +#endif } @@ -130,3 +134,5 @@ void PwMInit::initializeApp() Randomizer::init(); +#ifndef PWM_EMBEDDED Configuration::init(); +#endif initDCOP(); @@ -148,2 +154,13 @@ void PwMInit::initializeApp() delete newDoc; + + //US ENH for embedded devices: in the case of failure, open a document the default way + createMainWnd(conf()->confGlobAutoStart(), + openDeeplocked, + true, + 0, + savedCmd.minimized); + + + + } diff --git a/pwmanager/pwmanager/pwmtray.cpp b/pwmanager/pwmanager/pwmtray.cpp index 0f286c1..fe074ca 100644 --- a/pwmanager/pwmanager/pwmtray.cpp +++ b/pwmanager/pwmanager/pwmtray.cpp @@ -27,3 +27,7 @@ #include "pwminit.h" +#ifndef PWM_EMBEDDED #include "configuration.h" +#else +#include "pwmprefs.h" +#endif diff --git a/pwmanager/pwmanager/pwmview.cpp b/pwmanager/pwmanager/pwmview.cpp index c09fbf5..58c2fca 100644 --- a/pwmanager/pwmanager/pwmview.cpp +++ b/pwmanager/pwmanager/pwmview.cpp @@ -24,3 +24,7 @@ #include "rencatwnd.h" +#ifndef PWM_EMBEDDED #include "configuration.h" +#else +#include "pwmprefs.h" +#endif #include "commentbox.h" diff --git a/pwmanager/pwmanager/serializer.cpp b/pwmanager/pwmanager/serializer.cpp index 65e442d..f29ef6c 100644 --- a/pwmanager/pwmanager/serializer.cpp +++ b/pwmanager/pwmanager/serializer.cpp @@ -24,2 +24,3 @@ #ifdef PWM_EMBEDDED +#include <kglobal.h> #include <klocale.h> |