[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: KDE/kdenetwork/kopete/protocols/msn
From: Urs Wolfer <uwolfer () kde ! org>
Date: 2008-09-09 20:21:24
Message-ID: 1220991684.142188.31699.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 859240 by uwolfer:
* remove Q3 support
* fix a checkbox: whole text has been remove some times ago...
* use icons for move-from-to-listwidget buttons
M +1 -3 CMakeLists.txt
M +1 -5 msnaddcontactpage.cpp
M +13 -24 ui/msneditaccountui.ui
M +13 -10 ui/msneditaccountwidget.cpp
--- trunk/KDE/kdenetwork/kopete/protocols/msn/CMakeLists.txt #859239:859240
@@ -1,5 +1,3 @@
-add_definitions(-DQT3_SUPPORT -DQT3_SUPPORT_WARNINGS)
-
#add_subdirectory( ui )
add_subdirectory( icons )
@@ -63,7 +61,7 @@
if(WIN32)
target_link_libraries(kopete_msn_shared ${KDE4_KIO_LIBS} kopete \
${QT_QT3SUPPORT_LIBRARY} ${KDE4_KUTILS_LIBS}) else(WIN32)
- target_link_libraries(kopete_msn_shared ${KDE4_KIO_LIBS} kopete \
kopete_videodevice ${QT_QT3SUPPORT_LIBRARY} ${KDE4_KUTILS_LIBS}) + \
target_link_libraries(kopete_msn_shared ${KDE4_KIO_LIBS} kopete kopete_videodevice \
${KDE4_KUTILS_LIBS}) endif(WIN32)
set_target_properties(kopete_msn_shared PROPERTIES VERSION ${GENERIC_LIB_VERSION} \
SOVERSION ${GENERIC_LIB_SOVERSION} )
--- trunk/KDE/kdenetwork/kopete/protocols/msn/msnaddcontactpage.cpp #859239:859240
@@ -16,8 +16,6 @@
#include <qlayout.h>
#include <qlineedit.h>
-//Added by qt3to4:
-#include <QVBoxLayout>
#include <klocale.h>
#include <kmessagebox.h>
@@ -32,12 +30,10 @@
: AddContactPage(parent)
{
Q_UNUSED(connected);
- (new QVBoxLayout(this))->setAutoAdd(true);
/* if ( connected )
{*/
- QWidget* w = new QWidget( this );
msndata = new Ui::msnAddUI();
- msndata->setupUi( w );
+ msndata->setupUi( this );
/*
msndata->cmbGroup->insertStringList(owner->getGroups());
msndata->cmbGroup->setCurrentItem(0);
--- trunk/KDE/kdenetwork/kopete/protocols/msn/ui/msneditaccountui.ui #859239:859240
@@ -23,7 +23,7 @@
<item>
<widget class="QTabWidget" name="tabWidget3" >
<property name="currentIndex" >
- <number>0</number>
+ <number>3</number>
</property>
<widget class="QWidget" name="tab_connection" >
<attribute name="title" >
@@ -772,20 +772,14 @@
<property name="spacing" >
<number>6</number>
</property>
- <item row="0" column="2" >
+ <item row="0" column="4" >
<widget class="QLabel" name="textLabel2" >
<property name="text" >
- <string>Bloc&ked contacts:</string>
+ <string>Blocked contacts:</string>
</property>
- <property name="buddy" >
- <cstring>m_BL</cstring>
- </property>
</widget>
</item>
- <item row="1" column="0" >
- <widget class="Q3ListBox" name="m_AL" />
- </item>
- <item row="1" column="1" >
+ <item row="2" column="2" >
<layout class="QVBoxLayout" >
<property name="spacing" >
<number>6</number>
@@ -796,14 +790,14 @@
<item>
<widget class="QPushButton" name="m_blockButton" >
<property name="text" >
- <string>&></string>
+ <string/>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="m_allowButton" >
<property name="text" >
- <string>&<</string>
+ <string/>
</property>
</widget>
</item>
@@ -828,16 +822,16 @@
<item row="0" column="0" >
<widget class="QLabel" name="textLabel1" >
<property name="text" >
- <string>Allo&wed contacts:</string>
+ <string>Allowed contacts:</string>
</property>
- <property name="buddy" >
- <cstring>m_AL</cstring>
- </property>
</widget>
</item>
- <item row="1" column="2" >
- <widget class="Q3ListBox" name="m_BL" />
+ <item row="2" column="0" >
+ <widget class="QListWidget" name="m_AL" />
</item>
+ <item row="2" column="4" >
+ <widget class="QListWidget" name="m_BL" />
+ </item>
</layout>
</item>
<item>
@@ -870,7 +864,7 @@
<string>Checking this box will block all users not explicitly shown in \
the allowed list here, including any contacts not on your contact list.</string> \
</property> <property name="text" >
- <string/>
+ <string>Block all users not in 'Allowed' list</string>
</property>
</widget>
</item>
@@ -1224,11 +1218,6 @@
<layoutdefault spacing="6" margin="11" />
<customwidgets>
<customwidget>
- <class>Q3ListBox</class>
- <extends>Q3Frame</extends>
- <header>q3listbox.h</header>
- </customwidget>
- <customwidget>
<class>KComboBox</class>
<extends>QComboBox</extends>
<header>kcombobox.h</header>
--- trunk/KDE/kdenetwork/kopete/protocols/msn/ui/msneditaccountwidget.cpp \
#859239:859240 @@ -114,6 +114,9 @@
d->ui->m_allowButton->setEnabled( connected );
d->ui->m_blockButton->setEnabled( connected );
+ d->ui->m_allowButton->setIcon( KIcon( "arrow-left" ) );
+ d->ui->m_blockButton->setIcon( KIcon( "arrow-right" ) );
+
MSNAccount *m_account = static_cast<MSNAccount*>( account );
d->ui->m_serverName->setText( m_account->serverName() );
d->ui->m_serverPort->setValue( m_account->serverPort() );
@@ -123,10 +126,10 @@
//QStringList reverseList = config->readListEntry("reverseList" );
for ( QStringList::Iterator it = blockList.begin(); it != blockList.end(); ++it )
- d->ui->m_BL->insertItem( *it );
+ d->ui->m_BL->addItem( *it );
for ( QStringList::Iterator it = allowList.begin(); it != allowList.end(); ++it )
- d->ui->m_AL->insertItem( *it );
+ d->ui->m_AL->addItem( *it );
d->ui->m_blp->setChecked( config->readEntry( "BLP" ) == "BL" );
@@ -241,9 +244,9 @@
void MSNEditAccountWidget::slotAllow()
{
//TODO: play with multiple selection
- Q3ListBoxItem *item = d->ui->m_BL->selectedItem();
- if ( !item )
+ if ( d->ui->m_BL->selectedItems().isEmpty() )
return;
+ QListWidgetItem *item = d->ui->m_BL->selectedItems().at(0);
QString handle = item->text();
@@ -252,16 +255,16 @@
return;
notify->removeContact( handle, MSNProtocol::BL, QString(), QString() );
- d->ui->m_BL->takeItem( item );
- d->ui->m_AL->insertItem( item );
+ d->ui->m_BL->takeItem( d->ui->m_BL->row( item ) );
+ d->ui->m_AL->addItem( item );
}
void MSNEditAccountWidget::slotBlock()
{
//TODO: play with multiple selection
- Q3ListBoxItem *item = d->ui->m_AL->selectedItem();
- if ( !item )
+ if ( d->ui->m_AL->selectedItems().isEmpty() )
return;
+ QListWidgetItem *item = d->ui->m_AL->selectedItems().at(0);
QString handle = item->text();
@@ -271,8 +274,8 @@
notify->removeContact( handle, MSNProtocol::AL, QString(), QString() );
- d->ui->m_AL->takeItem( item );
- d->ui->m_BL->insertItem( item );
+ d->ui->m_AL->takeItem( d->ui->m_AL->row( item ) );
+ d->ui->m_BL->addItem( item );
}
void MSNEditAccountWidget::slotShowReverseList()
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic