diff options
Diffstat (limited to 'kdat')
-rw-r--r-- | kdat/Archive.cpp | 8 | ||||
-rw-r--r-- | kdat/Archive.h | 14 | ||||
-rw-r--r-- | kdat/BackupDlg.cpp | 2 | ||||
-rw-r--r-- | kdat/File.cpp | 16 | ||||
-rw-r--r-- | kdat/File.h | 18 | ||||
-rw-r--r-- | kdat/IndexDlg.cpp | 6 | ||||
-rw-r--r-- | kdat/InfoShellWidget.h | 2 | ||||
-rw-r--r-- | kdat/KDat.kdoc | 4 | ||||
-rw-r--r-- | kdat/KDatMainWindow.cpp | 42 | ||||
-rw-r--r-- | kdat/Node.cpp | 30 | ||||
-rw-r--r-- | kdat/Node.h | 16 | ||||
-rw-r--r-- | kdat/Tape.cpp | 44 | ||||
-rw-r--r-- | kdat/Tape.h | 4 | ||||
-rw-r--r-- | kdat/TapeInfoWidget.cpp | 6 | ||||
-rw-r--r-- | kdat/VerifyDlg.cpp | 2 | ||||
-rw-r--r-- | kdat/ktreeview.cpp | 76 | ||||
-rw-r--r-- | kdat/ktreeview.h | 26 |
17 files changed, 158 insertions, 158 deletions
diff --git a/kdat/Archive.cpp b/kdat/Archive.cpp index ad66dbd..5e8ef65 100644 --- a/kdat/Archive.cpp +++ b/kdat/Archive.cpp @@ -94,7 +94,7 @@ void Archive::read( int version ) } } - // Number of immediate tqchildren (4 bytes). + // Number of immediate children (4 bytes). fread( &ival, sizeof( ival ), 1, _fptr ); //===== Read files ===== @@ -148,7 +148,7 @@ void Archive::write( FILE* fptr ) fwrite( &ival, sizeof( ival ), 1, _fptr ); } - // Number of immediate tqchildren (4 bytes). + // Number of immediate children (4 bytes). ival = getChildren().count(); fwrite( &ival, sizeof( ival ), 1, _fptr ); @@ -202,7 +202,7 @@ const TQPtrList<File>& Archive::getChildren() { read(); - return _tqchildren; + return _children; } const TQPtrList<Range>& Archive::getRanges() @@ -255,7 +255,7 @@ void Archive::addChild( File* file ) { read(); - _tqchildren.append( file ); + _children.append( file ); } File* Archive::addFile( int size, int mtime, int startRecord, int endRecord, const TQString & filename ) diff --git a/kdat/Archive.h b/kdat/Archive.h index 7527073..9f42684 100644 --- a/kdat/Archive.h +++ b/kdat/Archive.h @@ -39,7 +39,7 @@ class Archive { FILE* _fptr; int _offset; TQString _name; - TQPtrList<File> _tqchildren; + TQPtrList<File> _children; RangeList _ranges; Tape* _tape; public: @@ -67,7 +67,7 @@ public: Archive( Tape* tape, FILE* fptr, int offset ); /** - * Destroy the archive entry and all of its tqchildren. + * Destroy the archive entry and all of its children. */ ~Archive(); @@ -82,7 +82,7 @@ public: /** * Recursively read the instance data for this archive entry and all of its - * tqchildren. This method is used when converting from an older index format. + * children. This method is used when converting from an older index format. * * @param version The version of the old tape index. */ @@ -90,7 +90,7 @@ public: /** * Write out the archive entry to the open file. Entries for each of its - * tqchildren will also be written. + * children will also be written. */ void write( FILE* fptr ); @@ -125,12 +125,12 @@ public: /** * Get the list of top-level files in this archive. * - * @return A list of the immediate tqchildren of this archive. + * @return A list of the immediate children of this archive. */ const TQPtrList<File>& getChildren(); /** - * Get the list of ranges of this file and all of its tqchildren. + * Get the list of ranges of this file and all of its children. * * @return A list of ranges. */ @@ -176,7 +176,7 @@ public: File* addFile( int size, int mtime, int startRecord, int endRecord, const TQString & filename ); /** - * Recursively calculate the list of ranges for all of the archive's tqchildren. + * Recursively calculate the list of ranges for all of the archive's children. */ void calcRanges(); }; diff --git a/kdat/BackupDlg.cpp b/kdat/BackupDlg.cpp index bd47226..e32f680 100644 --- a/kdat/BackupDlg.cpp +++ b/kdat/BackupDlg.cpp @@ -426,7 +426,7 @@ void BackupDlg::updateStats() _kbytesWritten->setText( str ); if ( elapsed > 0 ) { - str = i18n( "%1/min" ).tqarg(Util::kbytesToString( (int)_totalKBytes *60 / elapsed ) ); + str = i18n( "%1/min" ).arg(Util::kbytesToString( (int)_totalKBytes *60 / elapsed ) ); _transferRate->setText( str ); } } diff --git a/kdat/File.cpp b/kdat/File.cpp index ce05aeb..fd766b3 100644 --- a/kdat/File.cpp +++ b/kdat/File.cpp @@ -44,9 +44,9 @@ File::File( File* parent, FILE* fptr, int offset ) File::~File() { - while ( _tqchildren.first() ) { - delete _tqchildren.first(); - _tqchildren.removeFirst(); + while ( _children.first() ) { + delete _children.first(); + _children.removeFirst(); } } @@ -164,7 +164,7 @@ void File::write( FILE* fptr ) fwrite( &ival, sizeof( ival ), 1, fptr ); } - // Number of immediate tqchildren (4 bytes). + // Number of immediate children (4 bytes). ival = getChildren().count(); fwrite( &ival, sizeof( ival ), 1, fptr ); @@ -175,10 +175,10 @@ void File::write( FILE* fptr ) } //===== Write files ===== - ival = _tqchildren.count(); + ival = _children.count(); fwrite( &ival, sizeof( ival ), 1, fptr ); - TQPtrListIterator<File> i( _tqchildren ); + TQPtrListIterator<File> i( _children ); int count = 0; for ( ; i.current(); ++i, count++ ) { // Fill in the file offset. @@ -252,7 +252,7 @@ const TQPtrList<File>& File::getChildren() { read(); - return _tqchildren; + return _children; } const TQPtrList<Range>& File::getRanges() @@ -266,7 +266,7 @@ void File::addChild( File* file ) { read(); - _tqchildren.append( file ); + _children.append( file ); } void File::calcRanges() diff --git a/kdat/File.h b/kdat/File.h index 71167f2..75b1d87 100644 --- a/kdat/File.h +++ b/kdat/File.h @@ -46,7 +46,7 @@ class File { } _union; TQString _name; File* _parent; - TQPtrList<File> _tqchildren; + TQPtrList<File> _children; RangeList _ranges; public: /** @@ -80,7 +80,7 @@ public: File( File* parent, FILE* fptr, int offset ); /** - * Destroy the file entry and all of its tqchildren. + * Destroy the file entry and all of its children. */ ~File(); @@ -95,7 +95,7 @@ public: /** * Recursively read the instance for this file entry and all of it's - * tqchildren. This method is used when converting from an older index format. + * children. This method is used when converting from an older index format. * * @param version The version of the old tape index. */ @@ -103,7 +103,7 @@ public: /** * Write out the file entry to the open file. Entries for each of its - * tqchildren will also be written. + * children will also be written. */ void write( FILE* fptr ); @@ -171,15 +171,15 @@ public: File* getParent(); /** - * Get the tqchildren of this file entry. A normal file will never have any - * tqchildren. A directory may or may not have tqchildren. + * Get the children of this file entry. A normal file will never have any + * children. A directory may or may not have children. * - * @return A list of the immediate tqchildren of this file entry. + * @return A list of the immediate children of this file entry. */ const TQPtrList<File>& getChildren(); /** - * Get the list of ranges of this file and all of its tqchildren. + * Get the list of ranges of this file and all of its children. * * @return A list of ranges. */ @@ -193,7 +193,7 @@ public: void addChild( File* file ); /** - * Recursively calculate the list of ranges for all of the file's tqchildren. + * Recursively calculate the list of ranges for all of the file's children. */ void calcRanges(); }; diff --git a/kdat/IndexDlg.cpp b/kdat/IndexDlg.cpp index 92621b6..1d19d0a 100644 --- a/kdat/IndexDlg.cpp +++ b/kdat/IndexDlg.cpp @@ -275,10 +275,10 @@ void IndexDlg::timerEvent( TQTimerEvent* ) _archiveCount++; msg.setNum( _archiveCount ); _archives->setText( msg ); - msg = i18n( "Indexing archive %1." ).tqarg( _archiveCount ); + msg = i18n( "Indexing archive %1." ).arg( _archiveCount ); _log->append( msg ); - msg = i18n( "Archive %1" ).tqarg( _archiveCount ); + msg = i18n( "Archive %1" ).arg( _archiveCount ); _archive = new Archive( _tape, 0, msg ); _fileName = TQString(); _fileSize = -1; @@ -349,7 +349,7 @@ void IndexDlg::updateStats() _kbytesRead->setText( str ); if ( elapsed > 0 ) { - str = i18n( "%1/min" ).tqarg(Util::kbytesToString( (int)_totalKBytes * 60 / elapsed ) ); + str = i18n( "%1/min" ).arg(Util::kbytesToString( (int)_totalKBytes * 60 / elapsed ) ); _transferRate->setText( str ); } } diff --git a/kdat/InfoShellWidget.h b/kdat/InfoShellWidget.h index 0f87585..62f2c5f 100644 --- a/kdat/InfoShellWidget.h +++ b/kdat/InfoShellWidget.h @@ -42,7 +42,7 @@ public: ~InfoShellWidget(); protected: /** - * Resize all tqchildren to fill all of the available space within the shell. + * Resize all children to fill all of the available space within the shell. */ virtual void resizeEvent( TQResizeEvent* e ); }; diff --git a/kdat/KDat.kdoc b/kdat/KDat.kdoc index 2bf6349..7297e64 100644 --- a/kdat/KDat.kdoc +++ b/kdat/KDat.kdoc @@ -12,7 +12,7 @@ Archive::startBlock=Archive.html#startBlock Archive::endBlock=Archive.html#endBlock Archive::name=Archive.html#name Archive::files=Archive.html#files -Archive::tqchildren=Archive.html#tqchildren +Archive::children=Archive.html#children Archive::setEndBlock=Archive.html#setEndBlock Archive::setName=Archive.html#setName Archive::addFile=Archive.html#addFile @@ -94,7 +94,7 @@ File::size=File.html#size File::mtime=File.html#mtime File::record=File.html#record File::name=File.html#name -File::tqchildren=File.html#tqchildren +File::children=File.html#children IndexDlg=IndexDlg.html IndexDlg=IndexDlg.html IndexDlg::_tarParser=IndexDlg.html#_tarParser diff --git a/kdat/KDatMainWindow.cpp b/kdat/KDatMainWindow.cpp index 9a7d776..110296b 100644 --- a/kdat/KDatMainWindow.cpp +++ b/kdat/KDatMainWindow.cpp @@ -152,7 +152,7 @@ KDatMainWindow::KDatMainWindow() _menu->insertItem( i18n( "&File" ), _fileMenu ); _menu->insertItem( i18n( "&Settings" ), _editMenu ); _menu->insertSeparator(); - TQString about = i18n( "KDat Version %1\n\nKDat is a tar-based tape archiver.\n\nCopyright (c) 1998-2000 Sean Vyain\nCopyright (c) 2001-2002 Lawrence Widman\nkdat@cardiothink.com" ).tqarg( KDAT_VERSION ); + TQString about = i18n( "KDat Version %1\n\nKDat is a tar-based tape archiver.\n\nCopyright (c) 1998-2000 Sean Vyain\nCopyright (c) 2001-2002 Lawrence Widman\nkdat@cardiothink.com" ).arg( KDAT_VERSION ); _menu->insertItem( i18n( "&Help" ), helpMenu( about ) ); _toolbar = new KToolBar( this ); @@ -387,7 +387,7 @@ void KDatMainWindow::localSelected( int index ) _tree->expandItem( index ); _tree->collapseItem( index ); // 2002-01-30 LEW } - // tqrepaint(); // this doesn't work 2002-01-30 LEW + // repaint(); // this doesn't work 2002-01-30 LEW /* 2002-01-30 LEW: RG and I don't like this behavior */ } @@ -419,7 +419,7 @@ void KDatMainWindow::fileBackup() TQString msg = i18n("KDat will dump your files properly to tape, but may not be able\n" "to restore them. To restore your files by hand, you need to know\n" "the name of the *non-rewinding* version of your tape device %1.\n" - ).tqarg(Options::instance()->getTapeDevice()); + ).arg(Options::instance()->getTapeDevice()); TQString msg2 = i18n("For example, if your device is /dev/st0, the non-rewinding version\n" "is /dev/nst0. If your device name doesn't look like that, type\n" "\"ls -l %2\" in a terminal window to see the real name of your\n" @@ -430,7 +430,7 @@ void KDatMainWindow::fileBackup() "The third call to \"tar\" will retrieve your data into your\n" "current directory. Please let us know if this happens to you!\n" " - KDat Maintenance Team\n" - ).tqarg(Options::instance()->getTapeDevice()); + ).arg(Options::instance()->getTapeDevice()); msg = msg.append(msg2); KMessageBox::sorry( this, msg); /* 2002-01-28 LEW */ @@ -446,7 +446,7 @@ void KDatMainWindow::fileBackup() backupProfile.setRemoveSnapshot( bp->getRemoveSnapshot() ); } else { TQString name; - name = i18n( "Archive created on %1" ).tqarg( KGlobal::locale()->formatDate(TQDate::currentDate(), true) ); + name = i18n( "Archive created on %1" ).arg( KGlobal::locale()->formatDate(TQDate::currentDate(), true) ); name = name.stripWhiteSpace(); TQStringList files; @@ -486,8 +486,8 @@ void KDatMainWindow::fileBackup() msg = i18n( "WARNING: The estimated archive size is %1 KB but " "the tape has only %2 KB of space!\n" "Back up anyway?" ) - .tqarg(KGlobal::locale()->formatNumber(size, 0)) - .tqarg(KGlobal::locale()->formatNumber(TapeManager::instance()->getMountedTape()->getSize() - tapeSize, 0 )); + .arg(KGlobal::locale()->formatNumber(size, 0)) + .arg(KGlobal::locale()->formatNumber(TapeManager::instance()->getMountedTape()->getSize() - tapeSize, 0 )); int result = KMessageBox::warningContinueCancel( this, msg, i18n("Backup"), i18n("Backup") ); if ( result != KMessageBox::Continue) { @@ -600,7 +600,7 @@ void KDatMainWindow::doVerify( bool restore ) ranges.addRange( it.current()->getStart(), it.current()->getEnd() ); } if ( rangeableNode->isType( Node::MountedArchiveNodeType ) ) { - // Make sure the mounted archive node has populated its tqchildren. + // Make sure the mounted archive node has populated its children. archiveNode = (MountedArchiveNode*)rangeableNode; if ( archiveNode->childCount() == 0 ) { bool dummy = TRUE; @@ -627,7 +627,7 @@ void KDatMainWindow::doVerify( bool restore ) // Compile a list of files to verify/restore. TQPtrStack<RangeableNode> stack; - // Make sure the mounted archive node has populated its tqchildren. + // Make sure the mounted archive node has populated its children. if ( archiveNode->childCount() == 0 ) { bool dummy = TRUE; archiveNode->expanding( dummy ); @@ -697,7 +697,7 @@ void KDatMainWindow::fileMountTape() "correct device is selected as the tape drive (e.g.\n" "/dev/st0). If you hear the tape drive moving, wait\n" "until it stops and then try mounting it again.") - .tqarg(Options::instance()->getTapeDevice()); + .arg(Options::instance()->getTapeDevice()); if ( !TapeManager::instance()->getMountedTape() ) { if ( Options::instance()->getLoadOnMount() ) { @@ -727,7 +727,7 @@ void KDatMainWindow::fileIndexTape() IndexDlg dlg( TapeManager::instance()->getMountedTape(), this ); if ( dlg.exec() == TQDialog::Accepted ) { TQString title; - title = i18n( "KDat: %1" ).tqarg( TapeManager::instance()->getMountedTape()->getName() ); + title = i18n( "KDat: %1" ).arg( TapeManager::instance()->getMountedTape()->getName() ); setCaption( title ); setIconText( title ); @@ -776,7 +776,7 @@ void KDatMainWindow::fileDeleteArchive() } TQString msg = - i18n( "An archive cannot be removed from the middle of the tape. If\nthe archive '%1' is deleted then\nthe following archives will also be deleted:\n%2\n\nDelete all listed archives?" ).tqarg(archive->getName()).tqarg(list); + i18n( "An archive cannot be removed from the middle of the tape. If\nthe archive '%1' is deleted then\nthe following archives will also be deleted:\n%2\n\nDelete all listed archives?" ).arg(archive->getName()).arg(list); int result = KMessageBox::warningContinueCancel( this, msg, i18n("Delete Archive"), i18n("Delete All")); if (result == KMessageBox::Continue) { @@ -790,7 +790,7 @@ void KDatMainWindow::fileDeleteArchive() } else { // This is the last (known) archive on the tape. TQString msg = - i18n( "Really delete the archive '%1'?" ).tqarg(archive->getName()); + i18n( "Really delete the archive '%1'?" ).arg(archive->getName()); int result = KMessageBox::warningContinueCancel( this, msg, i18n("Delete Archive"), i18n("Delete")); if (result == KMessageBox::Continue) { @@ -824,7 +824,7 @@ void KDatMainWindow::fileDeleteIndex() } TQString msg = - i18n( "Really delete the index for '%1'?" ).tqarg(tape->getName()); + i18n( "Really delete the index for '%1'?" ).arg(tape->getName()); int result = KMessageBox::warningContinueCancel( this, msg, i18n("Delete Tape Index"), i18n("Delete")); if (result == KMessageBox::Continue) { @@ -847,7 +847,7 @@ void KDatMainWindow::fileFormatTape() "correct device is selected as the tape drive (e.g.\n" "/dev/st0). If you hear the tape drive moving, wait\n" "until it stops and then try mounting it again.") - .tqarg(Options::instance()->getTapeDevice()); + .arg(Options::instance()->getTapeDevice()); if ( !TapeDrive::instance()->isTapePresent() ) { KMessageBox::sorry( this, msg ); @@ -865,7 +865,7 @@ void KDatMainWindow::fileFormatTape() i18n("Format Tape"), i18n("Format")); if (result == KMessageBox::Continue ) { TQString name; - name = i18n( "Tape created on %1" ).tqarg( KGlobal::locale()->formatDate(TQDate::currentDate(), true) ); + name = i18n( "Tape created on %1" ).arg( KGlobal::locale()->formatDate(TQDate::currentDate(), true) ); FormatOptDlg dlg( name.stripWhiteSpace(), this ); if ( dlg.exec() != TQDialog::Accepted ) { return; @@ -898,7 +898,7 @@ void KDatMainWindow::fileNewBackupProfile() // Pick a unique name. TQString name; for ( int i = 1; ; i++ ) { - name = i18n( "Backup Profile %1").tqarg( i ); + name = i18n( "Backup Profile %1").arg( i ); TQStringList list = BackupProfileManager::instance()->getBackupProfileNames(); TQStringList::Iterator it = list.begin(); for ( ; it != list.end(); ++it ) { @@ -946,7 +946,7 @@ void KDatMainWindow::fileDeleteBackupProfile() assert( backupProfile ); TQString msg = - i18n("Really delete backup profile '%1'?").tqarg(backupProfile->getName()); + i18n("Really delete backup profile '%1'?").arg(backupProfile->getName()); int result = KMessageBox::warningContinueCancel( this, msg, i18n("Delete Backup Profile"), i18n("Delete")); if (result == KMessageBox::Continue) { @@ -1103,8 +1103,8 @@ int KDatMainWindow::calcBackupSize( const TQString& workingDir, bool local, cons if( stop_flag == TRUE ) break; TQString* path = dirStack.pop(); msg = i18n("Estimating backup size: %1, %2" ) - .tqarg(Util::kbytesToString( size / 2 )) - .tqarg(KStringHandler::csqueeze(*path, 60)); + .arg(Util::kbytesToString( size / 2 )) + .arg(KStringHandler::csqueeze(*path, 60)); status( msg ); KApplication::kApplication()->processEvents(); dir.setPath( *path ); @@ -1232,7 +1232,7 @@ void KDatMainWindow::configureUI( Tape* tape ) // Title bar if ( tape ) { TQString title; - title = i18n( "KDat: %1" ).tqarg(tape->getName()); + title = i18n( "KDat: %1" ).arg(tape->getName()); setCaption( title ); setIconText( title ); } else { diff --git a/kdat/Node.cpp b/kdat/Node.cpp index 6e1b174..cfc0610 100644 --- a/kdat/Node.cpp +++ b/kdat/Node.cpp @@ -211,7 +211,7 @@ void TapeNode::expanding( bool expand ) expand = TRUE; if ( childCount() > 0 ) { - // We already have the tqchildren added + // We already have the children added return; } @@ -280,7 +280,7 @@ void ArchiveNode::expanding( bool expand ) expand = TRUE; if ( childCount() > 0 ) { - // We already have the tqchildren added. + // We already have the children added. return; } @@ -338,7 +338,7 @@ void TapeDirectoryNode::expanding( bool expand ) expand = TRUE; if ( childCount() > 0 ) { - // We already have the tqchildren added. + // We already have the children added. return; } @@ -443,7 +443,7 @@ void SelectableNode::doUpdateState() void SelectableNode::doSetSelected( bool select ) { - // All my tqchildren get the same selection state. + // All my children get the same selection state. for ( uint i = 0; i < childCount(); i++ ) { if ( select ) { if ( !((SelectableNode*)childAt( i ))->isSelected() ) { @@ -605,7 +605,7 @@ void SelectableNode::setSelected( bool select ) ((SelectableNode*)getParent())->doUpdateState(); } - owner->tqrepaint(); + owner->repaint(); KDatMainWindow::getInstance()->configureUI( TapeManager::instance()->getMountedTape() ); } @@ -680,7 +680,7 @@ void MountedArchiveNode::expanding( bool expand ) expand = TRUE; if ( childCount() > 0 ) { - // We already have the tqchildren added. + // We already have the children added. return; } @@ -780,7 +780,7 @@ void MountedTapeDirectoryNode::expanding( bool expand ) expand = TRUE; if ( childCount() > 0 ) { - // We already have the tqchildren added. + // We already have the children added. return; } @@ -934,7 +934,7 @@ void RootNode::expanding( bool expand ) { expand = TRUE; - // If we already have some tqchildren, check to see if the directory has been modified. + // If we already have some children, check to see if the directory has been modified. if ( childCount() > 0 ) { struct stat statinfo; if ( stat( "/", &statinfo ) < 0 ) { @@ -950,7 +950,7 @@ void RootNode::expanding( bool expand ) _mtime = statinfo.st_mtime; - // Remove all the tqchildren. + // Remove all the children. Node* n; while ( ( n = (Node*)getChild() ) ) { removeChild( n ); @@ -975,7 +975,7 @@ void RootNode::expanding( bool expand ) return; } - // Fill in the child's tqchildren. + // Fill in the child's children. const TQFileInfoList* list = dir.entryInfoList( TQDir::Hidden | TQDir::Files | TQDir::Dirs, TQDir::Name | TQDir::DirsFirst ); if ( list ) { TQFileInfoListIterator it( *list ); @@ -1050,7 +1050,7 @@ void DirectoryNode::expanding( bool expand ) } path.prepend( "/" ); - // If we already have some tqchildren, check to see if the directory has been modified. + // If we already have some children, check to see if the directory has been modified. if ( childCount() > 0 ) { struct stat statinfo; if ( stat( TQFile::encodeName(path), &statinfo ) < 0 ) { @@ -1066,7 +1066,7 @@ void DirectoryNode::expanding( bool expand ) _mtime = statinfo.st_mtime; - // Remove all the tqchildren. + // Remove all the children. Node* n; while ( ( n = (Node*)getChild() ) ) { removeChild( n ); @@ -1091,7 +1091,7 @@ void DirectoryNode::expanding( bool expand ) return; } - // Fill in the child's tqchildren. + // Fill in the child's children. const TQFileInfoList* list = dir.entryInfoList( TQDir::Hidden | TQDir::Files | TQDir::Dirs, TQDir::Name | TQDir::DirsFirst ); if ( list ) { TQFileInfoListIterator it( *list ); @@ -1210,7 +1210,7 @@ void TapeDriveNode::expanding( bool expand ) expand = TRUE; if ( childCount() > 0 ) { - // We already have the tqchildren added + // We already have the children added return; } @@ -1254,7 +1254,7 @@ void TapeDriveNode::slotTapeUnmounted() setPixmap( *ImageCache::instance()->getTapeUnmounted() ); setText( i18n( "<no tape>" ) ); - // Remove all the tqchildren. + // Remove all the children. Node* n; while ( ( n = (Node*)getChild() ) ) { Node::removeChild( n ); diff --git a/kdat/Node.h b/kdat/Node.h index d2d0c26..2caa24b 100644 --- a/kdat/Node.h +++ b/kdat/Node.h @@ -90,7 +90,7 @@ public: /** * This method is called immediately before the node is to be expanded. - * This method can be used to fill in the tqchildren of this node, or + * This method can be used to fill in the children of this node, or * prevent the node from expanding. The default implementation does * nothing. * @@ -359,7 +359,7 @@ public: virtual bool isType( int type ); /** - * Determine whether the node and all of its tqchildren are selected. + * Determine whether the node and all of its children are selected. * * @return TRUE if the node is selected, otherwise FALSE. */ @@ -373,7 +373,7 @@ public: bool hasSelectedChildren(); /** - * Select/deselect this node and all of its tqchildren. + * Select/deselect this node and all of its children. * * @param selected TRUE means the node will be selected, FALSE means the * node will be deselected. @@ -445,7 +445,7 @@ public: virtual const TQPtrList<Range>& getRanges(); /** - * Select/deselect this node and all of its tqchildren. + * Select/deselect this node and all of its children. * * @param selected TRUE means the node will be selected, FALSE means the * node will be deselected. @@ -516,7 +516,7 @@ public: virtual const TQPtrList<Range>& getRanges(); /** - * Select/deselect this node and all of its tqchildren. + * Select/deselect this node and all of its children. * * @param selected TRUE means the node will be selected, FALSE means the * node will be deselected. @@ -596,7 +596,7 @@ public: virtual const TQPtrList<Range>& getRanges(); /** - * Select/deselect this node and all of its tqchildren. + * Select/deselect this node and all of its children. * * @param selected TRUE means the node will be selected, FALSE means the * node will be deselected. @@ -863,7 +863,7 @@ public slots: /** * Locate the child associated with the modified tape index, and make sure - * that the displayed information (including all tqchildren) is updated. + * that the displayed information (including all children) is updated. * * @param tape A pointer to the tape index that was modified. */ @@ -924,7 +924,7 @@ public slots: /** * Locate the child associated with the modified tape index, and make sure - * that the displayed information (including all tqchildren) is updated. + * that the displayed information (including all children) is updated. * * @param tape A pointer to the tape index that was modified. */ diff --git a/kdat/Tape.cpp b/kdat/Tape.cpp index 1f762c3..ff35d1a 100644 --- a/kdat/Tape.cpp +++ b/kdat/Tape.cpp @@ -216,7 +216,7 @@ void Tape::read() default: { KMessageBox::sorry( KDatMainWindow::getInstance(), - i18n( "The tape index file format is version %d. The index cannot be read by this version of KDat. Perhaps the tape index file was created by a newer version of KDat?" ).tqarg(version ), + i18n( "The tape index file format is version %d. The index cannot be read by this version of KDat. Perhaps the tape index file was created by a newer version of KDat?" ).arg(version ), i18n("Tape Index") ); } } @@ -226,7 +226,7 @@ void Tape::readAll( int version ) { read(); - TQPtrListIterator<Archive> i( _tqchildren ); + TQPtrListIterator<Archive> i( _children ); for ( ; i.current(); ++i ) { i.current()->readAll( version ); } @@ -282,7 +282,7 @@ void Tape::write() memset( buf, 0, 4096 ); memcpy( buf, _name.ascii(), _name.length() > 4095 ? 4095 : _name.length() ); fwrite( buf, sizeof( char ), 4096, _fptr ); - int ival = _tqchildren.count(); + int ival = _children.count(); fwrite( &ival, sizeof( ival ), 1, _fptr ); // Fill in the archive offsets later... @@ -292,7 +292,7 @@ void Tape::write() } //===== Write archives ===== - TQPtrListIterator<Archive> i( _tqchildren ); + TQPtrListIterator<Archive> i( _children ); int count = 0; for ( ; i.current(); ++i, count++ ) { // Fill in the file offset. @@ -346,7 +346,7 @@ const TQPtrList<Archive>& Tape::getChildren() { read(); - return _tqchildren; + return _children; } void Tape::setName( const TQString & name ) @@ -528,7 +528,7 @@ void Tape::addChild( Archive* archive ) archive->calcRanges(); - _tqchildren.append( archive ); + _children.append( archive ); char buf[4096]; fseek( _fptr, 0, SEEK_END ); @@ -537,9 +537,9 @@ void Tape::addChild( Archive* archive ) fgets( buf, 4096, _fptr ); fgets( buf, 4096, _fptr ); fseek( _fptr, 12 + 4096, SEEK_CUR ); - int ival = _tqchildren.count(); + int ival = _children.count(); fwrite( &ival, sizeof( ival ), 1, _fptr ); - fseek( _fptr, ( _tqchildren.count() - 1 ) * 4, SEEK_CUR ); + fseek( _fptr, ( _children.count() - 1 ) * 4, SEEK_CUR ); fwrite( &here, sizeof( here ), 1, _fptr ); fseek( _fptr, here, SEEK_SET ); archive->write( _fptr ); @@ -559,21 +559,21 @@ void Tape::removeChild( Archive* archive ) { read(); - while ( _tqchildren.last() != archive ) { - _tqchildren.removeLast(); + while ( _children.last() != archive ) { + _children.removeLast(); } - _tqchildren.removeLast(); + _children.removeLast(); char buf[4096]; fseek( _fptr, 0, SEEK_SET ); fgets( buf, 4096, _fptr ); fgets( buf, 4096, _fptr ); fseek( _fptr, 12 + 4096, SEEK_CUR ); - int ival = _tqchildren.count(); + int ival = _children.count(); fwrite( &ival, sizeof( ival ), 1, _fptr ); int here; if ( ival > 0 ) { - fseek( _fptr, _tqchildren.count() * 4, SEEK_CUR ); + fseek( _fptr, _children.count() * 4, SEEK_CUR ); fread( &here, sizeof( here ), 1, _fptr ); } else { fseek( _fptr, MAX_NUM_ARCHIVES * 4, SEEK_CUR ); @@ -593,13 +593,13 @@ void Tape::removeChild( Archive* archive ) void Tape::clear() { - if ( _tqchildren.count() < 1 ) { + if ( _children.count() < 1 ) { return; } - while ( _tqchildren.first() ) { - delete _tqchildren.first(); - _tqchildren.removeFirst(); + while ( _children.first() ) { + delete _children.first(); + _children.removeFirst(); } char buf[4096]; @@ -607,7 +607,7 @@ void Tape::clear() fgets( buf, 4096, _fptr ); fgets( buf, 4096, _fptr ); fseek( _fptr, 12 + 4096, SEEK_CUR ); - int ival = _tqchildren.count(); + int ival = _children.count(); fwrite( &ival, sizeof( ival ), 1, _fptr ); fseek( _fptr, MAX_NUM_ARCHIVES * 4, SEEK_CUR ); int here = ftell( _fptr ); @@ -711,7 +711,7 @@ void Tape::readVersion1Index( FILE* fptr ) Archive* archive = new Archive( this, archiveTimeStamp, archiveName ); archive->setEndBlock( archiveEndBlock - archiveStartBlock ); - _tqchildren.append( archive ); + _children.append( archive ); // Read the number of files. if ( !fgets( buf, 4096, fptr ) ) { @@ -827,7 +827,7 @@ void Tape::readVersion2Index( FILE* fptr ) int ival; for ( ; numArchives; numArchives-- ) { fread( &ival, sizeof( ival ), 1, fptr ); - _tqchildren.append( new Archive( this, fptr, ival ) ); + _children.append( new Archive( this, fptr, ival ) ); } } @@ -870,7 +870,7 @@ void Tape::readVersion3Index( FILE* fptr ) int ival; for ( ; numArchives; numArchives-- ) { fread( &ival, sizeof( ival ), 1, fptr ); - _tqchildren.append( new Archive( this, fptr, ival ) ); + _children.append( new Archive( this, fptr, ival ) ); } } @@ -913,7 +913,7 @@ void Tape::readVersion4Index( FILE* fptr ) int ival; for ( ; numArchives; numArchives-- ) { fread( &ival, sizeof( ival ), 1, fptr ); - _tqchildren.append( new Archive( this, fptr, ival ) ); + _children.append( new Archive( this, fptr, ival ) ); } /* 2002-01-31 LEW */ diff --git a/kdat/Tape.h b/kdat/Tape.h index 153561e..335619c 100644 --- a/kdat/Tape.h +++ b/kdat/Tape.h @@ -34,7 +34,7 @@ class Tape { int _mtime; TQString _name; int _size; - TQPtrList<Archive> _tqchildren; + TQPtrList<Archive> _children; FILE* _fptr; @@ -148,7 +148,7 @@ public: void removeChild( Archive* archive ); /** - * Recursively destroy all tqchildren of the tape index. + * Recursively destroy all children of the tape index. */ void clear(); }; diff --git a/kdat/TapeInfoWidget.cpp b/kdat/TapeInfoWidget.cpp index 9ee819a..1455743 100644 --- a/kdat/TapeInfoWidget.cpp +++ b/kdat/TapeInfoWidget.cpp @@ -203,9 +203,9 @@ void TapeInfoWidget::setTape( Tape* tape ) } if ( _tape->getSize() > 0 ) { tmp = TQString::fromLatin1( "%1 / %2 (%3%)") - .tqarg(Util::kbytesToString( used )) - .tqarg(Util::kbytesToString( _tape->getSize() )) - .tqarg(used * 100 / _tape->getSize() ); + .arg(Util::kbytesToString( used )) + .arg(Util::kbytesToString( _tape->getSize() )) + .arg(used * 100 / _tape->getSize() ); } else { tmp = Util::kbytesToString( used ); } diff --git a/kdat/VerifyDlg.cpp b/kdat/VerifyDlg.cpp index f15dcff..19477c9 100644 --- a/kdat/VerifyDlg.cpp +++ b/kdat/VerifyDlg.cpp @@ -409,7 +409,7 @@ void VerifyDlg::updateStats() _kbytesRead->setText( str ); if ( elapsed > 0 ) { - str = i18n( "%1/min" ).tqarg(Util::kbytesToString( (int)_totalKBytes * 60 / elapsed ) ); + str = i18n( "%1/min" ).arg(Util::kbytesToString( (int)_totalKBytes * 60 / elapsed ) ); _transferRate->setText( str ); } } diff --git a/kdat/ktreeview.cpp b/kdat/ktreeview.cpp index 9c08c54..df68b3d 100644 --- a/kdat/ktreeview.cpp +++ b/kdat/ktreeview.cpp @@ -79,7 +79,7 @@ KTreeViewItem::KTreeViewItem(const TQString& theText, KTreeViewItem::~KTreeViewItem() { if (deleteChildren) { - // remove the tqchildren + // remove the children KTreeViewItem* i = child; while (i) { KTreeViewItem* d = i; @@ -133,7 +133,7 @@ KTreeViewItem* KTreeViewItem::childAt(int index) const return item; } -// returns the number of tqchildren this item has +// returns the number of children this item has uint KTreeViewItem::childCount() const { return numChildren; @@ -193,7 +193,7 @@ const TQString& KTreeViewItem::getText() const return text; } -// indicates whether this item has any tqchildren +// indicates whether this item has any children bool KTreeViewItem::hasChild() const { return child != 0; @@ -260,7 +260,7 @@ void KTreeViewItem::insertChild(int index, KTreeViewItem* newChild) // indicates whether this item is displayed expanded // NOTE: a TRUE response does not necessarily indicate the item -// has any tqchildren +// has any children bool KTreeViewItem::isExpanded() const { return expanded; @@ -403,7 +403,7 @@ void KTreeViewItem::paintTree(TQPainter* p, int indent, int cellHeight) const p->drawLine(parentLeaderX, cellCenterY, parentLeaderX, cellBottomY); /* - * If this item has tqchildren or siblings in the tree or is a child of + * If this item has children or siblings in the tree or is a child of * an item other than the root item then draw the little line from the * item out to the left. */ @@ -411,7 +411,7 @@ void KTreeViewItem::paintTree(TQPainter* p, int indent, int cellHeight) const parent->parent != 0 || /* * The following handles the case of an item at the end of the - * topmost level which doesn't have tqchildren. + * topmost level which doesn't have children. */ parent->getChild() != this) { @@ -435,7 +435,7 @@ void KTreeViewItem::paintTree(TQPainter* p, int indent, int cellHeight) const // removes the given (direct) child from the branch bool KTreeViewItem::removeChild(KTreeViewItem* theChild) { - // search item in list of tqchildren + // search item in list of children KTreeViewItem* prevItem = 0; KTreeViewItem* toRemove = getChild(); while (toRemove && toRemove != theChild) { @@ -646,7 +646,7 @@ void KTreeView::appendChildItem(const TQString & theText, const TQPixmap& thePix appendChildItem(item, thePath); } -// appends the given item to the tqchildren of the item at the given index +// appends the given item to the children of the item at the given index void KTreeView::appendChildItem(KTreeViewItem* newItem, int index) { /* find parent item and append new item to parent's sub tree */ @@ -656,7 +656,7 @@ void KTreeView::appendChildItem(KTreeViewItem* newItem, int index) appendChildItem(parentItem, newItem); } -// appends the given item to the tqchildren of the item at the end of the +// appends the given item to the children of the item at the end of the // given path void KTreeView::appendChildItem(KTreeViewItem* newItem, const KPath& thePath) { @@ -744,7 +744,7 @@ void KTreeView::clear() if(goingDown || TQApplication::closingDown()) return; if(autoU && isVisible()) - tqrepaint(); + repaint(); setAutoUpdate(autoU); } @@ -789,7 +789,7 @@ int KTreeView::expandLevel() const // expands or collapses the subtree rooted at the given item, // as approptiate -// if item has no tqchildren, does nothing +// if item has no children, does nothing void KTreeView::expandOrCollapseItem(int index) { KTreeViewItem *item = itemAt(index); @@ -813,7 +813,7 @@ bool KTreeView::forEveryItem(KForEvery func, void* user, KTreeViewItem* item) if ((*func)(item, user)) { return true; } - // visit the tqchildren (recursively) + // visit the children (recursively) if (item->hasChild()) { if (forEveryItem(func, user, item)) return true; @@ -833,7 +833,7 @@ bool KTreeView::forEveryVisibleItem(KForEvery func, void *user, if (item == 0) { item = treeRoot; } else { - // tqchildren are invisible (hence, nothing to do) + // children are invisible (hence, nothing to do) // if item is invisible or collapsed if (!item->isVisible() || !item->isExpanded()) { return false; @@ -847,7 +847,7 @@ bool KTreeView::forEveryVisibleItem(KForEvery func, void *user, if ((*func)(item, user)) { return true; } - // visit the tqchildren (recursively) + // visit the children (recursively) if (item->hasChild() && item->isExpanded()) { if (forEveryVisibleItem(func, user, item)) return true; @@ -1113,7 +1113,7 @@ void KTreeView::setExpandButtonDrawing(bool enable) drawExpandButton = enable; forEveryItem(&KTreeView::setItemExpandButtonDrawing, 0); if(autoUpdate() && isVisible()) - tqrepaint(); + repaint(); } // sets depth to which subtrees are automatically expanded, and @@ -1132,7 +1132,7 @@ void KTreeView::setExpandLevel(int level) } setCurrentItem(itemRow(item)); if(autoUpdate() && isVisible()) - tqrepaint(); + repaint(); } // sets the indent margin for all branches and repaints if auto update enabled @@ -1143,7 +1143,7 @@ void KTreeView::setIndentSpacing(int spacing) itemIndent = spacing; updateCellWidth(); if (autoUpdate() && isVisible()) - tqrepaint(); + repaint(); } // enables/disables vertical scrollbar @@ -1160,7 +1160,7 @@ void KTreeView::setShowItemText(bool enable) showText = enable; forEveryItem(&KTreeView::setItemShowText, 0); if(autoUpdate() && isVisible()) - tqrepaint(); + repaint(); } // indicates whether vertical scrolling is by pixel or row @@ -1177,7 +1177,7 @@ void KTreeView::setTreeDrawing(bool enable) drawTree = enable; forEveryItem(&KTreeView::setItemTreeDrawing, 0); if(autoUpdate() && isVisible()) - tqrepaint(); + repaint(); } // indicates whether item text keys are displayed @@ -1251,18 +1251,18 @@ void KTreeView::appendChildItem(KTreeViewItem* theParent, newItem->setExpanded(true); } - // fix up branch levels of any tqchildren that the new item may already have + // fix up branch levels of any children that the new item may already have if(newItem->hasChild()) { fixChildren(newItem); } - // if necessary, adjust cell width, number of rows and tqrepaint + // if necessary, adjust cell width, number of rows and repaint if (newItem->isVisible() || theParent->childCount() == 1) { bool autoU = autoUpdate(); setAutoUpdate(false); updateVisibleItems(); if(autoU && isVisible()) - tqrepaint(); + repaint(); setAutoUpdate(autoU); } } @@ -1302,7 +1302,7 @@ void KTreeView::collapseSubTree(KTreeViewItem* subRoot) } } // roland - tqrepaint(); + repaint(); setAutoUpdate(TRUE); // roland } @@ -1331,7 +1331,7 @@ void KTreeView::expandOrCollapse(KTreeViewItem* parent) emit expanded(parentIndex); } if (autoU && isVisible()) - tqrepaint(); + repaint(); setAutoUpdate(autoU); } @@ -1361,7 +1361,7 @@ void KTreeView::expandSubTree(KTreeViewItem* subRoot) } } // roland - tqrepaint(); + repaint(); setAutoUpdate(TRUE); // roland @@ -1493,7 +1493,7 @@ bool KTreeView::insertItem(KTreeViewItem* referenceItem, } else { // no reference item, append at end of visible tree - // need to tqrepaint + // need to repaint parentItem = treeRoot; parentItem->appendChild(newItem); } @@ -1502,18 +1502,18 @@ bool KTreeView::insertItem(KTreeViewItem* referenceItem, if (level(newItem) < expansion) newItem->setExpanded(true); - // fix up branch levels of any tqchildren + // fix up branch levels of any children if (newItem->hasChild()) fixChildren(newItem); - // if tqrepaint necessary, do it if visible and auto update + // if repaint necessary, do it if visible and auto update // enabled if (newItem->isVisible() || parentItem->childCount() == 1) { bool autoU = autoUpdate(); setAutoUpdate(FALSE); updateVisibleItems(); if(autoU && isVisible()) - tqrepaint(); + repaint(); setAutoUpdate(autoU); } return true; @@ -1545,7 +1545,7 @@ void KTreeView::join(KTreeViewItem *item) takeItem(item); insertItem(itemParent, item, FALSE); if(autoU && isVisible()) - tqrepaint(); + repaint(); setAutoUpdate(autoU); } } @@ -1651,7 +1651,7 @@ void KTreeView::lowerItem(KTreeViewItem *item) takeItem(item); insertItem(itemParent->childAt(itemChildIndex), item, FALSE); if(autoU && isVisible()) - tqrepaint(); + repaint(); setAutoUpdate(autoU); } } @@ -1877,7 +1877,7 @@ void KTreeView::raiseItem(KTreeViewItem *item) takeItem(item); insertItem(itemParent->childAt(--itemChildIndex), item, TRUE); if(autoU && isVisible()) - tqrepaint(); + repaint(); setAutoUpdate(autoU); } } @@ -1897,7 +1897,7 @@ KTreeViewItem* KTreeView::recursiveFind(KPath& path) return 0; /* - * Iterate through the parent's tqchildren searching for searchString. + * Iterate through the parent's children searching for searchString. */ KTreeViewItem* sibling = parent->getChild(); while (sibling != 0) { @@ -1963,7 +1963,7 @@ void KTreeView::split(KTreeViewItem *item) takeItem(item); appendChildItem(itemParent->childAt(--itemChildIndex), item); if(autoU && isVisible()) - tqrepaint(); + repaint(); setAutoUpdate(autoU); } @@ -2003,7 +2003,7 @@ void KTreeView::takeItem(KTreeViewItem* item) updateVisibleItems(); if (autoU && isVisible()) - tqrepaint(); + repaint(); setAutoUpdate(autoU); } @@ -2041,10 +2041,10 @@ void KTreeView::updateVisibleItemRec(KTreeViewItem* item, int& index, int& count } /* - * Record the tqchildren of item in the list of visible items. + * Record the children of item in the list of visible items. * * Don't register item itself, it's already in the list. Also only - * allocate new space for tqchildren. + * allocate new space for children. */ count += item->childCount(); if (count > itemCapacity) { @@ -2066,7 +2066,7 @@ void KTreeView::updateVisibleItemRec(KTreeViewItem* item, int& index, int& count visibleItems = newItems; itemCapacity = newCapacity; } - // insert tqchildren + // insert children for (KTreeViewItem* i = item->getChild(); i != 0; i = i->getSibling()) { visibleItems[index++] = i; updateVisibleItemRec(i, index, count); diff --git a/kdat/ktreeview.h b/kdat/ktreeview.h index deed0f8..6e43518 100644 --- a/kdat/ktreeview.h +++ b/kdat/ktreeview.h @@ -43,18 +43,18 @@ public: * item can be constructed this way, the text has to be non-null when * the item is added to the tree, or it will not be inserted. * - * The constructor sets the delete-tqchildren flag to false. This flag + * The constructor sets the delete-children flag to false. This flag * tells the item whether it shall delete the child items when it is * itself deleted. By default the creator of the item is responsible to * also delete the child items. (However, the versions of * KTreeView::appendChildItem and KTreeView::insertChildItem that do - * not take a KTreeViewItem set the delete-tqchildren flag to true.) + * not take a KTreeViewItem set the delete-children flag to true.) */ KTreeViewItem(const TQString& theText = TQString()); // text can not be null when added to the list! KTreeViewItem(const TQString& theText, const TQPixmap& thePixmap); /** - * Destructor. It destroys its tqchildren if this item has been marked + * Destructor. It destroys its children if this item has been marked * with setDeleteChildren(true). */ virtual ~KTreeViewItem(); @@ -123,7 +123,7 @@ public: const TQString& getText() const; /** - * Indicates whether this item has any tqchildren. + * Indicates whether this item has any children. */ bool hasChild() const; @@ -152,7 +152,7 @@ public: * items (if any) would be visible if this item were visible. * * Note: If this function returns true, it does not necessarily indicate that - * this item is visible or that this item has any tqchildren. + * this item is visible or that this item has any children. */ bool isExpanded() const; @@ -174,12 +174,12 @@ public: * Sets the delayed-expanding flag. If this flag is true, the expanding * signal is emitted when the item is about to be expanded. The expand * button is always painted for this item, even if it doesn't have - * tqchildren. + * children. */ void setDelayedExpanding(bool flag); /** - * Tells the item whether it should delete its tqchildren when it is + * Tells the item whether it should delete its children when it is * deleted. The default is false, which means that the child items must * be deleted explicitly. */ @@ -417,8 +417,8 @@ public: /** * Appends a new child item to the item at the specified row. If that - * item already has tqchildren, the new item is appended below these - * tqchildren. A KTreeViewItem is created for which the delete-tqchildren + * item already has children, the new item is appended below these + * children. A KTreeViewItem is created for which the delete-children * flag is set to true. */ void appendChildItem(const TQString & theText, const TQPixmap& thePixmap, @@ -432,8 +432,8 @@ public: /** * Appendss the specified item as a child of the item that is at the - * specified row. If that item already has tqchildren, the new item is - * appended below these tqchildren. + * specified row. If that item already has children, the new item is + * appended below these children. */ void appendChildItem(KTreeViewItem* newItem, int index); @@ -529,7 +529,7 @@ public: /** * Iterates every item in the tree, visible or not, and applies the * function func with a pointer to each item and user data supplied as - * parameters. The tqchildren of the specified root item are visited + * parameters. The children of the specified root item are visited * (root itself is not visited!). If root is 0 all items in the tree * are visited. KForEveryFunc is defined as: * @@ -568,7 +568,7 @@ public: * the value of prefix. The new item is added to the same branch as the * referenced item. If row is -1, the item is simply appended to the * tree at the topmost level. A KTreeViewItem is created for which the - * delete-tqchildren flag is set to true. Returns true if the item has + * delete-children flag is set to true. Returns true if the item has * been successfully inserted in the tree, otherwise false. */ bool insertItem(const TQString & theText, const TQPixmap& thePixmap, |