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

List:       kde-commits
Subject:    extragear/network/konversation/src
From:       John Tapsell <john.tapsell () kdemail ! net>
Date:       2005-09-01 1:10:03
Message-ID: 1125537003.560111.24131.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 455623 by johnflux:

StatusPanel had a pointer to preferences - fixing to use the singleton



 M  +1 -1      channel.cpp  
 M  +2 -2      preferences.h  
 M  +10 -11    prefspagechatwinappearance.cpp  
 M  +1 -4      prefspagechatwinappearance.h  
 M  +1 -1      statuspanel.cpp  


--- trunk/extragear/network/konversation/src/channel.cpp #455622:455623
@@ -1839,7 +1839,7 @@
     if(Preferences::showBackgroundImage())
     {
         getTextView()->setViewBackground(Preferences::color("TextViewBackground"),
-            Preferences::backgroundImageName());
+            Preferences::backgroundImage());
     }
     else
     {
--- trunk/extragear/network/konversation/src/preferences.h #455622:455623
@@ -282,7 +282,7 @@
 
         static const QStringList buttonList();
         static void setButtonList(QStringList newList);
-
+*/
         static void addIgnore(const QString &newIgnore);
         static void clearIgnoreList();
         static const QPtrList<Ignore> ignoreList();
@@ -296,7 +296,7 @@
         static const IdentityPtr identityByName(const QString& name);
         static const IdentityPtr identityById(int id);
 //        static IdentityPtr identity;
-
+/*
         static const QString ident();
         static void setIdent(const QString &ident);
 
--- trunk/extragear/network/konversation/src/prefspagechatwinappearance.cpp \
#455622:455623 @@ -23,13 +23,12 @@
 
 #include "preferences.h"
 
-PrefsPageChatWinAppearance::PrefsPageChatWinAppearance(QWidget* \
newParent,Preferences* newPreferences) \
+PrefsPageChatWinAppearance::PrefsPageChatWinAppearance(QWidget* newParent)  : \
ChatWindowAppearance_Config(newParent)  {
-    preferences = newPreferences;
 
-    kcfg_Timestamping->setChecked(preferences->getTimestamping());
-    kcfg_ShowDate->setChecked(preferences->getShowDate());
+    kcfg_Timestamping->setChecked(Preferences::timestamping());
+    kcfg_ShowDate->setChecked(Preferences::showDate());
 
     kcfg_TimestampFormat->insertItem("hh");
     kcfg_TimestampFormat->insertItem("hh:mm");
@@ -41,22 +40,22 @@
     // find actual timestamp format
     for(int index=0; index < kcfg_TimestampFormat->count(); index++)
     {
-        if(kcfg_TimestampFormat->text(index) == preferences->getTimestampFormat())
+        if(kcfg_TimestampFormat->text(index) == Preferences::timestampFormat())
         {
             kcfg_TimestampFormat->setCurrentItem(index);
         }
     }
 
-    kcfg_ShowTopic->setChecked(preferences->getShowTopic());
-    kcfg_ShowModeButtons->setChecked(preferences->getShowModeButtons());
-    kcfg_ShowQuickButtons->setChecked(preferences->getShowQuickButtons());
-    kcfg_AutoUserhost->setChecked(preferences->getAutoUserhost());
+    kcfg_ShowTopic->setChecked(Preferences::showTopic());
+    kcfg_ShowModeButtons->setChecked(Preferences::showModeButtons());
+    kcfg_ShowQuickButtons->setChecked(Preferences::showQuickButtons());
+    kcfg_AutoUserhost->setChecked(Preferences::autoUserhost());
     kcfg_ShowNicknameBox->setChecked(preferences->showNicknameBox());
 
-    kcfg_ShowBackgroundImage->setChecked(preferences->getShowBackgroundImage());
+    kcfg_ShowBackgroundImage->setChecked(Preferences::showBackgroundImage());
 
     kcfg_BackgroundImage->setCaption(i18n("Select Background Image"));
-    kcfg_BackgroundImage->setURL(preferences->getBackgroundImageName());
+    kcfg_BackgroundImage->setURL(Preferences::backgroundImage());
 
     connect(kcfg_ShowBackgroundImage,SIGNAL(toggled(bool)),this, \
                SLOT(setBackgroundImageConfig(bool)));
     connect(kcfg_BackgroundImage,SIGNAL(textChanged(const \
                QString&)),this,SLOT(saveBackgroundImage(const QString&)));
--- trunk/extragear/network/konversation/src/prefspagechatwinappearance.h \
#455622:455623 @@ -21,7 +21,7 @@
 {
     Q_OBJECT
         public:
-        PrefsPageChatWinAppearance(QWidget* newParent,Preferences* newPreferences);
+        PrefsPageChatWinAppearance(QWidget* newParent);
 
     public slots:
         void applyPreferences();
@@ -29,8 +29,5 @@
     protected slots:
         void setBackgroundImageConfig(bool state);
         void saveBackgroundImage(const QString&);
-
-    protected:
-        Preferences* preferences;
 };
 #endif
--- trunk/extragear/network/konversation/src/statuspanel.cpp #455622:455623
@@ -175,7 +175,7 @@
     if(Preferences::showBackgroundImage())
     {
         getTextView()->setViewBackground(Preferences::color("TextViewBackground"),
-            Preferences::backgroundImageName());
+            Preferences::backgroundImage());
     }
     else
     {


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

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