diff options
| author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-14 16:45:05 +0000 |
|---|---|---|
| committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-14 16:45:05 +0000 |
| commit | 48d4a26399959121f33d2bc3bfe51c7827b654fc (patch) | |
| tree | 5ae5e6e00d3ba330b7b8be9bc097154b6bc739e8 /languages/cpp/pcsimporter/qtimporter/settingsdialog.cpp | |
| parent | 7e701ace6592d09e1f2c0cf28c7d6d872d78f4f5 (diff) | |
| download | tdevelop-48d4a26399959121f33d2bc3bfe51c7827b654fc.tar.gz tdevelop-48d4a26399959121f33d2bc3bfe51c7827b654fc.zip | |
TQt4 port kdevelop
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdevelop@1236710 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'languages/cpp/pcsimporter/qtimporter/settingsdialog.cpp')
| -rw-r--r-- | languages/cpp/pcsimporter/qtimporter/settingsdialog.cpp | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/languages/cpp/pcsimporter/qtimporter/settingsdialog.cpp b/languages/cpp/pcsimporter/qtimporter/settingsdialog.cpp index 2df475b7..a03ac0d4 100644 --- a/languages/cpp/pcsimporter/qtimporter/settingsdialog.cpp +++ b/languages/cpp/pcsimporter/qtimporter/settingsdialog.cpp @@ -27,20 +27,20 @@ #include "settingsdialog.h" -TQListBoxItem* QListBox_selectedItem( TQListBox* cpQListBox ) +TQListBoxItem* TQListBox_selectedItem( TQListBox* cpTQListBox ) { - if ( cpQListBox->selectionMode() != TQListBox::Single ) + if ( cpTQListBox->selectionMode() != TQListBox::Single ) return 0; - if ( cpQListBox->isSelected( cpQListBox->currentItem() ) ) - return cpQListBox->item( cpQListBox->currentItem() ); + if ( cpTQListBox->isSelected( cpTQListBox->currentItem() ) ) + return cpTQListBox->item( cpTQListBox->currentItem() ); return 0; } -SettingsDialog::SettingsDialog( TQWidget* parent, const char* name, WFlags fl ) - : SettingsDialogBase( parent, name, fl ) +SettingsDialog::SettingsDialog( TQWidget* tqparent, const char* name, WFlags fl ) + : SettingsDialogBase( tqparent, name, fl ) { TQStringList qtdirs; - qtdirs.push_back( ::getenv( "QTDIR" ) + TQString("/include") ); + qtdirs.push_back( ::getenv( "TQTDIR" ) + TQString("/include") ); qtdirs.push_back( "/usr/lib/qt3/include" ); qtdirs.push_back( "/usr/lib/qt/include" ); qtdirs.push_back( "/usr/share/qt3/include" ); @@ -49,8 +49,8 @@ SettingsDialog::SettingsDialog( TQWidget* parent, const char* name, WFlags fl ) for ( TQStringList::Iterator it = qtdirs.begin(); it != qtdirs.end(); ++it ) { TQString qtdir = *it; - if ( !qtdir.isEmpty() && isValidQtDir( qtdir ) ) - if ( !qtListBox->findItem( qtdir, ExactMatch ) ) + if ( !qtdir.isEmpty() && isValidTQtDir( qtdir ) ) + if ( !qtListBox->tqfindItem( qtdir, ExactMatch ) ) qtListBox->insertItem( qtdir ); } @@ -71,9 +71,9 @@ void SettingsDialog::slotSelectionChanged( TQListBoxItem* ) } TQDir dir( qtDir() ); - TQStringList qconfigFileList = dir.entryList( "qconfig-*.h" ); + TQStringList qconfigFileList = dir.entryList( "tqconfig-*.h" ); qtConfiguration->clear(); - TQRegExp rx( "qconfig-(\\w+)\\.h" ); + TQRegExp rx( "tqconfig-(\\w+)\\.h" ); for ( TQStringList::Iterator it = qconfigFileList.begin(); it != qconfigFileList.end(); ++it ) { ( void ) rx.exactMatch( *it ); @@ -83,7 +83,7 @@ void SettingsDialog::slotSelectionChanged( TQListBoxItem* ) emit enabled( true ); } -bool SettingsDialog::isValidQtDir( const TQString & path ) const +bool SettingsDialog::isValidTQtDir( const TQString & path ) const { return TQFile::exists( path + "/tqt.h" ); } @@ -101,10 +101,10 @@ void SettingsDialog::addUrlButton_clicked( ) { kdDebug(9000) << k_funcinfo << endl; - if ( isValidQtDir( qtUrl->url() ) ) + if ( isValidTQtDir( qtUrl->url() ) ) { qtListBox->insertItem( qtUrl->url() ); - if ( TQListBoxItem * item = qtListBox->findItem( qtUrl->url(), ExactMatch ) ) + if ( TQListBoxItem * item = qtListBox->tqfindItem( qtUrl->url(), ExactMatch ) ) { qtListBox->setSelected( item, true ); } @@ -112,7 +112,7 @@ void SettingsDialog::addUrlButton_clicked( ) } else { - KMessageBox::error( this, i18n("This does not appear to be a valid Qt3 include directory.\nPlease select a different directory."), i18n("Invalid Directory") ); + KMessageBox::error( this, i18n("This does not appear to be a valid TQt3 include directory.\nPlease select a different directory."), i18n("Invalid Directory") ); } } |
