diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-25 05:28:35 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-25 05:28:35 +0000 |
commit | f008adb5a77e094eaf6abf3fc0f36958e66896a5 (patch) | |
tree | 8e9244c4d4957c36be81e15b566b4aa5ea26c982 /kexi/widget/kexidbdrivercombobox.cpp | |
parent | 1210f27b660efb7b37ff43ec68763e85a403471f (diff) | |
download | koffice-f008adb5a77e094eaf6abf3fc0f36958e66896a5.tar.gz koffice-f008adb5a77e094eaf6abf3fc0f36958e66896a5.zip |
TQt4 port koffice
This should enable compilation under both Qt3 and Qt4; fixes for any missed components will be forthcoming
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/koffice@1238284 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kexi/widget/kexidbdrivercombobox.cpp')
-rw-r--r-- | kexi/widget/kexidbdrivercombobox.cpp | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/kexi/widget/kexidbdrivercombobox.cpp b/kexi/widget/kexidbdrivercombobox.cpp index e3431531..8026106d 100644 --- a/kexi/widget/kexidbdrivercombobox.cpp +++ b/kexi/widget/kexidbdrivercombobox.cpp @@ -19,17 +19,17 @@ #include "kexidbdrivercombobox.h" -#include <qlistbox.h> +#include <tqlistbox.h> #include <kiconloader.h> -KexiDBDriverComboBox::KexiDBDriverComboBox(QWidget* parent, const KexiDB::Driver::InfoMap& driversInfo, +KexiDBDriverComboBox::KexiDBDriverComboBox(TQWidget* tqparent, const KexiDB::Driver::InfoMap& driversInfo, Options options) - : KComboBox(parent, "KexiDBDriverComboBox") + : KComboBox(tqparent, "KexiDBDriverComboBox") { //retrieve list of drivers and sort it: file-based first, then server-based - QStringList captionsForFileBasedDrivers, captionsForServerBasedDrivers; - QMap<QString,QString> fileBasedDriversDict, serverBasedDriversDict; //a map from caption to name + TQStringList captionsForFileBasedDrivers, captionsForServerBasedDrivers; + TQMap<TQString,TQString> fileBasedDriversDict, serverBasedDriversDict; //a map from caption to name foreach(KexiDB::Driver::InfoMap::ConstIterator, it, driversInfo) { if (it.data().fileBased) { captionsForFileBasedDrivers += it.data().caption; @@ -44,7 +44,7 @@ KexiDBDriverComboBox::KexiDBDriverComboBox(QWidget* parent, const KexiDB::Driver captionsForServerBasedDrivers.sort(); //insert file-based if (options & ShowFileDrivers) { - foreach(QStringList::ConstIterator, it, captionsForFileBasedDrivers) { + foreach(TQStringList::ConstIterator, it, captionsForFileBasedDrivers) { const KexiDB::Driver::Info& info = driversInfo[ fileBasedDriversDict[ *it ] ]; //! @todo change this if better icon is available insertItem( SmallIcon("gear"), info.caption ); @@ -53,7 +53,7 @@ KexiDBDriverComboBox::KexiDBDriverComboBox(QWidget* parent, const KexiDB::Driver } //insert server-based if (options & ShowServerDrivers) { - foreach(QStringList::ConstIterator, it, captionsForServerBasedDrivers) { + foreach(TQStringList::ConstIterator, it, captionsForServerBasedDrivers) { const KexiDB::Driver::Info& info = driversInfo[ serverBasedDriversDict[ *it ] ]; //! @todo change this if better icon is available insertItem( SmallIcon("gear"), info.caption ); @@ -72,17 +72,17 @@ KexiDBDriverComboBox::~KexiDBDriverComboBox() { } -QString KexiDBDriverComboBox::selectedDriverName() const +TQString KexiDBDriverComboBox::selectedDriverName() const { - QMapConstIterator<QString,QString> it( m_driversMap.find( text( currentItem() ) ) ); + TQMapConstIterator<TQString,TQString> it( m_driversMap.tqfind( text( currentItem() ) ) ); if (it==m_driversMap.constEnd()) - return QString::null; + return TQString(); return it.data(); } -void KexiDBDriverComboBox::setDriverName(const QString& driverName) +void KexiDBDriverComboBox::setDriverName(const TQString& driverName) { - int index = m_driverNames.findIndex( driverName.lower() ); + int index = m_driverNames.tqfindIndex( driverName.lower() ); if (index==-1) { return; } |