summaryrefslogtreecommitdiffstats
path: root/kaddressbook/features
diff options
context:
space:
mode:
Diffstat (limited to 'kaddressbook/features')
-rw-r--r--kaddressbook/features/distributionlistngwidget.cpp114
-rw-r--r--kaddressbook/features/distributionlistngwidget.h30
-rw-r--r--kaddressbook/features/distributionlistwidget.cpp162
-rw-r--r--kaddressbook/features/distributionlistwidget.h52
-rw-r--r--kaddressbook/features/resourceselection.cpp166
-rw-r--r--kaddressbook/features/resourceselection.h32
6 files changed, 278 insertions, 278 deletions
diff --git a/kaddressbook/features/distributionlistngwidget.cpp b/kaddressbook/features/distributionlistngwidget.cpp
index fee8377a..08ef3e4c 100644
--- a/kaddressbook/features/distributionlistngwidget.cpp
+++ b/kaddressbook/features/distributionlistngwidget.cpp
@@ -35,23 +35,23 @@
#include <klocale.h>
#include <kpopupmenu.h>
-#include <qevent.h>
-#include <qguardedptr.h>
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qpoint.h>
-#include <qtimer.h>
-#include <qpushbutton.h>
-#include <qtooltip.h>
-
-KAB::DistributionListNg::ListBox::ListBox( QWidget* parent ) : KListBox( parent )
+#include <tqevent.h>
+#include <tqguardedptr.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqpoint.h>
+#include <tqtimer.h>
+#include <tqpushbutton.h>
+#include <tqtooltip.h>
+
+KAB::DistributionListNg::ListBox::ListBox( TQWidget* parent ) : KListBox( parent )
{
setAcceptDrops( true );
}
-void KAB::DistributionListNg::ListBox::dragMoveEvent( QDragMoveEvent *event )
+void KAB::DistributionListNg::ListBox::dragMoveEvent( TQDragMoveEvent *event )
{
- QListBoxItem *item = itemAt( event->pos() );
+ TQListBoxItem *item = itemAt( event->pos() );
if ( !item ) {
event->ignore();
}
@@ -60,18 +60,18 @@ void KAB::DistributionListNg::ListBox::dragMoveEvent( QDragMoveEvent *event )
}
}
-void KAB::DistributionListNg::ListBox::dragEnterEvent( QDragEnterEvent *event )
+void KAB::DistributionListNg::ListBox::dragEnterEvent( TQDragEnterEvent *event )
{
KListBox::dragEnterEvent( event );
}
-void KAB::DistributionListNg::ListBox::dropEvent( QDropEvent *event )
+void KAB::DistributionListNg::ListBox::dropEvent( TQDropEvent *event )
{
- QListBoxItem *item = itemAt( event->pos() );
+ TQListBoxItem *item = itemAt( event->pos() );
if ( !item || index( item ) == 0 )
return;
- QString vcards;
+ TQString vcards;
if ( !KVCardDrag::decode( event, vcards ) )
return;
@@ -85,12 +85,12 @@ namespace DistributionListNg {
class Factory : public KAB::ExtensionFactory
{
public:
- KAB::ExtensionWidget *extension( KAB::Core *core, QWidget *parent, const char *name )
+ KAB::ExtensionWidget *extension( KAB::Core *core, TQWidget *parent, const char *name )
{
return new KAB::DistributionListNg::MainWidget( core, parent, name );
}
- QString identifier() const
+ TQString identifier() const
{
return "distribution_list_editor";
}
@@ -106,76 +106,76 @@ extern "C" {
}
}
-QString KAB::DistributionListNg::MainWidget::title() const
+TQString KAB::DistributionListNg::MainWidget::title() const
{
return i18n( "Distribution List Editor NG" );
}
-QString KAB::DistributionListNg::MainWidget::identifier() const
+TQString KAB::DistributionListNg::MainWidget::identifier() const
{
return "distribution_list_editor_ng";
}
-KAB::DistributionListNg::MainWidget::MainWidget( KAB::Core *core, QWidget *parent, const char *name ) : KAB::ExtensionWidget( core, parent, name )
+KAB::DistributionListNg::MainWidget::MainWidget( KAB::Core *core, TQWidget *parent, const char *name ) : KAB::ExtensionWidget( core, parent, name )
{
- QVBoxLayout *layout = new QVBoxLayout( this );
+ TQVBoxLayout *layout = new TQVBoxLayout( this );
layout->setSpacing( KDialog::spacingHint() );
- QHBoxLayout *buttonLayout = new QHBoxLayout();
+ TQHBoxLayout *buttonLayout = new TQHBoxLayout();
layout->addLayout( buttonLayout );
- QLabel *label = new QLabel( this );
+ TQLabel *label = new TQLabel( this );
label->setText( i18n( "Distribution Lists" ) );
buttonLayout->addWidget( label );
buttonLayout->addStretch( 1 );
- mAddButton = new QPushButton( this );
+ mAddButton = new TQPushButton( this );
mAddButton->setIconSet( SmallIconSet( "add" ) );
- QToolTip::add( mAddButton, i18n( "Add distribution list" ) );
- connect( mAddButton, SIGNAL(clicked()), core, SLOT(newDistributionList()) );
+ TQToolTip::add( mAddButton, i18n( "Add distribution list" ) );
+ connect( mAddButton, TQT_SIGNAL(clicked()), core, TQT_SLOT(newDistributionList()) );
buttonLayout->addWidget( mAddButton );
- mEditButton = new QPushButton( this );
+ mEditButton = new TQPushButton( this );
mEditButton->setIconSet( SmallIconSet( "edit" ) );
- QToolTip::add( mEditButton, i18n( "Edit distribution list" ) );
- connect( mEditButton, SIGNAL(clicked()), this, SLOT(editSelectedDistributionList()) );
+ TQToolTip::add( mEditButton, i18n( "Edit distribution list" ) );
+ connect( mEditButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(editSelectedDistributionList()) );
buttonLayout->addWidget( mEditButton );
- mRemoveButton = new QPushButton( this );
+ mRemoveButton = new TQPushButton( this );
mRemoveButton->setIconSet( SmallIconSet( "remove" ) );
- QToolTip::add( mRemoveButton, i18n( "Remove distribution list" ) );
- connect( mRemoveButton, SIGNAL(clicked()), this, SLOT(deleteSelectedDistributionList()) );
+ TQToolTip::add( mRemoveButton, i18n( "Remove distribution list" ) );
+ connect( mRemoveButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(deleteSelectedDistributionList()) );
buttonLayout->addWidget( mRemoveButton );
mListBox = new ListBox( this );
- connect( mListBox, SIGNAL( contextMenuRequested( QListBoxItem*, const QPoint& ) ),
- this, SLOT( contextMenuRequested( QListBoxItem*, const QPoint& ) ) );
- connect( mListBox, SIGNAL( dropped( const QString &, const KABC::Addressee::List & ) ),
- this, SLOT( contactsDropped( const QString &, const KABC::Addressee::List & ) ) );
- connect( mListBox, SIGNAL( highlighted( int ) ),
- this, SLOT( itemSelected( int ) ) );
+ connect( mListBox, TQT_SIGNAL( contextMenuRequested( TQListBoxItem*, const TQPoint& ) ),
+ this, TQT_SLOT( contextMenuRequested( TQListBoxItem*, const TQPoint& ) ) );
+ connect( mListBox, TQT_SIGNAL( dropped( const TQString &, const KABC::Addressee::List & ) ),
+ this, TQT_SLOT( contactsDropped( const TQString &, const KABC::Addressee::List & ) ) );
+ connect( mListBox, TQT_SIGNAL( highlighted( int ) ),
+ this, TQT_SLOT( itemSelected( int ) ) );
layout->addWidget( mListBox );
- connect( core, SIGNAL( contactsUpdated() ),
- this, SLOT( updateEntries() ) );
- connect( core->addressBook(), SIGNAL( addressBookChanged( AddressBook* ) ),
- this, SLOT( updateEntries() ) );
+ connect( core, TQT_SIGNAL( contactsUpdated() ),
+ this, TQT_SLOT( updateEntries() ) );
+ connect( core->addressBook(), TQT_SIGNAL( addressBookChanged( AddressBook* ) ),
+ this, TQT_SLOT( updateEntries() ) );
// When contacts are changed, update both distr list combo and contents of displayed distr list
- connect( core, SIGNAL( contactsUpdated() ),
- this, SLOT( updateEntries() ) );
+ connect( core, TQT_SIGNAL( contactsUpdated() ),
+ this, TQT_SLOT( updateEntries() ) );
- QTimer::singleShot( 0, this, SLOT( updateEntries() ) );
+ TQTimer::singleShot( 0, this, TQT_SLOT( updateEntries() ) );
}
-void KAB::DistributionListNg::MainWidget::contextMenuRequested( QListBoxItem *item, const QPoint &point )
+void KAB::DistributionListNg::MainWidget::contextMenuRequested( TQListBoxItem *item, const TQPoint &point )
{
- QGuardedPtr<KPopupMenu> menu = new KPopupMenu( this );
- menu->insertItem( i18n( "New Distribution List..." ), core(), SLOT( newDistributionList() ) );
+ TQGuardedPtr<KPopupMenu> menu = new KPopupMenu( this );
+ menu->insertItem( i18n( "New Distribution List..." ), core(), TQT_SLOT( newDistributionList() ) );
if ( item )
{
- menu->insertItem( i18n( "Edit..." ), this, SLOT( editSelectedDistributionList() ) );
- menu->insertItem( i18n( "Delete" ), this, SLOT( deleteSelectedDistributionList() ) );
+ menu->insertItem( i18n( "Edit..." ), this, TQT_SLOT( editSelectedDistributionList() ) );
+ menu->insertItem( i18n( "Delete" ), this, TQT_SLOT( deleteSelectedDistributionList() ) );
}
menu->exec( point );
delete menu;
@@ -183,7 +183,7 @@ void KAB::DistributionListNg::MainWidget::contextMenuRequested( QListBoxItem *it
void KAB::DistributionListNg::MainWidget::editSelectedDistributionList()
{
- const QListBoxItem* const item = mListBox->selectedItem();
+ const TQListBoxItem* const item = mListBox->selectedItem();
if ( !item )
return;
core()->editDistributionList( item->text() );
@@ -191,8 +191,8 @@ void KAB::DistributionListNg::MainWidget::editSelectedDistributionList()
void KAB::DistributionListNg::MainWidget::deleteSelectedDistributionList()
{
- const QListBoxItem* const item = mListBox->selectedItem();
- const QString name = item ? item->text() : QString();
+ const TQListBoxItem* const item = mListBox->selectedItem();
+ const TQString name = item ? item->text() : TQString();
if ( name.isNull() )
return;
const KPIM::DistributionList list = KPIM::DistributionList::findByName(
@@ -202,7 +202,7 @@ void KAB::DistributionListNg::MainWidget::deleteSelectedDistributionList()
core()->deleteDistributionLists( name );
}
-void KAB::DistributionListNg::MainWidget::contactsDropped( const QString &listName, const KABC::Addressee::List &addressees )
+void KAB::DistributionListNg::MainWidget::contactsDropped( const TQString &listName, const KABC::Addressee::List &addressees )
{
if ( addressees.isEmpty() )
return;
@@ -228,7 +228,7 @@ void KAB::DistributionListNg::MainWidget::changed( const KABC::Addressee& dist )
void KAB::DistributionListNg::MainWidget::updateEntries()
{
const bool hadSelection = mListBox->selectedItem() != 0;
- const QStringList newEntries = core()->distributionListNames();
+ const TQStringList newEntries = core()->distributionListNames();
if ( !mCurrentEntries.isEmpty() && newEntries == mCurrentEntries )
return;
mCurrentEntries = newEntries;
@@ -241,7 +241,7 @@ void KAB::DistributionListNg::MainWidget::updateEntries()
void KAB::DistributionListNg::MainWidget::itemSelected( int index )
{
- core()->setSelectedDistributionList( index == 0 ? QString() : mListBox->item( index )->text() );
+ core()->setSelectedDistributionList( index == 0 ? TQString() : mListBox->item( index )->text() );
mEditButton->setEnabled( index > 0 );
mRemoveButton->setEnabled( index > 0 );
}
diff --git a/kaddressbook/features/distributionlistngwidget.h b/kaddressbook/features/distributionlistngwidget.h
index 4a174dd8..0bfa3d29 100644
--- a/kaddressbook/features/distributionlistngwidget.h
+++ b/kaddressbook/features/distributionlistngwidget.h
@@ -29,7 +29,7 @@
#include <klistbox.h>
-#include <qstringlist.h>
+#include <tqstringlist.h>
class QDragEnterEvent;
class QDragMoveEvent;
@@ -48,19 +48,19 @@ class ListBox : public KListBox
{
Q_OBJECT
public:
- ListBox( QWidget* parent = 0 );
+ ListBox( TQWidget* parent = 0 );
signals:
- void dropped( const QString &listName, const KABC::Addressee::List &addressees );
+ void dropped( const TQString &listName, const KABC::Addressee::List &addressees );
protected:
//override
- void dragEnterEvent( QDragEnterEvent *event );
+ void dragEnterEvent( TQDragEnterEvent *event );
//override
- void dragMoveEvent( QDragMoveEvent *event );
+ void dragMoveEvent( TQDragMoveEvent *event );
//override
- void dropEvent( QDropEvent *event );
+ void dropEvent( TQDropEvent *event );
};
class MainWidget : public KAB::ExtensionWidget
@@ -68,13 +68,13 @@ class MainWidget : public KAB::ExtensionWidget
Q_OBJECT
public:
- explicit MainWidget( KAB::Core *core, QWidget *parent = 0, const char *name = 0 );
+ explicit MainWidget( KAB::Core *core, TQWidget *parent = 0, const char *name = 0 );
//impl
- QString title() const;
+ TQString title() const;
//impl
- QString identifier() const;
+ TQString identifier() const;
private:
@@ -85,17 +85,17 @@ private slots:
void deleteSelectedDistributionList();
void editSelectedDistributionList();
- void contextMenuRequested( QListBoxItem *item, const QPoint &point );
+ void contextMenuRequested( TQListBoxItem *item, const TQPoint &point );
void updateEntries();
void itemSelected( int index );
- void contactsDropped( const QString &listName, const KABC::Addressee::List &addressees );
+ void contactsDropped( const TQString &listName, const KABC::Addressee::List &addressees );
private:
ListBox *mListBox;
- QStringList mCurrentEntries;
- QPushButton *mAddButton;
- QPushButton *mEditButton;
- QPushButton *mRemoveButton;
+ TQStringList mCurrentEntries;
+ TQPushButton *mAddButton;
+ TQPushButton *mEditButton;
+ TQPushButton *mRemoveButton;
};
} // namespace DistributionListNg
diff --git a/kaddressbook/features/distributionlistwidget.cpp b/kaddressbook/features/distributionlistwidget.cpp
index 9c322d6f..93a00bdf 100644
--- a/kaddressbook/features/distributionlistwidget.cpp
+++ b/kaddressbook/features/distributionlistwidget.cpp
@@ -22,13 +22,13 @@
#include "distributionlistwidget.h"
-#include <qbuttongroup.h>
-#include <qcombobox.h>
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qlistview.h>
-#include <qpushbutton.h>
-#include <qradiobutton.h>
+#include <tqbuttongroup.h>
+#include <tqcombobox.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqlistview.h>
+#include <tqpushbutton.h>
+#include <tqradiobutton.h>
#include <kaccelmanager.h>
#include <kconfig.h>
@@ -55,12 +55,12 @@ typedef KABC::DistributionList DistributionList;
class DistributionListFactory : public KAB::ExtensionFactory
{
public:
- KAB::ExtensionWidget *extension( KAB::Core *core, QWidget *parent, const char *name )
+ KAB::ExtensionWidget *extension( KAB::Core *core, TQWidget *parent, const char *name )
{
return new DistributionListWidget( core, parent, name );
}
- QString identifier() const
+ TQString identifier() const
{
return "distribution_list_editor";
}
@@ -82,15 +82,15 @@ class DeletePressedCatcher : public QObject
{
public:
DeletePressedCatcher( DistributionListWidget *parent )
- : QObject( parent, "DeletePressedCatcher" ), mWidget( parent )
+ : TQObject( parent, "DeletePressedCatcher" ), mWidget( parent )
{
}
protected:
- bool eventFilter( QObject*, QEvent *event )
+ bool eventFilter( TQObject*, TQEvent *event )
{
- if ( event->type() == QEvent::AccelOverride ) {
- QKeyEvent *keyEvent = (QKeyEvent*)event;
+ if ( event->type() == TQEvent::AccelOverride ) {
+ TQKeyEvent *keyEvent = (TQKeyEvent*)event;
if ( keyEvent->key() == Qt::Key_Delete ) {
keyEvent->accept();
mWidget->removeContact();
@@ -110,8 +110,8 @@ class ContactItem : public QListViewItem
{
public:
ContactItem( DistributionListView *parent, const KABC::Addressee &addressee,
- const QString &email = QString::null ) :
- QListViewItem( parent ),
+ const TQString &email = TQString::null ) :
+ TQListViewItem( parent ),
mAddressee( addressee ),
mEmail( email )
{
@@ -130,47 +130,47 @@ class ContactItem : public QListViewItem
return mAddressee;
}
- QString email() const
+ TQString email() const
{
return mEmail;
}
protected:
- bool acceptDrop( const QMimeSource* )
+ bool acceptDrop( const TQMimeSource* )
{
return true;
}
private:
KABC::Addressee mAddressee;
- QString mEmail;
+ TQString mEmail;
};
-DistributionListWidget::DistributionListWidget( KAB::Core *core, QWidget *parent,
+DistributionListWidget::DistributionListWidget( KAB::Core *core, TQWidget *parent,
const char *name )
: KAB::ExtensionWidget( core, parent, name )
#ifndef KDEPIM_NEW_DISTRLISTS
, mManager( 0 )
#endif
{
- QGridLayout *topLayout = new QGridLayout( this, 3, 4, KDialog::marginHint(),
+ TQGridLayout *topLayout = new TQGridLayout( this, 3, 4, KDialog::marginHint(),
KDialog::spacingHint() );
- mNameCombo = new QComboBox( this );
+ mNameCombo = new TQComboBox( this );
topLayout->addWidget( mNameCombo, 0, 0 );
- connect( mNameCombo, SIGNAL( activated( int ) ), SLOT( updateContactView() ) );
+ connect( mNameCombo, TQT_SIGNAL( activated( int ) ), TQT_SLOT( updateContactView() ) );
- mCreateListButton = new QPushButton( i18n( "New List..." ), this );
+ mCreateListButton = new TQPushButton( i18n( "New List..." ), this );
topLayout->addWidget( mCreateListButton, 0, 1 );
- connect( mCreateListButton, SIGNAL( clicked() ), SLOT( createList() ) );
+ connect( mCreateListButton, TQT_SIGNAL( clicked() ), TQT_SLOT( createList() ) );
- mEditListButton = new QPushButton( i18n( "Rename List..." ), this );
+ mEditListButton = new TQPushButton( i18n( "Rename List..." ), this );
topLayout->addWidget( mEditListButton, 0, 2 );
- connect( mEditListButton, SIGNAL( clicked() ), SLOT( editList() ) );
+ connect( mEditListButton, TQT_SIGNAL( clicked() ), TQT_SLOT( editList() ) );
- mRemoveListButton = new QPushButton( i18n( "Remove List" ), this );
+ mRemoveListButton = new TQPushButton( i18n( "Remove List" ), this );
topLayout->addWidget( mRemoveListButton, 0, 3 );
- connect( mRemoveListButton, SIGNAL( clicked() ), SLOT( removeList() ) );
+ connect( mRemoveListButton, TQT_SIGNAL( clicked() ), TQT_SLOT( removeList() ) );
mContactView = new DistributionListView( this );
mContactView->addColumn( i18n( "Name" ) );
@@ -180,44 +180,44 @@ DistributionListWidget::DistributionListWidget( KAB::Core *core, QWidget *parent
mContactView->setAllColumnsShowFocus( true );
mContactView->setFullWidth( true );
topLayout->addMultiCellWidget( mContactView, 1, 1, 0, 3 );
- connect( mContactView, SIGNAL( selectionChanged() ),
- SLOT( selectionContactViewChanged() ) );
- connect( mContactView, SIGNAL( dropped( QDropEvent*, QListViewItem* ) ),
- SLOT( dropped( QDropEvent*, QListViewItem* ) ) );
+ connect( mContactView, TQT_SIGNAL( selectionChanged() ),
+ TQT_SLOT( selectionContactViewChanged() ) );
+ connect( mContactView, TQT_SIGNAL( dropped( TQDropEvent*, TQListViewItem* ) ),
+ TQT_SLOT( dropped( TQDropEvent*, TQListViewItem* ) ) );
- mAddContactButton = new QPushButton( i18n( "Add Contact" ), this );
+ mAddContactButton = new TQPushButton( i18n( "Add Contact" ), this );
mAddContactButton->setEnabled( false );
topLayout->addWidget( mAddContactButton, 2, 0 );
- connect( mAddContactButton, SIGNAL( clicked() ), SLOT( addContact() ) );
+ connect( mAddContactButton, TQT_SIGNAL( clicked() ), TQT_SLOT( addContact() ) );
- mEntryCountLabel = new QLabel( this );
+ mEntryCountLabel = new TQLabel( this );
topLayout->addWidget( mEntryCountLabel, 2, 1 );
- mChangeEmailButton = new QPushButton( i18n( "Change Email..." ), this );
+ mChangeEmailButton = new TQPushButton( i18n( "Change Email..." ), this );
topLayout->addWidget( mChangeEmailButton, 2, 2 );
- connect( mChangeEmailButton, SIGNAL( clicked() ), SLOT( changeEmail() ) );
+ connect( mChangeEmailButton, TQT_SIGNAL( clicked() ), TQT_SLOT( changeEmail() ) );
- mRemoveContactButton = new QPushButton( i18n( "Remove Contact" ), this );
+ mRemoveContactButton = new TQPushButton( i18n( "Remove Contact" ), this );
topLayout->addWidget( mRemoveContactButton, 2, 3 );
- connect( mRemoveContactButton, SIGNAL( clicked() ), SLOT( removeContact() ) );
+ connect( mRemoveContactButton, TQT_SIGNAL( clicked() ), TQT_SLOT( removeContact() ) );
#ifdef KDEPIM_NEW_DISTRLISTS
// When contacts are changed, update both distr list combo and contents of displayed distr list
- connect( core, SIGNAL( contactsUpdated() ),
- this, SLOT( updateNameCombo() ) );
+ connect( core, TQT_SIGNAL( contactsUpdated() ),
+ this, TQT_SLOT( updateNameCombo() ) );
#else
mManager = new KABC::DistributionListManager( core->addressBook() );
- connect( KABC::DistributionListWatcher::self(), SIGNAL( changed() ),
- this, SLOT( updateNameCombo() ) );
+ connect( KABC::DistributionListWatcher::self(), TQT_SIGNAL( changed() ),
+ this, TQT_SLOT( updateNameCombo() ) );
#endif
- connect( core->addressBook(), SIGNAL( addressBookChanged( AddressBook* ) ),
- this, SLOT( updateNameCombo() ) );
+ connect( core->addressBook(), TQT_SIGNAL( addressBookChanged( AddressBook* ) ),
+ this, TQT_SLOT( updateNameCombo() ) );
updateNameCombo();
- QObject *catcher = new DeletePressedCatcher( this );
+ TQObject *catcher = new DeletePressedCatcher( this );
installEventFilter( catcher );
mContactView->installEventFilter( catcher );
@@ -252,7 +252,7 @@ void DistributionListWidget::selectionContactViewChanged()
mRemoveContactButton->setEnabled( state );
}
-bool DistributionListWidget::alreadyExists( const QString& distrListName ) const
+bool DistributionListWidget::alreadyExists( const TQString& distrListName ) const
{
#ifdef KDEPIM_NEW_DISTRLISTS
return core()->distributionListNames().contains( distrListName );
@@ -263,9 +263,9 @@ bool DistributionListWidget::alreadyExists( const QString& distrListName ) const
void DistributionListWidget::createList()
{
- QString newName = KInputDialog::getText( i18n( "New Distribution List" ),
+ TQString newName = KInputDialog::getText( i18n( "New Distribution List" ),
i18n( "Please enter name:" ),
- QString::null, 0, this );
+ TQString::null, 0, this );
if ( newName.isEmpty() ) return;
@@ -301,9 +301,9 @@ void DistributionListWidget::createList()
void DistributionListWidget::editList()
{
- const QString oldName = mNameCombo->currentText();
+ const TQString oldName = mNameCombo->currentText();
- const QString newName = KInputDialog::getText( i18n( "Rename Distribution List" ),
+ const TQString newName = KInputDialog::getText( i18n( "Rename Distribution List" ),
i18n( "Please enter name:" ),
oldName, 0, this );
@@ -344,7 +344,7 @@ void DistributionListWidget::removeList()
{
int result = KMessageBox::warningContinueCancel( this,
i18n( "<qt>Delete distribution list <b>%1</b>?</qt>" ) .arg( mNameCombo->currentText() ),
- QString::null, KGuiItem( i18n("Delete"), "editdelete") );
+ TQString::null, KGuiItem( i18n("Delete"), "editdelete") );
if ( result != KMessageBox::Continue )
return;
@@ -447,7 +447,7 @@ void DistributionListWidget::changeEmail()
return;
bool canceled = false;
- const QString email = EmailSelector::getEmail( contactItem->addressee().emails(),
+ const TQString email = EmailSelector::getEmail( contactItem->addressee().emails(),
contactItem->email(), this, canceled);
if( canceled)
return;
@@ -513,10 +513,10 @@ void DistributionListWidget::updateNameCombo()
int pos = mNameCombo->currentItem();
mNameCombo->clear();
#ifdef KDEPIM_NEW_DISTRLISTS
- const QStringList names = core()->distributionListNames();
+ const TQStringList names = core()->distributionListNames();
#else
mManager->load();
- const QStringList names = mManager->listNames();
+ const TQStringList names = mManager->listNames();
#endif
mNameCombo->insertStringList( names );
mNameCombo->setCurrentItem( QMIN( pos, (int)names.count() - 1 ) );
@@ -524,7 +524,7 @@ void DistributionListWidget::updateNameCombo()
updateContactView();
}
-void DistributionListWidget::dropEvent( QDropEvent *e )
+void DistributionListWidget::dropEvent( TQDropEvent *e )
{
if ( mNameCombo->count() == 0 )
return;
@@ -541,7 +541,7 @@ void DistributionListWidget::dropEvent( QDropEvent *e )
KABC::DistributionList& dist = *list;
#endif
- QString vcards;
+ TQString vcards;
if ( KVCardDrag::decode( e, vcards ) ) {
KABC::VCardConverter converter;
const KABC::Addressee::List lst = converter.parseVCards( vcards );
@@ -563,17 +563,17 @@ void DistributionListWidget::contactsSelectionChanged()
mAddContactButton->setEnabled( contactsSelected() && mNameCombo->count() > 0 );
}
-QString DistributionListWidget::title() const
+TQString DistributionListWidget::title() const
{
return i18n( "Distribution List Editor" );
}
-QString DistributionListWidget::identifier() const
+TQString DistributionListWidget::identifier() const
{
return "distribution_list_editor";
}
-void DistributionListWidget::dropped( QDropEvent *e, QListViewItem* )
+void DistributionListWidget::dropped( TQDropEvent *e, TQListViewItem* )
{
dropEvent( e );
}
@@ -590,7 +590,7 @@ void DistributionListWidget::changed()
}
#endif
-DistributionListView::DistributionListView( QWidget *parent, const char* name )
+DistributionListView::DistributionListView( TQWidget *parent, const char* name )
: KListView( parent, name )
{
setDragEnabled( true );
@@ -598,66 +598,66 @@ DistributionListView::DistributionListView( QWidget *parent, const char* name )
setAllColumnsShowFocus( true );
}
-void DistributionListView::dragEnterEvent( QDragEnterEvent* e )
+void DistributionListView::dragEnterEvent( TQDragEnterEvent* e )
{
- bool canDecode = QTextDrag::canDecode( e );
+ bool canDecode = TQTextDrag::canDecode( e );
e->accept( canDecode );
}
-void DistributionListView::viewportDragMoveEvent( QDragMoveEvent *e )
+void DistributionListView::viewportDragMoveEvent( TQDragMoveEvent *e )
{
- bool canDecode = QTextDrag::canDecode( e );
+ bool canDecode = TQTextDrag::canDecode( e );
e->accept( canDecode );
}
-void DistributionListView::viewportDropEvent( QDropEvent *e )
+void DistributionListView::viewportDropEvent( TQDropEvent *e )
{
emit dropped( e, 0 );
}
-void DistributionListView::dropEvent( QDropEvent *e )
+void DistributionListView::dropEvent( TQDropEvent *e )
{
emit dropped( e, 0 );
}
-EmailSelector::EmailSelector( const QStringList &emails,
- const QString &current, QWidget *parent )
+EmailSelector::EmailSelector( const TQStringList &emails,
+ const TQString &current, TQWidget *parent )
: KDialogBase( KDialogBase::Plain, i18n("Select Email Address"), Ok|Cancel, Ok,
parent )
{
- QFrame *topFrame = plainPage();
- QBoxLayout *topLayout = new QVBoxLayout( topFrame );
+ TQFrame *topFrame = plainPage();
+ TQBoxLayout *topLayout = new TQVBoxLayout( topFrame );
- mButtonGroup = new QButtonGroup( 1, Horizontal, i18n("Email Addresses"),
+ mButtonGroup = new TQButtonGroup( 1, Horizontal, i18n("Email Addresses"),
topFrame );
mButtonGroup->setRadioButtonExclusive( true );
topLayout->addWidget( mButtonGroup );
- QRadioButton *button = new QRadioButton( i18n("Preferred address"), mButtonGroup );
+ TQRadioButton *button = new TQRadioButton( i18n("Preferred address"), mButtonGroup );
button->setDown( true );
mEmailMap.insert( mButtonGroup->id( button ), "" );
- QStringList::ConstIterator it;
+ TQStringList::ConstIterator it;
for ( it = emails.begin(); it != emails.end(); ++it ) {
- button = new QRadioButton( *it, mButtonGroup );
+ button = new TQRadioButton( *it, mButtonGroup );
mEmailMap.insert( mButtonGroup->id( button ), *it );
if ( (*it) == current )
button->setDown( true );
}
}
-QString EmailSelector::selected() const
+TQString EmailSelector::selected() const
{
- QButton *button = mButtonGroup->selected();
+ TQButton *button = mButtonGroup->selected();
if ( button )
return mEmailMap[ mButtonGroup->id( button ) ];
- return QString::null;
+ return TQString::null;
}
-QString EmailSelector::getEmail( const QStringList &emails,
- const QString &current, QWidget *parent, bool &canceled )
+TQString EmailSelector::getEmail( const TQStringList &emails,
+ const TQString &current, TQWidget *parent, bool &canceled )
{
EmailSelector dlg( emails, current, parent );
if(dlg.exec())
@@ -666,7 +666,7 @@ QString EmailSelector::getEmail( const QStringList &emails,
return dlg.selected();
}
canceled = true;
- return QString();
+ return TQString();
}
diff --git a/kaddressbook/features/distributionlistwidget.h b/kaddressbook/features/distributionlistwidget.h
index d52a06ab..4ee5e76a 100644
--- a/kaddressbook/features/distributionlistwidget.h
+++ b/kaddressbook/features/distributionlistwidget.h
@@ -50,17 +50,17 @@ class DistributionListWidget : public KAB::ExtensionWidget
Q_OBJECT
public:
- DistributionListWidget( KAB::Core*, QWidget *parent, const char *name = 0 );
+ DistributionListWidget( KAB::Core*, TQWidget *parent, const char *name = 0 );
virtual ~DistributionListWidget();
void contactsSelectionChanged();
- QString title() const;
- QString identifier() const;
+ TQString title() const;
+ TQString identifier() const;
public slots:
void save();
- void dropped( QDropEvent*, QListViewItem* );
+ void dropped( TQDropEvent*, TQListViewItem* );
void removeContact();
@@ -80,25 +80,25 @@ class DistributionListWidget : public KAB::ExtensionWidget
#else
void changed();
#endif
- bool alreadyExists( const QString& distrListName ) const;
+ bool alreadyExists( const TQString& distrListName ) const;
protected:
- void dropEvent( QDropEvent* );
+ void dropEvent( TQDropEvent* );
private:
- QComboBox *mNameCombo;
- QLabel *mEntryCountLabel;
+ TQComboBox *mNameCombo;
+ TQLabel *mEntryCountLabel;
DistributionListView *mContactView;
#ifndef KDEPIM_NEW_DISTRLISTS
KABC::DistributionListManager *mManager;
#endif
- QPushButton *mCreateListButton;
- QPushButton *mEditListButton;
- QPushButton *mRemoveListButton;
- QPushButton *mChangeEmailButton;
- QPushButton *mAddContactButton;
- QPushButton *mRemoveContactButton;
+ TQPushButton *mCreateListButton;
+ TQPushButton *mEditListButton;
+ TQPushButton *mRemoveListButton;
+ TQPushButton *mChangeEmailButton;
+ TQPushButton *mAddContactButton;
+ TQPushButton *mRemoveContactButton;
};
/**
@@ -109,13 +109,13 @@ class DistributionListView : public KListView
Q_OBJECT
public:
- DistributionListView( QWidget *parent, const char* name = 0 );
+ DistributionListView( TQWidget *parent, const char* name = 0 );
protected:
- void dragEnterEvent( QDragEnterEvent *e );
- void dropEvent( QDropEvent *e );
- void viewportDragMoveEvent( QDragMoveEvent *e );
- void viewportDropEvent( QDropEvent *e );
+ void dragEnterEvent( TQDragEnterEvent *e );
+ void dropEvent( TQDropEvent *e );
+ void viewportDragMoveEvent( TQDragMoveEvent *e );
+ void viewportDropEvent( TQDropEvent *e );
};
/**
@@ -124,17 +124,17 @@ class DistributionListView : public KListView
class EmailSelector : public KDialogBase
{
public:
- EmailSelector( const QStringList &emails, const QString &current,
- QWidget *parent );
+ EmailSelector( const TQStringList &emails, const TQString &current,
+ TQWidget *parent );
- QString selected() const;
+ TQString selected() const;
- static QString getEmail( const QStringList &emails, const QString &current,
- QWidget *parent, bool &canceled );
+ static TQString getEmail( const TQStringList &emails, const TQString &current,
+ TQWidget *parent, bool &canceled );
private:
- QButtonGroup *mButtonGroup;
- QMap<int, QString> mEmailMap;
+ TQButtonGroup *mButtonGroup;
+ TQMap<int, TQString> mEmailMap;
};
#endif
diff --git a/kaddressbook/features/resourceselection.cpp b/kaddressbook/features/resourceselection.cpp
index dcd40dc1..d6edba25 100644
--- a/kaddressbook/features/resourceselection.cpp
+++ b/kaddressbook/features/resourceselection.cpp
@@ -21,13 +21,13 @@
without including the source code for Qt in the source distribution.
*/
-#include <qlayout.h>
-#include <qpopupmenu.h>
-#include <qpushbutton.h>
-#include <qtimer.h>
-#include <qlabel.h>
-#include <qheader.h>
-#include <qtooltip.h>
+#include <tqlayout.h>
+#include <tqpopupmenu.h>
+#include <tqpushbutton.h>
+#include <tqtimer.h>
+#include <tqlabel.h>
+#include <tqheader.h>
+#include <tqtooltip.h>
#include <kabc/resource.h>
#include <kdialog.h>
@@ -58,7 +58,7 @@ class ResourceItem : public QCheckListItem
{
public:
ResourceItem( KListView *parent, KABC::Resource *resource )
- : QCheckListItem( parent, resource->resourceName(), CheckBox ),
+ : TQCheckListItem( parent, resource->resourceName(), CheckBox ),
mResource( resource ), mChecked( false ),
mIsSubresource( false ), mSubItemsCreated( false ),
mResourceIdentifier()
@@ -69,8 +69,8 @@ class ResourceItem : public QCheckListItem
}
ResourceItem( KPIM::ResourceABC *resourceABC, ResourceItem* parent,
- const QString& resourceIdent )
- : QCheckListItem( parent, resourceABC->subresourceLabel( resourceIdent ), CheckBox ),
+ const TQString& resourceIdent )
+ : TQCheckListItem( parent, resourceABC->subresourceLabel( resourceIdent ), CheckBox ),
mResource( resourceABC ), mChecked( false ),
mIsSubresource( true ), mSubItemsCreated( false ),
mResourceIdentifier( resourceIdent )
@@ -89,7 +89,7 @@ class ResourceItem : public QCheckListItem
}
bool checked() const { return mChecked; }
KABC::Resource *resource() const { return mResource; }
- QString resourceIdentifier() const { return mResourceIdentifier; }
+ TQString resourceIdentifier() const { return mResourceIdentifier; }
bool isSubResource() const { return mIsSubresource; }
virtual void stateChange( bool active );
@@ -99,21 +99,21 @@ class ResourceItem : public QCheckListItem
bool mChecked;
const bool mIsSubresource;
bool mSubItemsCreated;
- const QString mResourceIdentifier;
+ const TQString mResourceIdentifier;
};
// Comes from korganizer/resourceview.cpp
void ResourceItem::createSubresourceItems()
{
KPIM::ResourceABC* res = dynamic_cast<KPIM::ResourceABC *>( mResource );
- QStringList subresources;
+ TQStringList subresources;
if ( res )
subresources = res->subresources();
if ( !subresources.isEmpty() ) {
setOpen( true );
setExpandable( true );
// This resource has subresources
- QStringList::ConstIterator it;
+ TQStringList::ConstIterator it;
for ( it = subresources.begin(); it != subresources.end(); ++it ) {
(void)new ResourceItem( res, this, *it );
}
@@ -134,7 +134,7 @@ void ResourceItem::stateChange( bool active )
////
-ResourceSelection::ResourceSelection( KAB::Core *core, QWidget *parent, const char *name )
+ResourceSelection::ResourceSelection( KAB::Core *core, TQWidget *parent, const char *name )
: KAB::ExtensionWidget( core, parent, name ), mManager( 0 )
{
initGUI();
@@ -142,49 +142,49 @@ ResourceSelection::ResourceSelection( KAB::Core *core, QWidget *parent, const ch
AddressBookWrapper *wrapper = static_cast<AddressBookWrapper*>( core->addressBook() );
mManager = wrapper->getResourceManager();
- connect( mAddButton, SIGNAL( clicked() ), SLOT( add() ) );
- connect( mEditButton, SIGNAL( clicked() ), SLOT( edit() ) );
- connect( mRemoveButton, SIGNAL( clicked() ), SLOT( remove() ) );
+ connect( mAddButton, TQT_SIGNAL( clicked() ), TQT_SLOT( add() ) );
+ connect( mEditButton, TQT_SIGNAL( clicked() ), TQT_SLOT( edit() ) );
+ connect( mRemoveButton, TQT_SIGNAL( clicked() ), TQT_SLOT( remove() ) );
- connect( mListView, SIGNAL( clicked( QListViewItem* ) ),
- SLOT( currentChanged( QListViewItem* ) ) );
+ connect( mListView, TQT_SIGNAL( clicked( TQListViewItem* ) ),
+ TQT_SLOT( currentChanged( TQListViewItem* ) ) );
- connect( mListView, SIGNAL( contextMenuRequested ( QListViewItem *,
- const QPoint &, int ) ),
- SLOT( contextMenuRequested( QListViewItem *, const QPoint &,
+ connect( mListView, TQT_SIGNAL( contextMenuRequested ( TQListViewItem *,
+ const TQPoint &, int ) ),
+ TQT_SLOT( contextMenuRequested( TQListViewItem *, const TQPoint &,
int ) ) );
- QTimer::singleShot( 0, this, SLOT( updateView() ) );
+ TQTimer::singleShot( 0, this, TQT_SLOT( updateView() ) );
}
ResourceSelection::~ResourceSelection()
{
}
-void ResourceSelection::contextMenuRequested ( QListViewItem *i,
- const QPoint &pos, int )
+void ResourceSelection::contextMenuRequested ( TQListViewItem *i,
+ const TQPoint &pos, int )
{
ResourceItem *item = static_cast<ResourceItem *>( i );
- QPopupMenu *menu = new QPopupMenu( this );
- connect( menu, SIGNAL( aboutToHide() ), menu, SLOT( deleteLater() ) );
+ TQPopupMenu *menu = new TQPopupMenu( this );
+ connect( menu, TQT_SIGNAL( aboutToHide() ), menu, TQT_SLOT( deleteLater() ) );
if ( item ) {
int reloadId = menu->insertItem( i18n("Re&load"), this,
- SLOT( reloadResource() ) );
+ TQT_SLOT( reloadResource() ) );
menu->setItemEnabled( reloadId, item->resource()->isActive() );
int saveId = menu->insertItem( i18n("&Save"), this,
- SLOT( saveResource() ) );
+ TQT_SLOT( saveResource() ) );
menu->setItemEnabled( saveId, item->resource()->isActive() );
menu->insertSeparator();
-// menu->insertItem( i18n("Show &Info"), this, SLOT( showInfo() ) );
+// menu->insertItem( i18n("Show &Info"), this, TQT_SLOT( showInfo() ) );
- menu->insertItem( i18n("&Edit..."), this, SLOT( edit() ) );
- menu->insertItem( i18n("&Remove"), this, SLOT( remove() ) );
+ menu->insertItem( i18n("&Edit..."), this, TQT_SLOT( edit() ) );
+ menu->insertItem( i18n("&Remove"), this, TQT_SLOT( remove() ) );
menu->insertSeparator();
}
- menu->insertItem( i18n("&Add..."), this, SLOT( add() ) );
+ menu->insertItem( i18n("&Add..."), this, TQT_SLOT( add() ) );
menu->popup( pos );
}
@@ -215,33 +215,33 @@ void ResourceSelection::showInfo()
ResourceItem *item = selectedItem();
if ( !item ) return;
-// QString txt = "<qt>" + item->resource()->infoText() + "</qt>";
+// TQString txt = "<qt>" + item->resource()->infoText() + "</qt>";
// KMessageBox::information( this, txt );
}
-QString ResourceSelection::title() const
+TQString ResourceSelection::title() const
{
return i18n( "Address Books" );
}
-QString ResourceSelection::identifier() const
+TQString ResourceSelection::identifier() const
{
return "resourceselection";
}
void ResourceSelection::add()
{
- QStringList types = mManager->resourceTypeNames();
- QStringList descs = mManager->resourceTypeDescriptions();
+ TQStringList types = mManager->resourceTypeNames();
+ TQStringList descs = mManager->resourceTypeDescriptions();
bool ok = false;
- QString desc = KInputDialog::getItem( i18n( "Add Address Book" ),
+ TQString desc = KInputDialog::getItem( i18n( "Add Address Book" ),
i18n( "Please select type of the new address book:" ),
descs, 0, false, &ok, this );
if ( !ok )
return;
- QString type = types[ descs.findIndex( desc ) ];
+ TQString type = types[ descs.findIndex( desc ) ];
// Create new resource
KABC::Resource *resource = mManager->createResource( type );
@@ -254,7 +254,7 @@ void ResourceSelection::add()
resource->setResourceName( i18n( "%1 address book" ).arg( type ) );
resource->setAddressBook(core()->addressBook());
- KRES::ConfigDialog dlg( this, QString( "contact" ), resource );
+ KRES::ConfigDialog dlg( this, TQString( "contact" ), resource );
if ( dlg.exec() ) {
core()->addressBook()->addResource( resource );
@@ -279,7 +279,7 @@ void ResourceSelection::edit()
// thus keep their data rather than their pointer
KABC::Resource *resource = item->resource();
- KRES::ConfigDialog dlg( this, QString( "contact" ), resource );
+ KRES::ConfigDialog dlg( this, TQString( "contact" ), resource );
if ( dlg.exec() ) {
mManager->change( resource );
@@ -311,7 +311,7 @@ void ResourceSelection::remove()
updateView();
}
-void ResourceSelection::currentChanged( QListViewItem *item )
+void ResourceSelection::currentChanged( TQListViewItem *item )
{
ResourceItem *resItem = static_cast<ResourceItem*>( item );
bool state = (resItem && !resItem->isSubResource() );
@@ -367,28 +367,28 @@ void ResourceSelection::updateView()
KPIM::ResourceABC* resource = dynamic_cast<KPIM::ResourceABC *>( *it );
if ( resource ) {
disconnect( resource, 0, this, 0 );
- connect( resource, SIGNAL( signalSubresourceAdded( KPIM::ResourceABC *,
- const QString &, const QString & ) ),
- SLOT( slotSubresourceAdded( KPIM::ResourceABC *,
- const QString &, const QString & ) ) );
-
- connect( resource, SIGNAL( signalSubresourceRemoved( KPIM::ResourceABC *,
- const QString &, const QString & ) ),
- SLOT( slotSubresourceRemoved( KPIM::ResourceABC *,
- const QString &, const QString & ) ) );
-
- connect( resource, SIGNAL( signalSubresourceChanged( KPIM::ResourceABC *,
- const QString &, const QString & ) ),
- SLOT( slotSubresourceChanged( KPIM::ResourceABC *,
- const QString &, const QString & ) ) );
-
- //connect( resource, SIGNAL( resourceSaved( KPIM::ResourceABC * ) ),
- // SLOT( closeResource( KPIM::ResourceABC * ) ) );
+ connect( resource, TQT_SIGNAL( signalSubresourceAdded( KPIM::ResourceABC *,
+ const TQString &, const TQString & ) ),
+ TQT_SLOT( slotSubresourceAdded( KPIM::ResourceABC *,
+ const TQString &, const TQString & ) ) );
+
+ connect( resource, TQT_SIGNAL( signalSubresourceRemoved( KPIM::ResourceABC *,
+ const TQString &, const TQString & ) ),
+ TQT_SLOT( slotSubresourceRemoved( KPIM::ResourceABC *,
+ const TQString &, const TQString & ) ) );
+
+ connect( resource, TQT_SIGNAL( signalSubresourceChanged( KPIM::ResourceABC *,
+ const TQString &, const TQString & ) ),
+ TQT_SLOT( slotSubresourceChanged( KPIM::ResourceABC *,
+ const TQString &, const TQString & ) ) );
+
+ //connect( resource, TQT_SIGNAL( resourceSaved( KPIM::ResourceABC * ) ),
+ // TQT_SLOT( closeResource( KPIM::ResourceABC * ) ) );
item->createSubresourceItems();
}
}
- QListViewItemIterator itemIt( mListView );
+ TQListViewItemIterator itemIt( mListView );
while ( itemIt.current() ) {
ResourceItem *item = static_cast<ResourceItem*>( itemIt.current() );
if ( item->resource()->identifier() == mLastResource ) {
@@ -405,11 +405,11 @@ void ResourceSelection::updateView()
// Add a new entry
void ResourceSelection::slotSubresourceAdded( KPIM::ResourceABC *resource,
- const QString& /*type*/,
- const QString& subResource )
+ const TQString& /*type*/,
+ const TQString& subResource )
{
kdDebug(5720) << k_funcinfo << resource->resourceName() << " " << subResource << endl;
- QListViewItem *i = mListView->findItem( resource->resourceName(), 0 );
+ TQListViewItem *i = mListView->findItem( resource->resourceName(), 0 );
if ( !i )
// Not found
return;
@@ -426,8 +426,8 @@ void ResourceSelection::slotSubresourceAdded( KPIM::ResourceABC *resource,
// Remove an entry
void ResourceSelection::slotSubresourceRemoved( KPIM::ResourceABC* resource,
- const QString& /*type*/,
- const QString& subResource )
+ const TQString& /*type*/,
+ const TQString& subResource )
{
ResourceItem *item = findSubResourceItem( resource, subResource );
delete item;
@@ -437,8 +437,8 @@ void ResourceSelection::slotSubresourceRemoved( KPIM::ResourceABC* resource,
// change an entry
void ResourceSelection::slotSubresourceChanged( KPIM::ResourceABC* resource,
- const QString& type,
- const QString& subResource )
+ const TQString& type,
+ const TQString& subResource )
{
kdDebug(5720) << resource->resourceName() << subResource;
@@ -463,14 +463,14 @@ ResourceItem* ResourceSelection::selectedItem() const
}
ResourceItem* ResourceSelection::findSubResourceItem( KPIM::ResourceABC *resource,
- const QString &subResource )
+ const TQString &subResource )
{
- QListViewItemIterator parentIt( mListView );
+ TQListViewItemIterator parentIt( mListView );
for ( ; *parentIt; ++parentIt ) {
if ( static_cast<ResourceItem*>(*parentIt)->resource() != resource )
continue;
- QListViewItemIterator childIt( *parentIt );
+ TQListViewItemIterator childIt( *parentIt );
for ( ; *childIt; ++childIt ) {
ResourceItem *item = static_cast<ResourceItem*>(*childIt);
if ( item->resourceIdentifier() == subResource )
@@ -483,30 +483,30 @@ ResourceItem* ResourceSelection::findSubResourceItem( KPIM::ResourceABC *resourc
void ResourceSelection::initGUI()
{
- QBoxLayout *topLayout = new QVBoxLayout( this );
+ TQBoxLayout *topLayout = new TQVBoxLayout( this );
topLayout->setSpacing( KDialog::spacingHint() );
- QBoxLayout *buttonLayout = new QHBoxLayout();
+ TQBoxLayout *buttonLayout = new TQHBoxLayout();
buttonLayout->setSpacing( KDialog::spacingHint() );
topLayout->addLayout( buttonLayout );
- QLabel *abLabel = new QLabel( i18n( "Address Books" ), this );
+ TQLabel *abLabel = new TQLabel( i18n( "Address Books" ), this );
buttonLayout->addWidget( abLabel );
buttonLayout->addStretch( 1 );
- mAddButton = new QPushButton( this );
+ mAddButton = new TQPushButton( this );
mAddButton->setIconSet( SmallIconSet( "add" ) );
- QToolTip::add( mAddButton, i18n( "Add addressbook" ) );
+ TQToolTip::add( mAddButton, i18n( "Add addressbook" ) );
buttonLayout->addWidget( mAddButton );
- mEditButton = new QPushButton( this );
+ mEditButton = new TQPushButton( this );
mEditButton->setIconSet( SmallIconSet( "edit" ) );
mEditButton->setEnabled( false );
- QToolTip::add( mEditButton, i18n( "Edit addressbook settings" ) );
+ TQToolTip::add( mEditButton, i18n( "Edit addressbook settings" ) );
buttonLayout->addWidget( mEditButton );
- mRemoveButton = new QPushButton( this );
+ mRemoveButton = new TQPushButton( this );
mRemoveButton->setIconSet( SmallIconSet( "remove" ) );
mRemoveButton->setEnabled( false );
- QToolTip::add( mRemoveButton, i18n( "Remove addressbook" ) );
+ TQToolTip::add( mRemoveButton, i18n( "Remove addressbook" ) );
buttonLayout->addWidget( mRemoveButton );
mListView = new KListView( this );
@@ -519,12 +519,12 @@ void ResourceSelection::initGUI()
class ResourceSelectionFactory : public KAB::ExtensionFactory
{
public:
- KAB::ExtensionWidget *extension( KAB::Core *core, QWidget *parent, const char *name )
+ KAB::ExtensionWidget *extension( KAB::Core *core, TQWidget *parent, const char *name )
{
return new ResourceSelection( core, parent, name );
}
- QString identifier() const
+ TQString identifier() const
{
return "resourceselection";
}
diff --git a/kaddressbook/features/resourceselection.h b/kaddressbook/features/resourceselection.h
index a2eff8c1..831cc4a5 100644
--- a/kaddressbook/features/resourceselection.h
+++ b/kaddressbook/features/resourceselection.h
@@ -40,11 +40,11 @@ class ResourceSelection : public KAB::ExtensionWidget
Q_OBJECT
public:
- ResourceSelection( KAB::Core*, QWidget *parent, const char *name );
+ ResourceSelection( KAB::Core*, TQWidget *parent, const char *name );
virtual ~ResourceSelection();
- QString title() const;
- QString identifier() const;
+ TQString title() const;
+ TQString identifier() const;
void contactsSelectionChanged() {};
@@ -52,21 +52,21 @@ class ResourceSelection : public KAB::ExtensionWidget
void add();
void edit();
void remove();
- void currentChanged( QListViewItem* );
+ void currentChanged( TQListViewItem* );
void updateView();
void slotSubresourceAdded( KPIM::ResourceABC *resource,
- const QString& /*type*/,
- const QString& subResource );
+ const TQString& /*type*/,
+ const TQString& subResource );
void slotSubresourceRemoved( KPIM::ResourceABC* /*resource*/,
- const QString& /*type*/,
- const QString& subResource );
+ const TQString& /*type*/,
+ const TQString& subResource );
void slotSubresourceChanged( KPIM::ResourceABC* /*resource*/,
- const QString& /*type*/,
- const QString& subResource );
+ const TQString& /*type*/,
+ const TQString& subResource );
- void contextMenuRequested ( QListViewItem *i, const QPoint &pos, int );
+ void contextMenuRequested ( TQListViewItem *i, const TQPoint &pos, int );
void showInfo();
@@ -77,14 +77,14 @@ class ResourceSelection : public KAB::ExtensionWidget
void initGUI();
ResourceItem* selectedItem() const;
- ResourceItem* findSubResourceItem( KPIM::ResourceABC *resource, const QString &subResource );
+ ResourceItem* findSubResourceItem( KPIM::ResourceABC *resource, const TQString &subResource );
KListView *mListView;
- QPushButton *mAddButton;
- QPushButton *mEditButton;
- QPushButton *mRemoveButton;
+ TQPushButton *mAddButton;
+ TQPushButton *mEditButton;
+ TQPushButton *mRemoveButton;
- QString mLastResource;
+ TQString mLastResource;
KRES::Manager<KABC::Resource> *mManager;
};