diff options
Diffstat (limited to 'kstars/kstars/opscolors.cpp')
-rw-r--r-- | kstars/kstars/opscolors.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/kstars/kstars/opscolors.cpp b/kstars/kstars/opscolors.cpp index 8746dd00..73f6ca59 100644 --- a/kstars/kstars/opscolors.cpp +++ b/kstars/kstars/opscolors.cpp @@ -62,8 +62,8 @@ OpsColors::OpsColors( TQWidget *p, const char *name, WFlags fl ) while ( !stream.eof() ) { line = stream.readLine(); - schemeName = line.left( line.find( ':' ) ); - filename = line.mid( line.find( ':' ) +1, line.length() ); + schemeName = line.left( line.tqfind( ':' ) ); + filename = line.mid( line.tqfind( ':' ) +1, line.length() ); PresetBox->insertItem( schemeName ); PresetFileList.append( filename ); } @@ -123,7 +123,7 @@ void OpsColors::slotPreset( int index ) { TQStringList::Iterator it = PresetFileList.at( index ); bool result = setColors( *it ); if (!result) { - TQString message = i18n( "The specified color scheme file (%1) could not be found, or was corrupt." ).arg( TQString(*it) ); + TQString message = i18n( "The specified color scheme file (%1) could not be found, or was corrupt." ).tqarg( TQString(*it) ); KMessageBox::sorry( 0, message, i18n( "Could Not Set Color Scheme" ) ); } } @@ -161,15 +161,15 @@ void OpsColors::slotAddPreset() { bool okPressed = false; TQString schemename = KInputDialog::getText( i18n( "New Color Scheme" ), i18n( "Enter a name for the new color scheme:" ), - TQString::null, &okPressed, 0 ); + TQString(), &okPressed, 0 ); if ( okPressed && ! schemename.isEmpty() ) { if ( ksw->data()->colorScheme()->save( schemename ) ) { PresetBox->insertItem( schemename ); - PresetBox->setCurrentItem( PresetBox->findItem( schemename ) ); + PresetBox->setCurrentItem( PresetBox->tqfindItem( schemename ) ); TQString fname = ksw->data()->colorScheme()->fileName(); PresetFileList.append( fname ); - ksw->addColorMenuItem( schemename, TQString("cs_" + fname.left(fname.find(".colors"))).utf8() ); + ksw->addColorMenuItem( schemename, TQString("cs_" + fname.left(fname.tqfind(".colors"))).utf8() ); } } } @@ -181,7 +181,7 @@ void OpsColors::slotRemovePreset() { cdatFile.setName( locateLocal( "appdata", "colors.dat" ) ); //determine filename in local user KDE directory tree. //Remove action from color-schemes menu - ksw->removeColorMenuItem( TQString("cs_" + filename.left( filename.find(".colors"))).utf8() ); + ksw->removeColorMenuItem( TQString("cs_" + filename.left( filename.tqfind(".colors"))).utf8() ); if ( !cdatFile.exists() || !cdatFile.open( IO_ReadWrite ) ) { TQString message = i18n( "Local color scheme index file could not be opened.\nScheme cannot be removed." ); @@ -205,7 +205,7 @@ void OpsColors::slotRemovePreset() { while ( !stream.eof() ) { TQString line = stream.readLine(); - if ( line.left( line.find(':') ) != name ) slist.append( line ); + if ( line.left( line.tqfind(':') ) != name ) slist.append( line ); else removed = true; } @@ -213,7 +213,7 @@ void OpsColors::slotRemovePreset() { TQFile colorFile; colorFile.setName( locateLocal( "appdata", filename ) ); //determine filename in local user KDE directory tree. if ( !colorFile.remove() ) { - TQString message = i18n( "Could not delete the file: %1" ).arg( colorFile.name() ); + TQString message = i18n( "Could not delete the file: %1" ).tqarg( colorFile.name() ); KMessageBox::sorry( 0, message, i18n( "Error Deleting File" ) ); } @@ -224,7 +224,7 @@ void OpsColors::slotRemovePreset() { for( unsigned int i=0; i<slist.count(); ++i ) stream << slist[i] << endl; } else { - TQString message = i18n( "Could not find an entry named %1 in colors.dat." ).arg( name ); + TQString message = i18n( "Could not find an entry named %1 in colors.dat." ).tqarg( name ); KMessageBox::sorry( 0, message, i18n( "Scheme Not Found" ) ); } cdatFile.close(); |