diff options
Diffstat (limited to 'kdevdesigner/designer/mainwindow.cpp')
-rw-r--r-- | kdevdesigner/designer/mainwindow.cpp | 56 |
1 files changed, 28 insertions, 28 deletions
diff --git a/kdevdesigner/designer/mainwindow.cpp b/kdevdesigner/designer/mainwindow.cpp index 87e15a74..8ad20987 100644 --- a/kdevdesigner/designer/mainwindow.cpp +++ b/kdevdesigner/designer/mainwindow.cpp @@ -142,7 +142,7 @@ static TQString textNoAccel( const TQString& text) { TQString t = text; int i; - while ( (i = t.tqfind('&') )>= 0 ) { + while ( (i = t.find('&') )>= 0 ) { t.remove(i,1); } return t; @@ -753,10 +753,10 @@ void MainWindow::helpContents() TQTextStream ts( &f ); while ( !ts.eof() ) { TQString s = ts.readLine(); - int from = s.tqfind( "\"" ); + int from = s.find( "\"" ); if ( from == -1 ) continue; - int to = s.tqfindRev( "\"" ); + int to = s.findRev( "\"" ); if ( to == -1 ) continue; propertyDocumentation[ s.mid( from + 1, to - from - 1 ) ] = s.mid( to + 2 ) + "-prop"; @@ -782,7 +782,7 @@ void MainWindow::helpContents() else source = propertyDocumentation[ "TQObject/name" ]; } else { - while ( mo && !propertyDocumentation.tqcontains( ( s = TQString( mo->className() ) + "/" + cp ) ) ) + while ( mo && !propertyDocumentation.contains( ( s = TQString( mo->className() ) + "/" + cp ) ) ) mo = mo->tqsuperClass(); if ( mo ) source = "p:" + propertyDocumentation[s]; @@ -945,7 +945,7 @@ bool MainWindow::eventFilter( TQObject *o, TQEvent *e ) } else if ( e->type() == TQEvent::MouseButtonPress && ::tqqt_cast<PopupMenuEditor*>(o) ) { PopupMenuEditor *m = ::tqqt_cast<PopupMenuEditor*>(o); PopupMenuEditorItem *i = m->at( ((TQMouseEvent*)e)->pos() ); - if ( m->tqfind( i->action() ) != -1 && !i->isSeparator() ) + if ( m->find( i->action() ) != -1 && !i->isSeparator() ) showProperties( i->action() ); } return TQMainWindow::eventFilter( o, e ); @@ -1262,7 +1262,7 @@ FormWindow *MainWindow::formWindow() if ( ::tqqt_cast<FormWindow*>(qworkspace->activeWindow()) ) fw = (FormWindow*)qworkspace->activeWindow(); else if ( lastActiveFormWindow && - qworkspace->windowList().tqfind( lastActiveFormWindow ) != -1) + qworkspace->windowList().find( lastActiveFormWindow ) != -1) fw = lastActiveFormWindow; return fw; } @@ -1554,18 +1554,18 @@ void MainWindow::popupWidgetMenu( const TQPoint &gp, FormWindow * /*fw*/, TQWidg void MainWindow::setupRMBProperties( TQValueList<uint> &ids, TQMap<TQString, int> &props, TQWidget *w ) { - const TQMetaProperty* text = w->tqmetaObject()->property( w->tqmetaObject()->tqfindProperty( "text", TRUE ), TRUE ); + const TQMetaProperty* text = w->tqmetaObject()->property( w->tqmetaObject()->findProperty( "text", TRUE ), TRUE ); if ( text && qstrcmp( text->type(), TQSTRING_OBJECT_NAME_STRING) != 0 ) text = 0; - const TQMetaProperty* title = w->tqmetaObject()->property( w->tqmetaObject()->tqfindProperty( "title", TRUE ), TRUE ); + const TQMetaProperty* title = w->tqmetaObject()->property( w->tqmetaObject()->findProperty( "title", TRUE ), TRUE ); if ( title && qstrcmp( title->type(), TQSTRING_OBJECT_NAME_STRING) != 0 ) title = 0; const TQMetaProperty* pagetitle = - w->tqmetaObject()->property( w->tqmetaObject()->tqfindProperty( "pageTitle", TRUE ), TRUE ); + w->tqmetaObject()->property( w->tqmetaObject()->findProperty( "pageTitle", TRUE ), TRUE ); if ( pagetitle && qstrcmp( pagetitle->type(), TQSTRING_OBJECT_NAME_STRING) != 0 ) pagetitle = 0; const TQMetaProperty* pixmap = - w->tqmetaObject()->property( w->tqmetaObject()->tqfindProperty( "pixmap", TRUE ), TRUE ); + w->tqmetaObject()->property( w->tqmetaObject()->findProperty( "pixmap", TRUE ), TRUE ); if ( pixmap && qstrcmp( pixmap->type(), TQPIXMAP_OBJECT_NAME_STRING) != 0 ) pixmap = 0; @@ -2132,7 +2132,7 @@ void MainWindow::selectionChanged() static TQString fixArgs( const TQString &s2 ) { TQString s = s2; - return s.tqreplace( ',', ';' ); + return s.replace( ',', ';' ); } void MainWindow::writeConfig() @@ -2242,7 +2242,7 @@ void MainWindow::writeConfig() static TQString fixArgs2( const TQString &s2 ) { TQString s = s2; - return s.tqreplace( ';', ',' ); + return s.replace( ';', ',' ); } void MainWindow::readConfig() @@ -2290,14 +2290,14 @@ void MainWindow::readConfig() } // We know that the oldSettingsKey() will return 3.1 if ( keybase == DesignerApplication::oldSettingsKey() ) { - if (keybase.tqcontains("3.1")) + if (keybase.contains("3.1")) recentlyFiles = config.readListEntry( keybase + "RecentlyOpenedFiles", ',' ); else recentlyFiles = config.readListEntry(keybase + "RecentlyOpenedFiles"); if ( recentlyFiles.count() == 1 && recentlyFiles[0].isNull() ) recentlyFiles.clear(); - if (keybase.tqcontains("3.1")) + if (keybase.contains("3.1")) recentlyProjects = config.readListEntry( keybase + "RecentlyOpenedProjects", ',' ); else recentlyProjects = config.readListEntry( keybase + "RecentlyOpenedProjects"); @@ -2574,7 +2574,7 @@ bool MainWindow::openEditor( TQWidget *w, FormWindow *f ) TQString fullSignal; for ( int i = 0; i < (int)sigs.count(); ++i ) { TQString sig = sigs.at( i ); - if ( sig.left( sig.tqfind( '(' ) ) == defSignal ) { + if ( sig.left( sig.find( '(' ) ) == defSignal ) { fullSignal = sig; break; } @@ -2582,14 +2582,14 @@ bool MainWindow::openEditor( TQWidget *w, FormWindow *f ) if ( !fullSignal.isEmpty() ) { TQString signl = fullSignal; - fullSignal = fullSignal.mid( fullSignal.tqfind( '(' ) + 1 ); + fullSignal = fullSignal.mid( fullSignal.find( '(' ) + 1 ); fullSignal.remove( (int)fullSignal.length() - 1, 1 ); fullSignal = iface->createArguments( fullSignal.simplifyWhiteSpace() ); s += "(" + fullSignal + ")"; if ( !MetaDataBase::hasFunction( TQT_TQOBJECT(f), s.latin1() ) ) MetaDataBase::addFunction( TQT_TQOBJECT(f), s.latin1(), "", "public", "slot", f->project()->language(), "void" ); - s = s.left( s.tqfind( '(' ) ).latin1(); + s = s.left( s.find( '(' ) ).latin1(); if ( !MetaDataBase::hasConnection( TQT_TQOBJECT(f), TQT_TQOBJECT(w), defSignal.latin1(), TQT_TQOBJECT(f->mainContainer()), s.latin1() ) ) { MetaDataBase::Connection conn; conn.sender = TQT_TQOBJECT(w); @@ -2617,8 +2617,8 @@ bool MainWindow::openEditor( TQWidget *w, FormWindow *f ) return TRUE; } - const TQMetaProperty* text = w->tqmetaObject()->property( w->tqmetaObject()->tqfindProperty( "text", TRUE ), TRUE ); - const TQMetaProperty* title = w->tqmetaObject()->property( w->tqmetaObject()->tqfindProperty( "title", TRUE ), TRUE ); + const TQMetaProperty* text = w->tqmetaObject()->property( w->tqmetaObject()->findProperty( "text", TRUE ), TRUE ); + const TQMetaProperty* title = w->tqmetaObject()->property( w->tqmetaObject()->findProperty( "title", TRUE ), TRUE ); if ( text && text->designable(w) ) { bool ok = FALSE; bool oldDoWrap = FALSE; @@ -2804,7 +2804,7 @@ void MainWindow::projectSelected( TQAction *a ) a->setOn( TRUE ); if ( currentProject ) currentProject->setActive( FALSE ); - Project *p = *projects.tqfind( a ); + Project *p = *projects.find( a ); p->setActive( TRUE ); if ( currentProject == p ) return; @@ -2881,9 +2881,9 @@ void MainWindow::showDialogHelp() else if ( ::tqqt_cast<ProjectSettingsBase*>(w) ) link += "dialog-project-settings"; else if ( ::tqqt_cast<FindDialog*>(w) ) - link += "dialog-tqfind-text"; + link += "dialog-find-text"; else if ( ::tqqt_cast<ReplaceDialog*>(w) ) - link += "dialog-tqreplace-text"; + link += "dialog-replace-text"; else if ( ::tqqt_cast<GotoLineDialog*>(w) ) link += "dialog-go-to-line"; // else if ( ::tqqt_cast<ConnectionEditorBase*>(w) ) @@ -3099,7 +3099,7 @@ void MainWindow::addRecentlyOpened( const TQString &fn, TQStringList &lst ) TQFileInfo fi( fn ); fi.convertToAbs(); TQString f = fi.filePath(); - if ( lst.tqfind( f ) != lst.end() ) + if ( lst.find( f ) != lst.end() ) lst.remove( f ); if ( lst.count() >= 10 ) lst.pop_back(); @@ -3210,7 +3210,7 @@ void MainWindow::setModified( bool b, TQWidget *window ) void MainWindow::editorClosed( SourceEditor *e ) { - sourceEditors.take( sourceEditors.tqfindRef( e ) ); + sourceEditors.take( sourceEditors.findRef( e ) ); } void MainWindow::functionsChanged() @@ -3422,7 +3422,7 @@ void MainWindow::showSourceLine( TQObject *o, int line, LineMode lm ) mblockNewForms = TRUE; if ( !fw ) - openFormWindow( currentProject->makeAbsolute( *qwf_forms->tqfind( (TQWidget*)o ) ) ); + openFormWindow( currentProject->makeAbsolute( *qwf_forms->find( (TQWidget*)o ) ) ); else fw->formFile()->showEditor( FALSE ); tqApp->processEvents(); // give all views the chance to get the formwindow @@ -3620,13 +3620,13 @@ TQString MainWindow::whatsThisFrom( const TQString &key ) } } - int i = menuHelpFile.tqfind( key ); + int i = menuHelpFile.find( key ); if ( i == -1 ) return TQString(); int start = i; int end = i; - start = menuHelpFile.tqfindRev( "<li>", i ) + 4; - end = menuHelpFile.tqfind( '\n', i ) - 1; + start = menuHelpFile.findRev( "<li>", i ) + 4; + end = menuHelpFile.find( '\n', i ) - 1; return menuHelpFile.mid( start, end - start + 1 ); } |