Diffstat (limited to 'kaddressbook/mainembedded.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | kaddressbook/mainembedded.cpp | 26 |
1 files changed, 21 insertions, 5 deletions
diff --git a/kaddressbook/mainembedded.cpp b/kaddressbook/mainembedded.cpp index 336e350..50db377 100644 --- a/kaddressbook/mainembedded.cpp +++ b/kaddressbook/mainembedded.cpp @@ -91,3 +91,2 @@ int main( int argc, char **argv ) a.setMainWidget( &m ); - m.resize (640, 480 ); m.show(); @@ -95,6 +94,23 @@ int main( int argc, char **argv ) a.exec(); - - dumpMissing(); - - KPimGlobalPrefs::instance()->writeConfig(); +#ifdef DESKTOP_VERSION + KConfig *config = KABPrefs::instance()->getConfig(); + config->setGroup("WidgetLayout"); + QStringList list ;//= config->readListEntry("MainLayout"); + int x,y,w,h; + QWidget* wid; + wid = &m; + x = wid->geometry().x(); + y = wid->geometry().y(); + w = wid->width(); + h = wid->height(); + list.clear(); + list << QString::number( x ); + list << QString::number( y ); + list << QString::number( w ); + list << QString::number( h ); + config->writeEntry("MainLayout",list ); +#endif + dumpMissing(); + + KPimGlobalPrefs::instance()->writeConfig(); } |