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

List:       kde-commits
Subject:    branches/work/konvi-kde4/src/irc
From:       Pino Toscano <pino () kde ! org>
Date:       2009-02-01 16:50:50
Message-ID: 1233507050.322678.15115.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 919825 by pino:

show again the channel modes in the channel option dialog; reenable a missing \
connection


 M  +8 -14     channeloptionsdialog.cpp  


--- branches/work/konvi-kde4/src/irc/channeloptionsdialog.cpp #919824:919825
@@ -67,10 +67,7 @@
         connect(m_channel, SIGNAL(topicHistoryChanged()), this, \
SLOT(refreshTopicHistory()));  
         connect(m_channel, SIGNAL(modesChanged()), this, SLOT(refreshModes()));
-#ifndef Q_CC_MSVC
-#warning "port it to kde4"
-#endif
-        //connect(m_channel->getOwnChannelNick(), SIGNAL(channelNickChanged()), \
this, SLOT(refreshEnableModes())); +        \
connect(m_channel->getOwnChannelNick().data(), SIGNAL(channelNickChanged()), this, \
SLOT(refreshEnableModes()));  
         connect(this, SIGNAL(cancelClicked()), this, SLOT(cancelClicked()));
         connect(this, SIGNAL(okClicked()), this, SLOT(changeOptions()));
@@ -263,15 +260,12 @@
             static_cast<Q3CheckListItem*>(item)->setOn(false);
             item = item->nextSibling();
         }
-#ifndef Q_CC_MSVC
-#warning "port to kde4"
-#endif
-#if 0
+
         char mode;
 
-        for(QStringList::const_iterator it = modes.begin(); it != modes.end(); ++it)
+        foreach (const QString &currentMode, modes)
         {
-            mode = (*it)[0];
+            mode = currentMode[0].toLatin1();
             switch(mode)
             {
                 case 't':
@@ -282,7 +276,7 @@
                     break;
                 case 'l':
                     m_ui.userLimitChBox->setChecked(true);
-                    m_ui.userLimitEdit->setValue((*it).mid(1).toInt());
+                    m_ui.userLimitEdit->setValue(currentMode.mid(1).toInt());
                     break;
                 case 'i':
                     m_ui.inviteModeChBox->setChecked(true);
@@ -295,7 +289,7 @@
                     break;
                 case 'k':
                     m_ui.keyModeChBox->setChecked(true);
-                    m_ui.keyModeEdit->setText((*it).mid(1));
+                    m_ui.keyModeEdit->setText(currentMode.mid(1));
                     break;
                 default:
                 {
@@ -310,7 +304,7 @@
                         {
                             found = true;
                             static_cast<Q3CheckListItem*>(item)->setOn(true);
-                            item->setText(1, (*it).mid(1));
+                            item->setText(1, currentMode.mid(1));
                         }
                         else
                         {
@@ -322,7 +316,7 @@
                 }
             }
         }
-#endif
+
         refreshEnableModes();
     }
 


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

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