[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    kdeextragear-2/konversation/konversation
From:       Peter Simonsson <psn () linux ! se>
Date:       2004-10-19 15:18:49
Message-ID: 20041019151849.140C416C6D () office ! kde ! org
[Download RAW message or body]

CVS commit by psn: 

Save the size of the serverlist dialog


  M +10 -1     serverlistdialog.cpp   1.8


--- kdeextragear-2/konversation/konversation/serverlistdialog.cpp  #1.7:1.8
@@ -24,4 +24,5 @@
 #include <qpixmap.h>
 #include <qpainter.h>
+#include <qsize.h>
 
 #include <klocale.h>
@@ -160,5 +161,5 @@ namespace Konversation {
   
   ServerListDialog::ServerListDialog(QWidget *parent, const char *name)
-    : KDialogBase(Plain, i18n("Server List"), Ok|Apply|Cancel, Ok, parent, name)
+    : KDialogBase(Plain, i18n("Server List"), Ok|/*Apply|*/Cancel, Ok, parent, name)
   {
     m_preferences = &KonversationApplication::preferences;
@@ -215,8 +216,16 @@ namespace Konversation {
     
     updateButtons();
+  
+    KConfig* config = kapp->config();
+    config->setGroup("ServerListDialog");
+    QSize newSize = config->readSizeEntry("Size", &size());
+    resize(newSize);
   }
   
   ServerListDialog::~ServerListDialog()
   {
+    KConfig* config = kapp->config();
+    config->setGroup("ServerListDialog");
+    config->writeEntry("Size", size());
   }
 


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic