summaryrefslogtreecommitdiffstats
path: root/languages/cpp/qtdesignercppintegration.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'languages/cpp/qtdesignercppintegration.cpp')
-rw-r--r--languages/cpp/qtdesignercppintegration.cpp50
1 files changed, 25 insertions, 25 deletions
diff --git a/languages/cpp/qtdesignercppintegration.cpp b/languages/cpp/qtdesignercppintegration.cpp
index 420cf38e..9314aceb 100644
--- a/languages/cpp/qtdesignercppintegration.cpp
+++ b/languages/cpp/qtdesignercppintegration.cpp
@@ -20,8 +20,8 @@
***************************************************************************/
#include "qtdesignercppintegration.h"
-#include <qpair.h>
-#include <qregexp.h>
+#include <tqpair.h>
+#include <tqregexp.h>
#include <klocale.h>
#include <kdebug.h>
@@ -52,7 +52,7 @@ void QtDesignerCppIntegration::addFunctionToClass( KInterfaceDesigner::Function
if ( !editIface )
{
/// @todo show messagebox
- // QDialog::accept();
+ // TQDialog::accept();
return ;
}
@@ -60,14 +60,14 @@ void QtDesignerCppIntegration::addFunctionToClass( KInterfaceDesigner::Function
klass->getEndPosition( &line, &column );
// compute the insertion point map
- QMap<QString, QPair<int, int> > points;
+ TQMap<TQString, QPair<int, int> > points;
const FunctionList functionList = klass->functionList();
for ( FunctionList::ConstIterator it = functionList.begin(); it != functionList.end(); ++it )
{
int funEndLine, funEndColumn;
( *it ) ->getEndPosition( &funEndLine, &funEndColumn );
- QString access = accessID( *it );
+ TQString access = accessID( *it );
QPair<int, int> funEndPoint = qMakePair( funEndLine, funEndColumn );
if ( !points.contains( access ) || points[ access ] < funEndPoint )
@@ -78,9 +78,9 @@ void QtDesignerCppIntegration::addFunctionToClass( KInterfaceDesigner::Function
int insertedLine = 0;
- QString access = function.access + ( function.type == KInterfaceDesigner::ftQtSlot ? " slots" : "" );
+ TQString access = function.access + ( function.type == KInterfaceDesigner::ftQtSlot ? " slots" : "" );
- QString str = function.returnType + " " + function.function;
+ TQString str = function.returnType + " " + function.function;
if ( function.specifier == "virtual" )
str = "virtual " + str;
else if ( function.specifier == "pure virtual" )
@@ -103,7 +103,7 @@ void QtDesignerCppIntegration::addFunctionToClass( KInterfaceDesigner::Function
}
editIface->insertText( pt.first + insertedLine + 1, 0 /*pt.second*/, str );
- insertedLine += str.contains( QChar( '\n' ) );
+ insertedLine += str.contains( TQChar( '\n' ) );
CppSupportPart *cppPart = dynamic_cast<CppSupportPart *>( m_part );
cppPart->backgroundParser() ->addFile( klass->fileName() );
@@ -113,18 +113,18 @@ void QtDesignerCppIntegration::addFunctionToClass( KInterfaceDesigner::Function
//implementation
- QString stri = function.returnType + " " + klass->name() + "::" + function.function;
+ TQString stri = function.returnType + " " + klass->name() + "::" + function.function;
if ( function.specifier == "static" )
stri = "static " + stri;
stri += "\n{\n}\n";
stri = "\n" + stri;
- QFileInfo fi( klass->fileName() );
- QString implementationFile = fi.absFilePath();
+ TQFileInfo fi( klass->fileName() );
+ TQString implementationFile = fi.absFilePath();
implementationFile.replace( ".h", ".cpp" );
- QFileInfo fileInfo( implementationFile );
- if ( !QFile::exists( fileInfo.absFilePath() ) )
+ TQFileInfo fileInfo( implementationFile );
+ if ( !TQFile::exists( fileInfo.absFilePath() ) )
{
if ( KDevCreateFile * createFileSupp = m_part->extension<KDevCreateFile>( "KDevelop/CreateFile" ) )
createFileSupp->createNewFile( fileInfo.extension(), fileInfo.dirPath( true ), fileInfo.fileName() );
@@ -158,7 +158,7 @@ void QtDesignerCppIntegration::addFunctionToClass( KInterfaceDesigner::Function
}
else
{
- if ( editIface->textLine( line ).contains( QRegExp( ".*#include .*\\.moc.*" ) ) )
+ if ( editIface->textLine( line ).contains( TQRegExp( ".*#include .*\\.moc.*" ) ) )
atLine = line;
break;
}
@@ -167,7 +167,7 @@ void QtDesignerCppIntegration::addFunctionToClass( KInterfaceDesigner::Function
atColumn = 0;
}
- // editIface->insertLine( atLine + 1, QString::fromLatin1("") );
+ // editIface->insertLine( atLine + 1, TQString::fromLatin1("") );
kdDebug() << "at line in intg: " << atLine << " atCol: " << atColumn << endl;
kdDebug() << "text: " << stri << endl;
editIface->insertText( atLine, atColumn, stri );
@@ -182,33 +182,33 @@ void QtDesignerCppIntegration::addFunctionToClass( KInterfaceDesigner::Function
cppPart->backgroundParser() ->addFile( implementationFile );
}
-QString QtDesignerCppIntegration::accessID( FunctionDom fun ) const
+TQString QtDesignerCppIntegration::accessID( FunctionDom fun ) const
{
if ( fun->isSignal() )
- return QString::fromLatin1( "signals" );
+ return TQString::fromLatin1( "signals" );
switch ( fun->access() )
{
case CodeModelItem::Public:
if ( fun->isSlot() )
- return QString::fromLatin1( "public slots" );
- return QString::fromLatin1( "public" );
+ return TQString::fromLatin1( "public slots" );
+ return TQString::fromLatin1( "public" );
case CodeModelItem::Protected:
if ( fun->isSlot() )
- return QString::fromLatin1( "protected slots" );
- return QString::fromLatin1( "protected" );
+ return TQString::fromLatin1( "protected slots" );
+ return TQString::fromLatin1( "protected" );
case CodeModelItem::Private:
if ( fun->isSlot() )
- return QString::fromLatin1( "private slots" );
- return QString::fromLatin1( "private" );
+ return TQString::fromLatin1( "private slots" );
+ return TQString::fromLatin1( "private" );
}
- return QString::null;
+ return TQString::null;
}
-void QtDesignerCppIntegration::processImplementationName( QString &name )
+void QtDesignerCppIntegration::processImplementationName( TQString &name )
{
name.replace( ".h", ".cpp" );
}