diff options
author | Michele Calgaro <[email protected]> | 2023-07-13 21:45:56 +0900 |
---|---|---|
committer | Michele Calgaro <[email protected]> | 2023-07-14 09:58:29 +0900 |
commit | 60598ea23e9fec7b4320985aad848c5ffee033c2 (patch) | |
tree | 169801c444ffe73c517d5b1cdc62a39efb8c7392 /buildtools/qmake | |
parent | b8cc513c5e875739c6790da651f6a3f47ed8f657 (diff) | |
download | tdevelop-60598ea23e9fec7b4320985aad848c5ffee033c2.tar.gz tdevelop-60598ea23e9fec7b4320985aad848c5ffee033c2.zip |
Removed Qt4 specific code and template files
Signed-off-by: Michele Calgaro <[email protected]>
Diffstat (limited to 'buildtools/qmake')
-rw-r--r-- | buildtools/qmake/projectconfigurationdlg.cpp | 183 | ||||
-rw-r--r-- | buildtools/qmake/projectconfigurationdlgbase.ui | 181 | ||||
-rw-r--r-- | buildtools/qmake/qmakescopeitem.cpp | 10 | ||||
-rw-r--r-- | buildtools/qmake/scope.cpp | 42 | ||||
-rw-r--r-- | buildtools/qmake/scope.h | 3 | ||||
-rw-r--r-- | buildtools/qmake/trollprojectpart.cpp | 30 | ||||
-rw-r--r-- | buildtools/qmake/trollprojectpart.h | 1 | ||||
-rw-r--r-- | buildtools/qmake/trollprojectwidget.cpp | 39 |
8 files changed, 27 insertions, 462 deletions
diff --git a/buildtools/qmake/projectconfigurationdlg.cpp b/buildtools/qmake/projectconfigurationdlg.cpp index fec743cb..25137f04 100644 --- a/buildtools/qmake/projectconfigurationdlg.cpp +++ b/buildtools/qmake/projectconfigurationdlg.cpp @@ -327,89 +327,6 @@ void ProjectConfigurationDlg::updateProjectConfiguration() else myProjectItem->removeValue( "CONFIG", "windows" ); - //TQt4 libs - if ( prjWidget->m_part->isTQt4Project() ) - { - if ( checkDebugReleaseMode->isChecked() ) - myProjectItem->addValue( "CONFIG", "debug_and_release" ); - else - myProjectItem->removeValue( "CONFIG", "debug_and_release" ); - - if ( checkTestlib->isChecked() ) - myProjectItem->addValue( "CONFIG", "qtestlib" ); - else - myProjectItem->removeValue( "CONFIG", "qtestlib" ); - if ( checkAssistant->isChecked() ) - myProjectItem->addValue( "CONFIG", "assistant" ); - else - myProjectItem->removeValue( "CONFIG", "assistant" ); - if ( checkUiTools->isChecked() ) - myProjectItem->addValue( "CONFIG", "uitools" ); - else - myProjectItem->removeValue( "CONFIG", "uitools" ); - if ( checkQDBus->isChecked() ) - myProjectItem->addValue( "CONFIG", "dbus" ); - else - myProjectItem->removeValue( "CONFIG", "dbus" ); - if ( checkBuildAll->isChecked() ) - myProjectItem->addValue( "CONFIG", "build_all" ); - else - myProjectItem->removeValue( "CONFIG", "build_all" ); - if ( checkQtHelp->isChecked() ) - myProjectItem->addValue( "CONFIG", "help" ); - else - myProjectItem->removeValue( "CONFIG", "help" ); - - if ( checkQt4Core->isChecked() ) - myProjectItem->addValue( "QT", "core" ); - else - myProjectItem->removeValue( "QT", "core" ); - if ( checkQt4Gui->isChecked() ) - myProjectItem->addValue( "QT", "gui" ); - else - myProjectItem->removeValue( "QT", "gui" ); - if ( checkQt4SQL->isChecked() ) - myProjectItem->addValue( "QT", "sql" ); - else - myProjectItem->removeValue( "QT", "sql" ); - if ( checkQt4SVG->isChecked() ) - myProjectItem->addValue( "QT", "svg" ); - else - myProjectItem->removeValue( "QT", "svg" ); - if ( checkQt4XML->isChecked() ) - myProjectItem->addValue( "QT", "xml" ); - else - myProjectItem->removeValue( "QT", "xml" ); - if ( checkQt4Network->isChecked() ) - myProjectItem->addValue( "QT", "network" ); - else - myProjectItem->removeValue( "QT", "network" ); - if ( checkQt3Support->isChecked() ) - myProjectItem->addValue( "QT", "qt3support" ); - else - myProjectItem->removeValue( "QT", "qt3support" ); - if ( checkQt4OpenGL->isChecked() ) - myProjectItem->addValue( "QT", "opengl" ); - else - myProjectItem->removeValue( "QT", "opengl" ); - if ( checkQtScript->isChecked() ) - myProjectItem->addValue( "QT", "script" ); - else - myProjectItem->removeValue( "QT", "script" ); - if ( checkQtWebKit->isChecked() ) - myProjectItem->addValue( "QT", "webkit" ); - else - myProjectItem->removeValue( "QT", "webkit" ); - if ( checkQtXmlPatterns->isChecked() ) - myProjectItem->addValue( "QT", "xmlpatterns" ); - else - myProjectItem->removeValue( "QT", "xmlpatterns" ); - if ( checkPhonon->isChecked() ) - myProjectItem->addValue( "QT", "phonon" ); - else - myProjectItem->removeValue( "QT", "phonon" ); - } - TQStringList confValues = myProjectItem->scope->variableValues( "CONFIG" ); TQStringList extraValues = TQStringList::split( " ", editConfigExtra->text() ); for ( TQStringList::iterator it = confValues.begin() ; it != confValues.end() ; ++it ) @@ -667,8 +584,6 @@ void ProjectConfigurationDlg::updateControls() { sharedRadio->setChecked( true ); checkPlugin->setEnabled( true ); - if( prjWidget->m_part->isTQt4Project() ) - checkDesigner->setEnabled( true ); m_targetLibraryVersion->setText( myProjectItem->scope->variableValues( "VERSION" ).front() ); } else @@ -805,92 +720,6 @@ void ProjectConfigurationDlg::updateControls() else checkWindows->setChecked( false ); - //TQt4 libs - if ( prjWidget->m_part->isTQt4Project() ) - { - - if ( configValues.findIndex( "assistant" ) != -1 ) - checkAssistant->setChecked( true ); - else - checkAssistant->setChecked( false ); - if ( configValues.findIndex( "qtestlib" ) != -1 ) - checkTestlib->setChecked( true ); - else - checkTestlib->setChecked( false ); - if ( configValues.findIndex( "uitools" ) != -1 ) - checkUiTools->setChecked( true ); - else - checkUiTools->setChecked( false ); - if ( configValues.findIndex( "dbus" ) != -1 ) - checkQDBus->setChecked( true ); - else - checkQDBus->setChecked( false ); - if ( configValues.findIndex( "build_all" ) != -1 ) - checkBuildAll->setChecked( true ); - else - checkBuildAll->setChecked( false ); - if ( configValues.findIndex( "help" ) != -1 ) - checkQtHelp->setChecked( true ); - else - checkQtHelp->setChecked( false ); - - TQStringList qtLibs = myProjectItem->scope->variableValues( "QT" ); - if ( qtLibs.findIndex( "core" ) != -1 ) - checkQt4Core->setChecked( true ); - else - checkQt4Core->setChecked( false ); - if ( qtLibs.findIndex( "gui" ) != -1 ) - checkQt4Gui->setChecked( true ); - else - checkQt4Gui->setChecked( false ); - if ( qtLibs.findIndex( "sql" ) != -1 ) - checkQt4SQL->setChecked( true ); - else - checkQt4SQL->setChecked( false ); - if ( qtLibs.findIndex( "xml" ) != -1 ) - checkQt4XML->setChecked( true ); - else - checkQt4XML->setChecked( false ); - if ( qtLibs.findIndex( "network" ) != -1 ) - checkQt4Network->setChecked( true ); - else - checkQt4Network->setChecked( false ); - if ( qtLibs.findIndex( "svg" ) != -1 ) - checkQt4SVG->setChecked( true ); - else - checkQt4SVG->setChecked( false ); - if ( qtLibs.findIndex( "opengl" ) != -1 ) - checkQt4OpenGL->setChecked( true ); - else - checkQt4OpenGL->setChecked( false ); - if ( qtLibs.findIndex( "qt3support" ) != -1 ) - checkQt3Support->setChecked( true ); - else - checkQt3Support->setChecked( false ); - if ( qtLibs.findIndex( "script" ) != -1 ) - checkQtScript->setChecked( true ); - else - checkQtScript->setChecked( false ); - if ( qtLibs.findIndex( "phonon" ) != -1 ) - checkPhonon->setChecked( true ); - else - checkPhonon->setChecked( false ); - if ( qtLibs.findIndex( "webkit" ) != -1 ) - checkQtWebKit->setChecked( true ); - else - checkQtWebKit->setChecked( false ); - if ( qtLibs.findIndex( "xmlpatterns" ) != -1 ) - checkQtXmlPatterns->setChecked( true ); - else - checkQtXmlPatterns->setChecked( false ); - - checkDebugReleaseMode->setEnabled( true ); - checkBuildAll->setEnabled( true ); - groupQt4Libs->setEnabled( checkQt->isChecked() ); - rccdir_url->setEnabled( true ); - rccdir_label->setEnabled( true ); - } - //fill the custom config edit TQStringList extraValues; for ( TQStringList::const_iterator it = configValues.begin() ; it != configValues.end() ; ++it ) @@ -1882,10 +1711,6 @@ void ProjectConfigurationDlg::groupLibrariesChanged( int ) checkPlugin->setEnabled( true ); checkDesigner->setEnabled( checkPlugin->isChecked() ); } - else if ( checkPlugin->isChecked() && prjWidget->m_part->isTQt4Project() ) - { - checkDesigner->setEnabled( true ); - } else { checkDesigner->setEnabled( false ); @@ -1978,14 +1803,6 @@ void ProjectConfigurationDlg::groupTemplateChanged( int ) void ProjectConfigurationDlg::groupRequirementsChanged( int ) { - if ( checkQt->isChecked() && prjWidget->m_part->isTQt4Project() ) - { - groupQt4Libs->setEnabled( true ); - } - else - { - groupQt4Libs->setEnabled( false ); - } activateApply( 0 ); } diff --git a/buildtools/qmake/projectconfigurationdlgbase.ui b/buildtools/qmake/projectconfigurationdlgbase.ui index 28003188..09193bdf 100644 --- a/buildtools/qmake/projectconfigurationdlgbase.ui +++ b/buildtools/qmake/projectconfigurationdlgbase.ui @@ -584,164 +584,6 @@ </widget> <widget class="TQButtonGroup"> <property name="name"> - <cstring>groupQt4Libs</cstring> - </property> - <property name="enabled"> - <bool>false</bool> - </property> - <property name="title"> - <string>Qt4 Libraries</string> - </property> - <grid> - <property name="name"> - <cstring>unnamed</cstring> - </property> - <widget class="TQCheckBox" row="1" column="0"> - <property name="name"> - <cstring>checkQt4Gui</cstring> - </property> - <property name="text"> - <string>Gui</string> - </property> - <property name="checked"> - <bool>true</bool> - </property> - </widget> - <widget class="TQCheckBox" row="2" column="0"> - <property name="name"> - <cstring>checkQt4XML</cstring> - </property> - <property name="text"> - <string>XML</string> - </property> - </widget> - <widget class="TQCheckBox" row="3" column="0"> - <property name="name"> - <cstring>checkQt4Network</cstring> - </property> - <property name="text"> - <string>Network</string> - </property> - </widget> - <widget class="TQCheckBox" row="0" column="0"> - <property name="name"> - <cstring>checkQt4Core</cstring> - </property> - <property name="text"> - <string>Core</string> - </property> - <property name="checked"> - <bool>true</bool> - </property> - </widget> - <widget class="TQCheckBox" row="0" column="1"> - <property name="name"> - <cstring>checkQt4OpenGL</cstring> - </property> - <property name="text"> - <string>OpenGL</string> - </property> - </widget> - <widget class="TQCheckBox" row="1" column="1"> - <property name="name"> - <cstring>checkUiTools</cstring> - </property> - <property name="text"> - <string>QtUiTools</string> - </property> - </widget> - <widget class="TQCheckBox" row="2" column="1"> - <property name="name"> - <cstring>checkQt4SQL</cstring> - </property> - <property name="text"> - <string>SQL</string> - </property> - </widget> - <widget class="TQCheckBox" row="3" column="1"> - <property name="name"> - <cstring>checkQt4SVG</cstring> - </property> - <property name="text"> - <string>SVG</string> - </property> - </widget> - <widget class="TQCheckBox" row="0" column="2"> - <property name="name"> - <cstring>checkTestlib</cstring> - </property> - <property name="text"> - <string>QtTest</string> - </property> - </widget> - <widget class="TQCheckBox" row="1" column="2"> - <property name="name"> - <cstring>checkQt3Support</cstring> - </property> - <property name="text"> - <string>Qt3 Support</string> - </property> - </widget> - <widget class="TQCheckBox" row="2" column="2"> - <property name="name"> - <cstring>checkQDBus</cstring> - </property> - <property name="text"> - <string>QDBus (Qt4.2)</string> - </property> - </widget> - <widget class="TQCheckBox" row="3" column="2"> - <property name="name"> - <cstring>checkAssistant</cstring> - </property> - <property name="text"> - <string>QtAssistant</string> - </property> - </widget> - <widget class="TQCheckBox" row="0" column="3"> - <property name="name"> - <cstring>checkQtScript</cstring> - </property> - <property name="text"> - <string>QtScript (Qt4.3)</string> - </property> - </widget> - <widget class="TQCheckBox" row="1" column="3"> - <property name="name"> - <cstring>checkQtWebKit</cstring> - </property> - <property name="text"> - <string>QtWebKit (Qt4.4)</string> - </property> - </widget> - <widget class="TQCheckBox" row="2" column="3"> - <property name="name"> - <cstring>checkQtXmlPatterns</cstring> - </property> - <property name="text"> - <string>QtXmlPatterns (Qt4.4)</string> - </property> - </widget> - <widget class="TQCheckBox" row="3" column="3"> - <property name="name"> - <cstring>checkPhonon</cstring> - </property> - <property name="text"> - <string>Phonon (Qt4.4)</string> - </property> - </widget> - <widget class="TQCheckBox" row="0" column="4"> - <property name="name"> - <cstring>checkQtHelp</cstring> - </property> - <property name="text"> - <string>QtHelp (Qt4.4)</string> - </property> - </widget> - </grid> - </widget> - <widget class="TQButtonGroup"> - <property name="name"> <cstring>groupLibraries</cstring> </property> <property name="title"> @@ -2317,12 +2159,6 @@ <slot>activateApply(int)</slot> </connection> <connection> - <sender>groupQt4Libs</sender> - <signal>clicked(int)</signal> - <receiver>ProjectConfigurationDlgBase</receiver> - <slot>activateApply(int)</slot> - </connection> - <connection> <sender>insideinc_listview</sender> <signal>clicked(TQListViewItem*)</signal> <receiver>ProjectConfigurationDlgBase</receiver> @@ -2697,23 +2533,6 @@ <tabstop>checkConsole</tabstop> <tabstop>checkPCH</tabstop> <tabstop>editConfigExtra</tabstop> - <tabstop>checkQt4Core</tabstop> - <tabstop>checkQt4Gui</tabstop> - <tabstop>checkQt4XML</tabstop> - <tabstop>checkQt4Network</tabstop> - <tabstop>checkQt4OpenGL</tabstop> - <tabstop>checkUiTools</tabstop> - <tabstop>checkQt4SQL</tabstop> - <tabstop>checkQt4SVG</tabstop> - <tabstop>checkTestlib</tabstop> - <tabstop>checkQt3Support</tabstop> - <tabstop>checkQDBus</tabstop> - <tabstop>checkAssistant</tabstop> - <tabstop>checkQtScript</tabstop> - <tabstop>checkQtWebKit</tabstop> - <tabstop>checkQtXmlPatterns</tabstop> - <tabstop>checkPhonon</tabstop> - <tabstop>checkQtHelp</tabstop> <tabstop>staticRadio</tabstop> <tabstop>checkPlugin</tabstop> <tabstop>checkLibtool</tabstop> diff --git a/buildtools/qmake/qmakescopeitem.cpp b/buildtools/qmake/qmakescopeitem.cpp index 6549a557..ec0cd2af 100644 --- a/buildtools/qmake/qmakescopeitem.cpp +++ b/buildtools/qmake/qmakescopeitem.cpp @@ -649,16 +649,6 @@ void QMakeScopeItem::buildGroups() item->files.append( createFileItem( *it ) ); } - if ( scope->isTQt4Project() ) - { - values = scope->variableValues( "RESOURCES" ); - item = createGroupItem( GroupItem::Resources, "RESOURCES", this ); - groups.insert( item->groupType, item ); - for ( it = values.begin(); it != values.end(); ++it ) - { - item->files.append( createFileItem( *it ) ); - } - } values = scope->variableValues( "IMAGES" ); item = createGroupItem( GroupItem::Images, "IMAGES", this ); groups.insert( item->groupType, item ); diff --git a/buildtools/qmake/scope.cpp b/buildtools/qmake/scope.cpp index 84052970..4e2b079a 100644 --- a/buildtools/qmake/scope.cpp +++ b/buildtools/qmake/scope.cpp @@ -514,10 +514,7 @@ Scope* Scope::createSimpleScope( const TQString& scopename ) ast->setDepth( m_root->depth() ); m_root->addChildAST( ast ); m_root->addChildAST( new TQMake::NewLineAST() ); - /* We can't unconditionally add the scope name to CONFIG, scope might be win32 which may only be in CONFIG under windows. - if ( m_part->isTQt4Project() ) - addToPlusOp( "CONFIG", TQStringList( scopename ) ); - */ + // We can't unconditionally add the scope name to CONFIG, scope might be win32 which may only be in CONFIG under windows. Scope* simpleScope = new Scope( m_environment, getNextScopeNum(), this, ast, m_defaultopts, m_part ); if( simpleScope->scopeType() != Scope::InvalidScope ) @@ -1182,11 +1179,6 @@ TQStringList Scope::cleanStringList(const TQStringList& list) const return result; } -bool Scope::isTQt4Project() const -{ - return m_part->isTQt4Project(); -} - void Scope::reloadProject() { if ( !m_root || !m_root->isProject() ) @@ -1426,16 +1418,6 @@ void Scope::allFiles( const TQString& projectDirectory, std::set<TQString>& res } } - if ( isTQt4Project() ) - { - values = variableValues( "RESOURCES" ,false, false ); - for ( it = values.begin(); it != values.end(); ++it ) - { - file = myRelPath + TQString(TQChar(TQDir::separator())) + *it; - file = resolveVariables( file ); - res.insert( TQDir::cleanDirPath( file ) ); - } - } values = variableValues( "IMAGES" ,false, false ); for ( it = values.begin(); it != values.end(); ++it ) { @@ -1481,22 +1463,12 @@ void Scope::allFiles( const TQString& projectDirectory, std::set<TQString>& res file = resolveVariables( file ); res.insert( TQDir::cleanDirPath( file ) ); - if( !m_part->isTQt4Project()) - { - header = projectDir()+TQString(TQChar(TQDir::separator())) + *it+".h"; - if( TQFileInfo(header).exists() ) - res.insert( TQDir::cleanDirPath( header ) ); - header = projectDir()+TQString(TQChar(TQDir::separator())) + *it+".cpp"; - if( TQFileInfo(header).exists() ) - res.insert( TQDir::cleanDirPath( header ) ); - } - else - { - header = projectDir()+TQString(TQChar(TQDir::separator())) + "ui_" +*it; - header.replace(TQRegExp("\\.ui$"),".h"); - if( TQFileInfo(header).exists() ) - res.insert( TQDir::cleanDirPath( header ) ); - } + header = projectDir()+TQString(TQChar(TQDir::separator())) + *it+".h"; + if( TQFileInfo(header).exists() ) + res.insert( TQDir::cleanDirPath( header ) ); + header = projectDir()+TQString(TQChar(TQDir::separator())) + *it+".cpp"; + if( TQFileInfo(header).exists() ) + res.insert( TQDir::cleanDirPath( header ) ); } } diff --git a/buildtools/qmake/scope.h b/buildtools/qmake/scope.h index 5be259bd..f50d4d99 100644 --- a/buildtools/qmake/scope.h +++ b/buildtools/qmake/scope.h @@ -125,9 +125,6 @@ public: /* deletes the subproject (including the subdir if deleteSubdir is true) */ bool deleteSubProject( unsigned int, bool deleteSubdir ); - /* find out wether the project is TQt4 or TQt3 */ - bool isTQt4Project() const ; - /* Provide a Map of Custom variables */ const TQMap<unsigned int, TQMap<TQString, TQString> > customVariables() const; diff --git a/buildtools/qmake/trollprojectpart.cpp b/buildtools/qmake/trollprojectpart.cpp index 82bb7416..49e228ad 100644 --- a/buildtools/qmake/trollprojectpart.cpp +++ b/buildtools/qmake/trollprojectpart.cpp @@ -255,7 +255,7 @@ TQString TrollProjectPart::makeEnvironment() environstr += " "; } - if( !hasTQtDir && !isTQt4Project() && !DomUtil::readEntry(*projectDom(), "/kdevcppsupport/qt/root", "").isEmpty() ) + if( !hasTQtDir && !DomUtil::readEntry(*projectDom(), "/kdevcppsupport/qt/root", "").isEmpty() ) { environstr += TQString( "TQTDIR=" ) + EnvVarTools::quote( DomUtil::readEntry(*projectDom(), "/kdevcppsupport/qt/root", "") ) + TQString( " PATH=$TQTDIR/bin:$PATH " ); } @@ -291,7 +291,7 @@ void TrollProjectPart::openProject(const TQString &dirName, const TQString &proj mainWindow()->statusBar()->message( i18n("Loading Project...") ); TQString defaultTQtDir = DomUtil::readEntry(*projectDom(), "/kdevcppsupport/qt/root", ""); - if( !isTQt4Project() && ( defaultTQtDir.isEmpty() || !isValidTQtDir( defaultTQtDir ) ) ) + if( defaultTQtDir.isEmpty() || !isValidTQtDir( defaultTQtDir ) ) { bool doask = true; while( doask ) @@ -705,11 +705,6 @@ void TrollProjectPart::startTQMakeCommand(const TQString &dir, bool recursive) cmdline = DomUtil::readEntry(*projectDom(), "/kdevcppsupport/qt/qmake", "")+" "; } - if(isTQt4Project() && recursive) - { - cmdline += " -recursive "; - } - //TQString cmdline = TQString::fromLatin1( isTMakeProject() ? "tmake " : "qmake " ); // cmdline += fi.baseName() + ".pro"; TQDir d(dir); @@ -798,18 +793,15 @@ bool TrollProjectPart::isValidTQtDir( const TQString& path ) const TQFileInfo inc( path + TQString( TQChar( TQDir::separator() ) )+ "include"+TQString( TQChar( TQDir::separator() ) )+ "tqt.h" ); - return ( isTQt4Project() || ( !isTQt4Project() && inc.exists() ) ); + return ( inc.exists() ); } void TrollProjectPart::buildBinDirs( TQStringList & dirs ) const { - if( !isTQt4Project() ) - { - TQString m_defaultTQtDir = DomUtil::readEntry(*projectDom(), "/kdevcppsupport/qt/root", ""); - if( !m_defaultTQtDir.isEmpty() ) - dirs << (m_defaultTQtDir + TQString( TQChar( TQDir::separator() ) ) + "bin" ); - dirs << ( ::getenv("TQTDIR") + TQString( TQChar( TQDir::separator() ) ) + "bin" ); - } + TQString m_defaultTQtDir = DomUtil::readEntry(*projectDom(), "/kdevcppsupport/qt/root", ""); + if( !m_defaultTQtDir.isEmpty() ) + dirs << (m_defaultTQtDir + TQString( TQChar( TQDir::separator() ) ) + "bin" ); + dirs << ( ::getenv("TQTDIR") + TQString( TQChar( TQDir::separator() ) ) + "bin" ); TQStringList paths = TQStringList::split(":",::getenv("PATH")); dirs += paths; TQString binpath = TQDir::rootDirPath() + "bin"; @@ -850,8 +842,7 @@ bool TrollProjectPart::isExecutable( const TQString& path ) const TQString TrollProjectPart::findTQtDir() { TQStringList qtdirs; - if( !isTQt4Project() ) - qtdirs.push_back( ::getenv("TQTDIR") ); + qtdirs.push_back( ::getenv("TQTDIR") ); qtdirs.push_back( TQDir::rootDirPath()+"usr"+TQString( TQChar( TQDir::separator() ) )+"lib"+TQString( TQChar( TQDir::separator() ) )+"qt"+TQString("%1").arg( DomUtil::readEntry( *projectDom(), "/kdevcppsupport/qt/version", "3") ) ); qtdirs.push_back( TQDir::rootDirPath()+"usr"+TQString( TQChar( TQDir::separator() ) )+"lib"+TQString( TQChar( TQDir::separator() ) )+"qt"+TQString( TQChar( TQDir::separator() ) )+TQString("%1").arg( DomUtil::readEntry( *projectDom(), "/kdevcppsupport/qt/version", "3") ) ); qtdirs.push_back( TQDir::rootDirPath()+"usr"+TQString( TQChar( TQDir::separator() ) )+"share"+TQString( TQChar( TQDir::separator() ) )+"qt"+TQString("%1").arg( DomUtil::readEntry( *projectDom(), "/kdevcppsupport/qt/version", "3") ) ); @@ -909,11 +900,6 @@ TQStringList TrollProjectPart::distFiles() const return sourceList + files; } -bool TrollProjectPart::isTQt4Project() const -{ - return ( DomUtil::readIntEntry( *projectDom(), "kdevcppsupport/qt/version", 3 ) == 4 ); -} - KDirWatch* TrollProjectPart::dirWatch() { return m_dirWatch; diff --git a/buildtools/qmake/trollprojectpart.h b/buildtools/qmake/trollprojectpart.h index e36ef202..ac323cb4 100644 --- a/buildtools/qmake/trollprojectpart.h +++ b/buildtools/qmake/trollprojectpart.h @@ -38,7 +38,6 @@ public: ~TrollProjectPart(); bool isTMakeProject() const { return m_tmakeProject; } - bool isTQt4Project() const; bool isDirty(); KDirWatch* dirWatch(); virtual Options options() const; diff --git a/buildtools/qmake/trollprojectwidget.cpp b/buildtools/qmake/trollprojectwidget.cpp index 3c35cb94..ca369c1f 100644 --- a/buildtools/qmake/trollprojectwidget.cpp +++ b/buildtools/qmake/trollprojectwidget.cpp @@ -1416,10 +1416,7 @@ void TrollProjectWidget::slotNewFile() fcext = "h"; break; case GroupItem::Forms: - if ( !m_part->isTQt4Project() ) - fcext = "ui-widget"; - else - fcext = "ui-widget-qt4"; + fcext = "ui-widget"; break; case GroupItem::Translations: fcext = "ts"; @@ -1694,10 +1691,7 @@ void TrollProjectWidget::slotDetailsContextMenu( TDEListView *, TQListViewItem * fcext = "h"; break; case GroupItem::Forms: - if ( !m_part->isTQt4Project() ) - fcext = "ui-widget"; - else - fcext = "ui-widget-qt4"; + fcext = "ui-widget"; break; case GroupItem::Translations: fcext = "ts"; @@ -1782,11 +1776,8 @@ void TrollProjectWidget::slotDetailsContextMenu( TDEListView *, TQListViewItem * popup.setWhatsThis( idSubclassWidget, i18n( "<b>Subclass widget</b><p>Launches <b>Subclassing</b> wizard. " "It allows to create a subclass from the class defined in .ui file. " "There is also possibility to implement slots and functions defined in the base class." ) ); - if ( !m_part->isTQt4Project() ) - { - idViewUIH = popup.insertItem( SmallIconSet( "qmake_ui_h" ), i18n( "Open ui.h File" ) ); - popup.setWhatsThis( idViewUIH, i18n( "<b>Open ui.h file</b><p>Opens .ui.h file associated with the selected .ui." ) ); - } + idViewUIH = popup.insertItem( SmallIconSet( "qmake_ui_h" ), i18n( "Open ui.h File" ) ); + popup.setWhatsThis( idViewUIH, i18n( "<b>Open ui.h file</b><p>Opens .ui.h file associated with the selected .ui." ) ); idUISubclasses = popup.insertItem( SmallIconSet( "qmake_subclass" ), i18n( "List of Subclasses..." ) ); popup.setWhatsThis( idUISubclasses, i18n( "<b>List of subclasses</b><p>Shows subclasses list editor. " "There is possibility to add or remove subclasses from the list." ) ); @@ -2340,21 +2331,15 @@ void TrollProjectWidget::setLastFocusedView( TrollProjectView view ) void TrollProjectWidget::runTQMakeRecursive( QMakeScopeItem* proj ) { - if( m_part->isTQt4Project() ) + if ( proj->scope->scopeType() == Scope::ProjectScope ) { - m_part->startTQMakeCommand( proj->scope->projectDir(), true ); - }else + m_part->startTQMakeCommand( proj->scope->projectDir() ); + } + QMakeScopeItem* item = static_cast<QMakeScopeItem*>( proj->firstChild() ); + while ( item ) { - if ( proj->scope->scopeType() == Scope::ProjectScope ) - { - m_part->startTQMakeCommand( proj->scope->projectDir() ); - } - QMakeScopeItem* item = static_cast<QMakeScopeItem*>( proj->firstChild() ); - while ( item ) - { - runTQMakeRecursive( item ); - item = static_cast<QMakeScopeItem*>( item->nextSibling() ); - } + runTQMakeRecursive( item ); + item = static_cast<QMakeScopeItem*>( item->nextSibling() ); } } @@ -2533,7 +2518,7 @@ TQMap<TQString,TQString> TrollProjectWidget::qmakeEnvironment() const map[(*it).first] = (*it).second; } - if( !hasTQtDir && !m_part->isTQt4Project() && !DomUtil::readEntry(*m_part->projectDom(), "/kdevcppsupport/qt/root", "").isEmpty() ) + if( !hasTQtDir && !DomUtil::readEntry(*m_part->projectDom(), "/kdevcppsupport/qt/root", "").isEmpty() ) { map["TQTDIR="] = DomUtil::readEntry(*m_part->projectDom(), "/kdevcppsupport/qt/root", ""); map["PATH"] = map["PATH"].prepend( DomUtil::readEntry(*m_part->projectDom(), "/kdevcppsupport/qt/root", "") +"/bin" ); |