Rename a number of old tq methods that are no longer tq specific

pull/1/head
Timothy Pearson 12 years ago
parent db73314477
commit ef5831dd5c

@ -21,7 +21,7 @@
</property>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout6</cstring>
<cstring>layout6</cstring>
</property>
<vbox>
<property name="name">
@ -40,7 +40,7 @@
</property>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout1</cstring>
<cstring>layout1</cstring>
</property>
<hbox>
<property name="name">
@ -73,7 +73,7 @@
</widget>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout2</cstring>
<cstring>layout2</cstring>
</property>
<hbox>
<property name="name">
@ -89,7 +89,7 @@
<property name="sizeType">
<enum>Fixed</enum>
</property>
<property name="tqsizeHint">
<property name="sizeHint">
<size>
<width>20</width>
<height>10</height>
@ -186,7 +186,7 @@
</widget>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout3</cstring>
<cstring>layout3</cstring>
</property>
<hbox>
<property name="name">
@ -202,7 +202,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
<property name="tqsizeHint">
<property name="sizeHint">
<size>
<width>40</width>
<height>20</height>

@ -15,7 +15,7 @@
#include <config.h>
#include <tqlayout.h>
#include <layout.h>
#include <tqmap.h>
#include <tqfile.h>
#include <tqfileinfo.h>
@ -260,7 +260,7 @@ void K3bSetup2::updatePrograms()
if( perm != wantedPerm ||
fi.owner() != "root" ||
fi.group() != wantedGroup ) {
bi->setText( 4, TQString("%1 root.%2").tqarg(wantedPerm,0,8).tqarg(wantedGroup) );
bi->setText( 4, TQString("%1 root.%2").arg(wantedPerm,0,8).arg(wantedGroup) );
if( bi->isOn() )
d->changesNeeded = true;
}
@ -405,7 +405,7 @@ void K3bSetup2::save()
// TODO: create the group if it's not there
g = getgrnam( burningGroup().local8Bit() );
if( !g ) {
KMessageBox::error( this, i18n("There is no group %1.").tqarg(burningGroup()) );
KMessageBox::error( this, i18n("There is no group %1.").arg(burningGroup()) );
return;
}
}
@ -536,7 +536,7 @@ void K3bSetup2::slotAddDevice()
emit changed( d->changesNeeded );
}
else
KMessageBox::error( this, i18n("Could not find an additional device at\n%1").tqarg(newDevicename),
KMessageBox::error( this, i18n("Could not find an additional device at\n%1").arg(newDevicename),
i18n("Error"), false );
}
}

@ -24,7 +24,7 @@
#include <kgenericfactory.h>
#include <tqtextstream.h>
#include <textstream.h>
#include <tqdom.h>
#include <tqfile.h>

@ -187,7 +187,7 @@ K3bCddbQuery* K3bCddb::getQuery( const TQString& s )
}
m_httpQuery->setServer( server, port );
m_httpQuery->setCgiPath( m_bUseManualCgiPath ? m_cgiPath : TQString::tqfromLatin1("/~cddb/cddb.cgi") );
m_httpQuery->setCgiPath( m_bUseManualCgiPath ? m_cgiPath : TQString::fromLatin1("/~cddb/cddb.cgi") );
return m_httpQuery;
}

@ -21,7 +21,7 @@
#include <tqstringlist.h>
#include <tqregexp.h>
#include <tqtextstream.h>
#include <textstream.h>
#include <klocale.h>
#include <kdebug.h>
@ -58,7 +58,7 @@ void K3bCddbHttpQuery::doMatchQuery()
m_state = READ;
m_parsingBuffer.truncate(0);
performCommand( TQString( "cddb read %1 %2").tqarg( header().category ).tqarg( header().discid ) );
performCommand( TQString( "cddb read %1 %2").arg( header().category ).arg( header().discid ) );
}
@ -82,7 +82,7 @@ void K3bCddbHttpQuery::performCommand( const TQString& cmd )
if( !job ) {
setError( CONNECTION_ERROR );
emit infoMessage( i18n("Could not connect to host %1").tqarg(m_server) );
emit infoMessage( i18n("Could not connect to host %1").arg(m_server) );
emitQueryFinished();
return;
}

@ -18,7 +18,7 @@
#include <tqdir.h>
#include <tqfile.h>
#include <tqtextstream.h>
#include <textstream.h>
#include <kapplication.h>
#include <klocale.h>
@ -38,7 +38,7 @@ K3bCddbLocalQuery::~K3bCddbLocalQuery()
void K3bCddbLocalQuery::doQuery()
{
emit infoMessage( i18n("Searching entry in %1").tqarg( m_cddbDir ) );
emit infoMessage( i18n("Searching entry in %1").arg( m_cddbDir ) );
kapp->processEvents(); //BAD!
TQString path = preparePath( m_cddbDir );

@ -19,7 +19,7 @@
#include <tqdir.h>
#include <tqfile.h>
#include <tqtextstream.h>
#include <textstream.h>
#include <kdebug.h>
#include <klocale.h>
@ -94,7 +94,7 @@ void K3bCddbLocalSubmit::doSubmit()
else {
kdDebug() << "(K3bCddbLocalSubmit) could not find directory: " << path << endl;
setError( IO_ERROR );
emit infoMessage( i18n("Could not find directory: %1").tqarg(path) );
emit infoMessage( i18n("Could not find directory: %1").arg(path) );
emit submitFinished( this );
}
}

@ -16,7 +16,7 @@
#include "k3bcddbmultientriesdialog.h"
#include <tqlayout.h>
#include <layout.h>
#include <tqframe.h>
#include <tqlabel.h>
@ -29,13 +29,13 @@ K3bCddbMultiEntriesDialog::K3bCddbMultiEntriesDialog( TQWidget* parent, const ch
: KDialogBase( Plain, i18n("CDDB Database Entry"), Ok|Cancel, Ok, parent, name )
{
TQFrame* frame = plainPage();
TQVBoxLayout* tqlayout = new TQVBoxLayout( frame );
tqlayout->setAutoAdd( true );
tqlayout->setSpacing( spacingHint() );
tqlayout->setMargin( 0 );
TQVBoxLayout* layout = new TQVBoxLayout( frame );
layout->setAutoAdd( true );
layout->setSpacing( spacingHint() );
layout->setMargin( 0 );
TQLabel* infoLabel = new TQLabel( i18n("K3b found multiple inexact CDDB entries. Please select one."), frame );
infoLabel->tqsetAlignment( WordBreak );
infoLabel->setAlignment( WordBreak );
m_listBox = new KListBox( frame, "list_box");

@ -17,7 +17,7 @@
#include <tqstringlist.h>
#include <tqsocket.h>
#include <tqtextstream.h>
#include <textstream.h>
#include <klocale.h>
#include <kdebug.h>
@ -54,7 +54,7 @@ void K3bCddbpQuery::doQuery()
// connect to the server
m_socket->connectToHost( m_server, m_port );
emit infoMessage( i18n("Searching %1 on port %2").tqarg(m_server).tqarg(m_port) );
emit infoMessage( i18n("Searching %1 on port %2").arg(m_server).arg(m_port) );
}
@ -63,7 +63,7 @@ void K3bCddbpQuery::doMatchQuery()
// we should still be connected
// TODO: check this
TQString read = TQString( "cddb read %1 %2").tqarg( header().category ).tqarg( header().discid );
TQString read = TQString( "cddb read %1 %2").arg( header().category ).arg( header().discid );
m_state = READ;
m_parsingBuffer = "";
@ -258,16 +258,16 @@ void K3bCddbpQuery::slotError( int e )
{
switch(e) {
case TQSocket::ErrConnectionRefused:
kdDebug() << i18n("Connection to %1 refused").tqarg( m_server ) << endl;
emit infoMessage( i18n("Connection to %1 refused").tqarg( m_server ) );
kdDebug() << i18n("Connection to %1 refused").arg( m_server ) << endl;
emit infoMessage( i18n("Connection to %1 refused").arg( m_server ) );
break;
case TQSocket::ErrHostNotFound:
kdDebug() << i18n("Could not find host %1").tqarg( m_server ) << endl;
emit infoMessage( i18n("Could not find host %1").tqarg( m_server ) );
kdDebug() << i18n("Could not find host %1").arg( m_server ) << endl;
emit infoMessage( i18n("Could not find host %1").arg( m_server ) );
break;
case TQSocket::ErrSocketRead:
kdDebug() << i18n("Error while reading from %1").tqarg( m_server ) << endl;
emit infoMessage( i18n("Error while reading from %1").tqarg( m_server ) );
kdDebug() << i18n("Error while reading from %1").arg( m_server ) << endl;
emit infoMessage( i18n("Error while reading from %1").arg( m_server ) );
break;
}

@ -21,7 +21,7 @@
#include <tqstring.h>
#include <tqvaluelist.h>
#include <tqtextstream.h>
#include <textstream.h>
class TQSocket;

@ -25,7 +25,7 @@
#include <klocale.h>
#include <tqtextstream.h>
#include <textstream.h>
#include <tqstringlist.h>
#include <tqregexp.h>
#include <tqtimer.h>
@ -226,7 +226,7 @@ TQString K3bCddbQuery::handshakeString() const
if( host.isEmpty() )
host = "kde-host";
return TQString("%1 %2 K3b %3").tqarg(user).tqarg(host).tqarg(kapp->aboutData()->version());
return TQString("%1 %2 K3b %3").arg(user).arg(host).arg(kapp->aboutData()->version());
}
@ -238,10 +238,10 @@ TQString K3bCddbQuery::queryString() const
+ TQString::number( (unsigned int)m_toc.count() );
for( K3bDevice::Toc::const_iterator it = m_toc.begin(); it != m_toc.end(); ++it ) {
query.append( TQString( " %1" ).tqarg( (*it).firstSector().lba() ) );
query.append( TQString( " %1" ).arg( (*it).firstSector().lba() ) );
}
query.append( TQString( " %1" ).tqarg( m_toc.length().lba() / 75 ) );
query.append( TQString( " %1" ).arg( m_toc.length().lba() / 75 ) );
return query;
}

@ -19,7 +19,7 @@
#include <tqobject.h>
#include <tqstring.h>
#include <tqtextstream.h>
#include <textstream.h>
#include "k3bcddbresult.h"

@ -23,7 +23,7 @@
#include <tqfileinfo.h>
#include <tqobject.h>
#include <tqregexp.h>
#include <tqtextstream.h>
#include <textstream.h>
#include <k3bprocess.h>
#include <kdebug.h>
@ -186,7 +186,7 @@ bool K3bCdrecordProgram::scan( const TQString& p )
endPos = out.output().find( "\n", pos );
// cdrecord does not use local encoding for the copyright statement but plain latin1
bin->copyright = TQString::tqfromLatin1( out.output().mid( pos, endPos-pos ).local8Bit() ).stripWhiteSpace();
bin->copyright = TQString::fromLatin1( out.output().mid( pos, endPos-pos ).local8Bit() ).stripWhiteSpace();
}
else {
kdDebug() << "(K3bCdrecordProgram) could not start " << path << endl;

@ -169,7 +169,7 @@ TQString K3b::findUniqueFilePrefix( const TQString& _prefix, const TQString& pat
TQString K3b::findTempFile( const TQString& ending, const TQString& d )
{
return findUniqueFilePrefix( "k3b_", d ) + ( ending.isEmpty() ? TQString() : (TQString::tqfromLatin1(".") + ending) );
return findUniqueFilePrefix( "k3b_", d ) + ( ending.isEmpty() ? TQString() : (TQString::fromLatin1(".") + ending) );
}
@ -387,7 +387,7 @@ TQString K3b::externalBinDeviceParameter( K3bDevice::Device* dev, const K3bExter
else if( (plainAtapiSupport() && bin->hasFeature("plain-atapi") ) )
return dev->blockDeviceName();
else
return TQString("ATAPI:%1").tqarg(dev->blockDeviceName());
return TQString("ATAPI:%1").arg(dev->blockDeviceName());
}

@ -285,7 +285,7 @@ class LIBK3B_EXPORT K3bBurnJob : public K3bJob
void setWritingApp( int w ) { m_writeMethod = w; }
signals:
void buffertqStatus( int );
void bufferStatus( int );
void deviceBuffer( int );

@ -192,7 +192,7 @@ TQStringList K3bProcess::splitOutput( char* data, int len,
// check if line ends with a newline
// if not save the last line because it is not finished
TQChar c = buffer.right(1).at(0);
bool hasUnfinishedLine = ( c != '\n' && c != '\r' && c != TQChar(46) ); // What is tqunicode 46?? It is printed as a point
bool hasUnfinishedLine = ( c != '\n' && c != '\r' && c != TQChar(46) ); // What is unicode 46?? It is printed as a point
if( hasUnfinishedLine ) {
kdDebug() << "(K3bProcess) found unfinished line: '" << lines.last() << "'" << endl;
kdDebug() << "(K3bProcess) last char: '" << buffer.right(1) << "'" << endl;

@ -69,7 +69,7 @@ class K3bProgressInfoEvent : public TQCustomEvent
NewTask,
NewSubTask,
DebuggingOutput,
BuffertqStatus,
BufferStatus,
WriteSpeed,
NextTrack
};

@ -157,9 +157,9 @@ TQString K3bVersion::createVersionString( int majorVersion,
TQString s = TQString::number(majorVersion);
if( minorVersion > -1 ) {
s.append( TQString(".%1").tqarg(minorVersion) );
s.append( TQString(".%1").arg(minorVersion) );
if( patchlevel > -1 )
s.append( TQString(".%1").tqarg(patchlevel) );
s.append( TQString(".%1").arg(patchlevel) );
}
if( !suffix.isNull() )

@ -76,7 +76,7 @@ K3bAudioCueFileWritingJob::K3bAudioCueFileWritingJob( K3bJobHandler* jh, TQObjec
connect( m_audioJob, TQT_SIGNAL(processedSize(int, int)), this, TQT_SIGNAL(processedSubSize(int, int)) );
connect( m_audioJob, TQT_SIGNAL(processedSubSize(int, int)), this, TQT_SIGNAL(processedSubSize(int, int)) );
connect( m_audioJob, TQT_SIGNAL(burning(bool)), this, TQT_SIGNAL(burning(bool)) );
connect( m_audioJob, TQT_SIGNAL(buffertqStatus(int)), this, TQT_SIGNAL(buffertqStatus(int)) );
connect( m_audioJob, TQT_SIGNAL(bufferStatus(int)), this, TQT_SIGNAL(bufferStatus(int)) );
connect( m_audioJob, TQT_SIGNAL(deviceBuffer(int)), this, TQT_SIGNAL(deviceBuffer(int)) );
connect( m_audioJob, TQT_SIGNAL(writeSpeed(int, int)), this, TQT_SIGNAL(writeSpeed(int, int)) );
@ -252,19 +252,19 @@ void K3bAudioCueFileWritingJob::importCueInProject()
// now analyze the source
emit newTask( i18n("Analysing the audio file") );
emit newSubTask( i18n("Analysing %1").tqarg( parser.imageFilename() ) );
emit newSubTask( i18n("Analysing %1").arg( parser.imageFilename() ) );
// start the analyser thread
m_analyserThread->setDecoder( m_decoder );
m_analyserJob->start();
}
else {
emit infoMessage( i18n("Unable to handle '%1' due to an unsupported format.").tqarg( m_cueFile ), ERROR );
emit infoMessage( i18n("Unable to handle '%1' due to an unsupported format.").arg( m_cueFile ), ERROR );
jobFinished(false);
}
}
else {
emit infoMessage( i18n("No valid audio cue file: '%1'").tqarg( m_cueFile ), ERROR );
emit infoMessage( i18n("No valid audio cue file: '%1'").arg( m_cueFile ), ERROR );
jobFinished(false);
}
}

@ -93,7 +93,7 @@ void K3bAudioSessionReadingJob::WorkThread::run()
toc = device->readToc();
if( !paranoia->initParanoia( device, toc ) ) {
emitInfoMessage( i18n("Could not open device %1").tqarg(device->blockDeviceName()),
emitInfoMessage( i18n("Could not open device %1").arg(device->blockDeviceName()),
K3bJob::ERROR );
emitFinished(false);
return;
@ -154,7 +154,7 @@ void K3bAudioSessionReadingJob::WorkThread::run()
}
if( !waveFileWriter->open( filenames[currentTrack-1] ) ) {
emitInfoMessage( i18n("Unable to open '%1' for writing.").tqarg(filenames[currentTrack-1]), K3bJob::ERROR );
emitInfoMessage( i18n("Unable to open '%1' for writing.").arg(filenames[currentTrack-1]), K3bJob::ERROR );
writeError = true;
break;
}
@ -188,7 +188,7 @@ void K3bAudioSessionReadingJob::WorkThread::run()
device->block( false );
if( status != K3bCdparanoiaLib::S_OK ) {
emitInfoMessage( i18n("Unrecoverable error while ripping track %1.").tqarg(trackNum), K3bJob::ERROR );
emitInfoMessage( i18n("Unrecoverable error while ripping track %1.").arg(trackNum), K3bJob::ERROR );
emitFinished(false);
return;
}

@ -26,7 +26,7 @@
#include <kdebug.h>
#include <tqfile.h>
#include <tqtextstream.h>
#include <textstream.h>
@ -148,7 +148,7 @@ bool K3bBinImageWritingJob::prepareWriter()
connect( m_writer, TQT_SIGNAL(percent(int)), this, TQT_SLOT(copyPercent(int)) );
connect( m_writer, TQT_SIGNAL(subPercent(int)), this, TQT_SLOT(copySubPercent(int)) );
connect( m_writer, TQT_SIGNAL(processedSize(int, int)), this, TQT_SIGNAL(processedSize(int, int)) );
connect( m_writer, TQT_SIGNAL(buffer(int)), this, TQT_SIGNAL(buffertqStatus(int)) );
connect( m_writer, TQT_SIGNAL(buffer(int)), this, TQT_SIGNAL(bufferStatus(int)) );
connect( m_writer, TQT_SIGNAL(deviceBuffer(int)), this, TQT_SIGNAL(deviceBuffer(int)) );
connect( m_writer, TQT_SIGNAL(writeSpeed(int, int)), this, TQT_SIGNAL(writeSpeed(int, int)) );
connect( m_writer, TQT_SIGNAL(finished(bool)), this, TQT_SLOT(writerFinished(bool)) );
@ -207,7 +207,7 @@ void K3bBinImageWritingJob::writerFinished(bool ok)
void K3bBinImageWritingJob::slotNextTrack( int t, int tt )
{
emit newSubTask( i18n("Writing track %1 of %2").tqarg(t).tqarg(tt) );
emit newSubTask( i18n("Writing track %1 of %2").arg(t).arg(tt) );
}

@ -131,9 +131,9 @@ void K3bBlankingJob::slotStartErasing()
K3bDevice::STATE_COMPLETE|K3bDevice::STATE_INCOMPLETE,
K3bDevice::MEDIA_CD_RW,
i18n("Please insert a rewritable CD medium into drive<p><b>%1 %2 (%3)</b>.")
.tqarg(m_device->vendor())
.tqarg(m_device->description())
.tqarg(m_device->devicename()) ) < 0 ) {
.arg(m_device->vendor())
.arg(m_device->description())
.arg(m_device->devicename()) ) < 0 ) {
emit canceled();
jobFinished(false);
return;

@ -46,7 +46,7 @@
#include <tqstringlist.h>
#include <tqfile.h>
#include <tqregexp.h>
#include <tqtextstream.h>
#include <textstream.h>
#include <tqcstring.h>
#include <tqfileinfo.h>
#include <tqdir.h>
@ -313,7 +313,7 @@ void K3bCdCopyJob::slotDiskInfoReady( K3bDevice::DeviceHandler* dh )
unsigned long avail, size;
TQString pathToTest = m_tempPath.left( m_tempPath.findRev( '/' ) );
if( !K3b::kbFreeOnFs( pathToTest, size, avail ) ) {
emit infoMessage( i18n("Unable to determine free space in temporary directory '%1'.").tqarg(pathToTest), ERROR );
emit infoMessage( i18n("Unable to determine free space in temporary directory '%1'.").arg(pathToTest), ERROR );
d->error = true;
canCopy = false;
}
@ -379,7 +379,7 @@ void K3bCdCopyJob::slotCdTextReady( K3bDevice::DeviceHandler* dh )
if( dh->success() ) {
if( K3bDevice::CdText::checkCrc( dh->cdTextRaw() ) ) {
K3bDevice::CdText cdt( dh->cdTextRaw() );
emit infoMessage( i18n("Found CD-TEXT (%1 - %2).").tqarg(cdt.performer()).tqarg(cdt.title()), SUCCESS );
emit infoMessage( i18n("Found CD-TEXT (%1 - %2).").arg(cdt.performer()).arg(cdt.title()), SUCCESS );
d->haveCdText = true;
d->cdTextRaw = dh->cdTextRaw();
}
@ -429,7 +429,7 @@ void K3bCdCopyJob::slotCddbQueryFinished( int error )
d->cddbInfo = d->cddb->result();
d->haveCddb = true;
emit infoMessage( i18n("Found Cddb entry (%1 - %2).").tqarg(d->cddbInfo.cdArtist).tqarg(d->cddbInfo.cdTitle), SUCCESS );
emit infoMessage( i18n("Found Cddb entry (%1 - %2).").arg(d->cddbInfo.cdArtist).arg(d->cddbInfo.cdTitle), SUCCESS );
// save the entry locally
KConfig* c = k3bcore->config();
@ -441,7 +441,7 @@ void K3bCdCopyJob::slotCddbQueryFinished( int error )
emit infoMessage( i18n("No Cddb entry found."), WARNING );
}
else {
emit infoMessage( i18n("Cddb error (%1).").tqarg(d->cddb->errorString()), ERROR );
emit infoMessage( i18n("Cddb error (%1).").arg(d->cddb->errorString()), ERROR );
}
startCopy();
@ -524,24 +524,24 @@ bool K3bCdCopyJob::prepareImageFiles()
m_tempPath = K3b::findUniqueFilePrefix( "k3bCdCopy", m_tempPath );
kdDebug() << "(K3bCdCopyJob) creating temp dir: " << m_tempPath << endl;
if( !dir.mkdir( m_tempPath, true ) ) {
emit infoMessage( i18n("Unable to create temporary directory '%1'.").tqarg(m_tempPath), ERROR );
emit infoMessage( i18n("Unable to create temporary directory '%1'.").arg(m_tempPath), ERROR );
return false;
}
d->deleteTempDir = true;
}
m_tempPath = K3b::prepareDir( m_tempPath );
emit infoMessage( i18n("Using temporary directory %1.").tqarg(m_tempPath), INFO );
emit infoMessage( i18n("Using temporary directory %1.").arg(m_tempPath), INFO );
// create temp filenames
int i = 1;
for( K3bDevice::Toc::const_iterator it = d->toc.begin(); it != d->toc.end(); ++it ) {
if( (*it).type() == K3bDevice::Track::AUDIO ) {
d->imageNames.append( m_tempPath + TQString("Track%1.wav").tqarg(TQString::number(i).rightJustify(2, '0')) );
d->infNames.append( m_tempPath + TQString("Track%1.inf").tqarg(TQString::number(i).rightJustify(2, '0')) );
d->imageNames.append( m_tempPath + TQString("Track%1.wav").arg(TQString::number(i).rightJustify(2, '0')) );
d->infNames.append( m_tempPath + TQString("Track%1.inf").arg(TQString::number(i).rightJustify(2, '0')) );
}
else
d->imageNames.append( m_tempPath + TQString("Track%1.iso").tqarg(TQString::number(i).rightJustify(2, '0')) );
d->imageNames.append( m_tempPath + TQString("Track%1.iso").arg(TQString::number(i).rightJustify(2, '0')) );
++i;
}
@ -554,7 +554,7 @@ bool K3bCdCopyJob::prepareImageFiles()
else {
// we only need a single image file
if( !fi.isFile() ||
questionYesNo( i18n("Do you want to overwrite %1?").tqarg(m_tempPath),
questionYesNo( i18n("Do you want to overwrite %1?").arg(m_tempPath),
i18n("File Exists") ) ) {
if( fi.isDir() )
m_tempPath = K3b::findTempFile( "iso", m_tempPath );
@ -564,7 +564,7 @@ bool K3bCdCopyJob::prepareImageFiles()
}
// else the user specified a file in an existing dir
emit infoMessage( i18n("Writing image file to %1.").tqarg(m_tempPath), INFO );
emit infoMessage( i18n("Writing image file to %1.").arg(m_tempPath), INFO );
}
else
return false;
@ -580,12 +580,12 @@ void K3bCdCopyJob::readNextSession()
{
if( !m_onTheFly || m_onlyCreateImages ) {
if( d->numSessions > 1 )
emit newTask( i18n("Reading Session %1").tqarg(d->currentReadSession) );
emit newTask( i18n("Reading Session %1").arg(d->currentReadSession) );
else
emit newTask( i18n("Reading Source Medium") );
if( d->currentReadSession == 1 )
emit newSubTask( i18n("Reading track %1 of %2").tqarg(1).tqarg(d->toc.count()) );
emit newSubTask( i18n("Reading track %1 of %2").arg(1).arg(d->toc.count()) );
}
// there is only one situation where we need the audiosessionreader:
@ -677,17 +677,17 @@ bool K3bCdCopyJob::writeNextSession()
// we emit our own task since the cdrecord task is way too simple
if( d->numSessions > 1 ) {
if( m_simulate )
emit newTask( i18n("Simulating Session %1").tqarg(d->currentWrittenSession) );
emit newTask( i18n("Simulating Session %1").arg(d->currentWrittenSession) );
else if( m_copies > 1 )
emit newTask( i18n("Writing Copy %1 (Session %2)").tqarg(d->doneCopies+1).tqarg(d->currentWrittenSession) );
emit newTask( i18n("Writing Copy %1 (Session %2)").arg(d->doneCopies+1).arg(d->currentWrittenSession) );
else
emit newTask( i18n("Writing Copy (Session %2)").tqarg(d->currentWrittenSession) );
emit newTask( i18n("Writing Copy (Session %2)").arg(d->currentWrittenSession) );
}
else {
if( m_simulate )
emit newTask( i18n("Simulating") );
else if( m_copies > 1 )
emit newTask( i18n("Writing Copy %1").tqarg(d->doneCopies+1) );
emit newTask( i18n("Writing Copy %1").arg(d->doneCopies+1) );
else
emit newTask( i18n("Writing Copy") );
}
@ -713,7 +713,7 @@ bool K3bCdCopyJob::writeNextSession()
connect( d->cdrecordWriter, TQT_SIGNAL(subPercent(int)), this, TQT_SIGNAL(subPercent(int)) );
connect( d->cdrecordWriter, TQT_SIGNAL(processedSubSize(int, int)), this, TQT_SIGNAL(processedSubSize(int, int)) );
connect( d->cdrecordWriter, TQT_SIGNAL(nextTrack(int, int)), this, TQT_SLOT(slotWritingNextTrack(int, int)) );
connect( d->cdrecordWriter, TQT_SIGNAL(buffer(int)), this, TQT_SIGNAL(buffertqStatus(int)) );
connect( d->cdrecordWriter, TQT_SIGNAL(buffer(int)), this, TQT_SIGNAL(bufferStatus(int)) );
connect( d->cdrecordWriter, TQT_SIGNAL(deviceBuffer(int)), this, TQT_SIGNAL(deviceBuffer(int)) );
connect( d->cdrecordWriter, TQT_SIGNAL(writeSpeed(int, int)), this, TQT_SIGNAL(writeSpeed(int, int)) );
connect( d->cdrecordWriter, TQT_SIGNAL(finished(bool)), this, TQT_SLOT(slotWriterFinished(bool)) );
@ -923,7 +923,7 @@ bool K3bCdCopyJob::writeNextSession()
trackLen = trackLen * 2056; // see k3bdatatrackreader.h
else
trackLen = trackLen * 2332; // see k3bdatatrackreader.h
d->cdrecordWriter->addArgument( TQString("-tsize=%1").tqarg(trackLen) )->addArgument("-");
d->cdrecordWriter->addArgument( TQString("-tsize=%1").arg(trackLen) )->addArgument("-");
}
else if( d->toc.contentType() == K3bDevice::MIXED )
d->cdrecordWriter->addArgument( d->imageNames[d->toc.count()-1] );
@ -953,7 +953,7 @@ void K3bCdCopyJob::slotSessionReaderFinished( bool success )
if( success ) {
if( d->numSessions > 1 )
emit infoMessage( i18n("Successfully read session %1.").tqarg(d->currentReadSession), SUCCESS );
emit infoMessage( i18n("Successfully read session %1.").arg(d->currentReadSession), SUCCESS );
else
emit infoMessage( i18n("Successfully read source disk."), SUCCESS );
@ -987,7 +987,7 @@ void K3bCdCopyJob::slotSessionReaderFinished( bool success )
}
else {
if( !d->canceled ) {
emit infoMessage( i18n("Error while reading session %1.").tqarg(d->currentReadSession), ERROR );
emit infoMessage( i18n("Error while reading session %1.").arg(d->currentReadSession), ERROR );
if( m_onTheFly )
d->cdrecordWriter->setSourceUnreadable(true);
}
@ -1137,14 +1137,14 @@ void K3bCdCopyJob::slotWritingNextTrack( int t, int tt )
{
if( d->toc.contentType() == K3bDevice::MIXED ) {
if( d->currentWrittenSession == 1 )
emit newSubTask( i18n("Writing track %1 of %2").tqarg(t).tqarg(d->toc.count()) );
emit newSubTask( i18n("Writing track %1 of %2").arg(t).arg(d->toc.count()) );
else
emit newSubTask( i18n("Writing track %1 of %2").tqarg(d->toc.count()).tqarg(d->toc.count()) );
emit newSubTask( i18n("Writing track %1 of %2").arg(d->toc.count()).arg(d->toc.count()) );
}
else if( d->numSessions > 1 )
emit newSubTask( i18n("Writing track %1 of %2").tqarg(d->currentWrittenSession).tqarg(d->toc.count()) );
emit newSubTask( i18n("Writing track %1 of %2").arg(d->currentWrittenSession).arg(d->toc.count()) );
else
emit newSubTask( i18n("Writing track %1 of %2").tqarg(t).tqarg(tt) );
emit newSubTask( i18n("Writing track %1 of %2").arg(t).arg(tt) );
}
@ -1159,7 +1159,7 @@ void K3bCdCopyJob::slotReadingNextTrack( int t, int )
else
track = d->currentReadSession;
emit newSubTask( i18n("Reading track %1 of %2").tqarg(track).tqarg(d->toc.count()) );
emit newSubTask( i18n("Reading track %1 of %2").arg(track).arg(d->toc.count()) );
}
}

@ -95,7 +95,7 @@ void K3bCdda2wavReader::start( bool onlyInfo )
d->cdda2wavBin = k3bcore->externalBinManager()->binObject( "cdda2wav" );
if( !d->cdda2wavBin ) {
emit infoMessage( i18n("Could not find %1 executable.").tqarg("cdda2wav"), ERROR );
emit infoMessage( i18n("Could not find %1 executable.").arg("cdda2wav"), ERROR );
jobFinished(false);
d->running = false;
return;
@ -115,7 +115,7 @@ void K3bCdda2wavReader::start( bool onlyInfo )
*d->process << d->cdda2wavBin->path;
*d->process << "-vall" << ( d->cdda2wavBin->hasFeature( "gui" ) ? "-gui" : "-g" );
if( d->cdda2wavBin->hasFeature( "dev" ) )
*d->process << TQString("dev=%1").tqarg(K3bDevice::externalBinDeviceParameter(m_device, d->cdda2wavBin));
*d->process << TQString("dev=%1").arg(K3bDevice::externalBinDeviceParameter(m_device, d->cdda2wavBin));
else
*d->process << "-D" << K3bDevice::externalBinDeviceParameter(m_device, d->cdda2wavBin);
*d->process << ( d->cdda2wavBin->hasFeature( "bulk" ) ? "-bulk" : "-B" );
@ -134,7 +134,7 @@ void K3bCdda2wavReader::start( bool onlyInfo )
// something went wrong when starting the program
// it "should" be the executable
kdDebug() << "(K3bCdda2wavReader) could not start cdda2wav" << endl;
emit infoMessage( i18n("Could not start %1.").tqarg("cdda2wav"), K3bJob::ERROR );
emit infoMessage( i18n("Could not start %1.").arg("cdda2wav"), K3bJob::ERROR );
d->running = false;
jobFinished(false);
}
@ -240,12 +240,12 @@ void K3bCdda2wavReader::slotProcessExited( KProcess* p )
}
else {
emit infoMessage( i18n("%1 returned an unknown error (code %2).")
.tqarg("Cdda2wav").tqarg(p->exitStatus()), ERROR );
.arg("Cdda2wav").arg(p->exitStatus()), ERROR );
jobFinished( false );
}
}
else {
emit infoMessage( i18n("%1 did not exit cleanly.").tqarg("Cdda2wav"),
emit infoMessage( i18n("%1 did not exit cleanly.").arg("Cdda2wav"),
ERROR );
jobFinished( false );
}

@ -85,13 +85,13 @@ void K3bCloneJob::start()
//
const K3bExternalBin* cdrecordBin = k3bcore->externalBinManager()->binObject( "cdrecord" );
if( !cdrecordBin ) {
emit infoMessage( i18n("Could not find %1 executable.").tqarg("cdrecord"), ERROR );
emit infoMessage( i18n("Could not find %1 executable.").arg("cdrecord"), ERROR );
jobFinished(false);
m_running = false;
return;
}
else if( !cdrecordBin->hasFeature( "clone" ) ) {
emit infoMessage( i18n("Cdrecord version %1 does not have cloning support.").tqarg(cdrecordBin->version), ERROR );
emit infoMessage( i18n("Cdrecord version %1 does not have cloning support.").arg(cdrecordBin->version), ERROR );
jobFinished(false);
m_running = false;
return;
@ -109,8 +109,8 @@ void K3bCloneJob::start()
if( !writer()->supportsWritingMode( K3bDevice::RAW_R96R ) &&
!writer()->supportsWritingMode( K3bDevice::RAW_R16 ) ) {
emit infoMessage( i18n("CD writer %1 does not support cloning.")
.tqarg(writer()->vendor())
.tqarg(writer()->description()), ERROR );
.arg(writer()->vendor())
.arg(writer()->description()), ERROR );
m_running = false;
jobFinished(false);
return;
@ -180,7 +180,7 @@ void K3bCloneJob::prepareWriter()
connect( m_writerJob, TQT_SIGNAL(percent(int)), this, TQT_SIGNAL(subPercent(int)) );
connect( m_writerJob, TQT_SIGNAL(nextTrack(int, int)), this, TQT_SLOT(slotWriterNextTrack(int, int)) );
connect( m_writerJob, TQT_SIGNAL(processedSize(int, int)), this, TQT_SIGNAL(processedSubSize(int, int)) );
connect( m_writerJob, TQT_SIGNAL(buffer(int)), this, TQT_SIGNAL(buffertqStatus(int)) );
connect( m_writerJob, TQT_SIGNAL(buffer(int)), this, TQT_SIGNAL(bufferStatus(int)) );
connect( m_writerJob, TQT_SIGNAL(deviceBuffer(int)), this, TQT_SIGNAL(deviceBuffer(int)) );
connect( m_writerJob, TQT_SIGNAL(writeSpeed(int, int)), this, TQT_SIGNAL(writeSpeed(int, int)) );
connect( m_writerJob, TQT_SIGNAL(finished(bool)), this, TQT_SLOT(slotWriterFinished(bool)) );
@ -222,7 +222,7 @@ void K3bCloneJob::slotWriterPercent( int p )
void K3bCloneJob::slotWriterNextTrack( int t, int tt )
{
emit newSubTask( i18n("Writing Track %1 of %2").tqarg(t).tqarg(tt) );
emit newSubTask( i18n("Writing Track %1 of %2").arg(t).arg(tt) );
}
@ -239,7 +239,7 @@ void K3bCloneJob::slotWriterFinished( bool success )
if( success ) {
d->doneCopies++;
emit infoMessage( i18n("Successfully written clone copy %1.").tqarg(d->doneCopies), INFO );
emit infoMessage( i18n("Successfully written clone copy %1.").arg(d->doneCopies), INFO );
if( d->doneCopies < m_copies ) {
K3bDevice::eject( writer() );
@ -330,7 +330,7 @@ void K3bCloneJob::startWriting()
if( m_simulate )
emit newTask( i18n("Simulating clone copy") );
else
emit newTask( i18n("Writing clone copy %1").tqarg(d->doneCopies+1) );
emit newTask( i18n("Writing clone copy %1").arg(d->doneCopies+1) );
m_writerJob->start();
}

@ -22,7 +22,7 @@
#include <k3bglobals.h>
#include <tqfile.h>
#include <tqtextstream.h>
#include <textstream.h>
#include <kdebug.h>

@ -109,7 +109,7 @@ void K3bDataTrackReader::WorkThread::run()
emitStarted();
if( !m_device->open() ) {
emitInfoMessage( i18n("Could not open device %1").tqarg(m_device->blockDeviceName()), K3bJob::ERROR );
emitInfoMessage( i18n("Could not open device %1").arg(m_device->blockDeviceName()), K3bJob::ERROR );
emitFinished(false);
return;
}
@ -142,7 +142,7 @@ void K3bDataTrackReader::WorkThread::run()
}
if( !m_libcss->open(m_device) ) {
emitInfoMessage( i18n("Could not open device %1").tqarg(m_device->blockDeviceName()), K3bJob::ERROR );
emitInfoMessage( i18n("Could not open device %1").arg(m_device->blockDeviceName()), K3bJob::ERROR );
emitFinished(false);
return;
}
@ -183,14 +183,14 @@ void K3bDataTrackReader::WorkThread::run()
}
}
emitInfoMessage( i18n("Reading with sector size %1.").tqarg(m_usedSectorSize), K3bJob::INFO );
emitInfoMessage( i18n("Reading with sector size %1.").arg(m_usedSectorSize), K3bJob::INFO );
emitDebuggingOutput( "K3bDataTrackReader",
TQString("reading sectors %1 to %2 with sector size %3. Length: %4 sectors, %5 bytes.")
.tqarg( m_firstSector.lba() )
.tqarg( m_lastSector.lba() )
.tqarg( m_usedSectorSize )
.tqarg( m_lastSector.lba() - m_firstSector.lba() + 1 )
.tqarg( TQ_UINT64(m_usedSectorSize) * (TQ_UINT64)(m_lastSector.lba() - m_firstSector.lba() + 1) ) );
.arg( m_firstSector.lba() )
.arg( m_lastSector.lba() )
.arg( m_usedSectorSize )
.arg( m_lastSector.lba() - m_firstSector.lba() + 1 )
.arg( TQ_UINT64(m_usedSectorSize) * (TQ_UINT64)(m_lastSector.lba() - m_firstSector.lba() + 1) ) );
TQFile file;
if( m_fd == -1 ) {
@ -199,7 +199,7 @@ void K3bDataTrackReader::WorkThread::run()
m_device->close();
if( m_useLibdvdcss )
m_libcss->close();
emitInfoMessage( i18n("Unable to open '%1' for writing.").tqarg(m_imagePath), K3bJob::ERROR );
emitInfoMessage( i18n("Unable to open '%1' for writing.").arg(m_imagePath), K3bJob::ERROR );
emitFinished( false );
return;
}
@ -231,7 +231,7 @@ void K3bDataTrackReader::WorkThread::run()
// s_bufferSizeSectors = K3bDevice::determineMaxReadingBufferSize( m_device, m_firstSector );
if( s_bufferSizeSectors <= 0 ) {
emitInfoMessage( i18n("Error while reading sector %1.").tqarg(m_firstSector.lba()), K3bJob::ERROR );
emitInfoMessage( i18n("Error while reading sector %1.").arg(m_firstSector.lba()), K3bJob::ERROR );
emitFinished(false);
m_device->block( false );
k3bcore->unblockDevice( m_device );
@ -239,7 +239,7 @@ void K3bDataTrackReader::WorkThread::run()
}
kdDebug() << "(K3bDataTrackReader) using buffer size of " << s_bufferSizeSectors << " blocks." << endl;
emitDebuggingOutput( "K3bDataTrackReader", TQString("using buffer size of %1 blocks.").tqarg( s_bufferSizeSectors ) );
emitDebuggingOutput( "K3bDataTrackReader", TQString("using buffer size of %1 blocks.").arg( s_bufferSizeSectors ) );
// 2. get it on
K3b::Msf currentSector = m_firstSector;
@ -279,7 +279,7 @@ void K3bDataTrackReader::WorkThread::run()
<< " current sector: " << (currentSector.lba()-m_firstSector.lba()) << endl;
emitDebuggingOutput( "K3bDataTrackReader",
TQString("Error while writing to fd %1. Current sector is %2.")
.tqarg(m_fd).tqarg(currentSector.lba()-m_firstSector.lba()) );
.arg(m_fd).arg(currentSector.lba()-m_firstSector.lba()) );
writeError = true;
break;
}
@ -290,7 +290,7 @@ void K3bDataTrackReader::WorkThread::run()
<< " current sector: " << (currentSector.lba()-m_firstSector.lba()) << endl;
emitDebuggingOutput( "K3bDataTrackReader",
TQString("Error while writing to file %1. Current sector is %2.")
.tqarg(m_imagePath).tqarg(currentSector.lba()-m_firstSector.lba()) );
.arg(m_imagePath).arg(currentSector.lba()-m_firstSector.lba()) );
writeError = true;
break;
}
@ -331,8 +331,8 @@ void K3bDataTrackReader::WorkThread::run()
emitDebuggingOutput( "K3bDataTrackReader",
TQString("Read a total of %1 sectors (%2 bytes)")
.tqarg(totalReadSectors.lba())
.tqarg((TQ_UINT64)totalReadSectors.lba()*(TQ_UINT64)m_usedSectorSize) );
.arg(totalReadSectors.lba())
.arg((TQ_UINT64)totalReadSectors.lba()*(TQ_UINT64)m_usedSectorSize) );
if( m_canceled )
emitCanceled();
@ -386,8 +386,8 @@ int K3bDataTrackReader::WorkThread::read( unsigned char* buffer, unsigned long s
// here we read every single sector for itself to find the troubleing ones
bool K3bDataTrackReader::WorkThread::retryRead( unsigned char* buffer, unsigned long startSector, unsigned int len )
{
emitDebuggingOutput( "K3bDataTrackReader", TQString( "Problem while reading. Retrying from sector %1.").tqarg(startSector) );
emitInfoMessage( i18n("Problem while reading. Retrying from sector %1.").tqarg(startSector), K3bJob::WARNING );
emitDebuggingOutput( "K3bDataTrackReader", TQString( "Problem while reading. Retrying from sector %1.").arg(startSector) );
emitInfoMessage( i18n("Problem while reading. Retrying from sector %1.").arg(startSector), K3bJob::WARNING );
int sectorsRead = -1;
bool success = true;
@ -403,16 +403,16 @@ bool K3bDataTrackReader::WorkThread::retryRead( unsigned char* buffer, unsigned
if( !success ) {
if( m_ignoreReadErrors ) {
emitInfoMessage( i18n("Ignoring read error in sector %1.").tqarg(sector), K3bJob::ERROR );
emitDebuggingOutput( "K3bDataTrackReader", TQString( "Ignoring read error in sector %1.").tqarg(sector) );
emitInfoMessage( i18n("Ignoring read error in sector %1.").arg(sector), K3bJob::ERROR );
emitDebuggingOutput( "K3bDataTrackReader", TQString( "Ignoring read error in sector %1.").arg(sector) );
++m_errorSectorCount;
// ::memset( &buffer[i], 0, 1 );
success = true;
}
else {
emitInfoMessage( i18n("Error while reading sector %1.").tqarg(sector), K3bJob::ERROR );
emitDebuggingOutput( "K3bDataTrackReader", TQString( "Read error in sector %1.").tqarg(sector) );
emitInfoMessage( i18n("Error while reading sector %1.").arg(sector), K3bJob::ERROR );
emitDebuggingOutput( "K3bDataTrackReader", TQString( "Read error in sector %1.").arg(sector) );
break;
}
}

@ -122,7 +122,7 @@ void K3bDvdCopyJob::start()
k3bcore->externalBinManager()->binObject( "growisofs" )->version < K3bVersion( 5, 12 ) ) {
m_onTheFly = false;
emit infoMessage( i18n("K3b does not support writing on-the-fly with growisofs %1.")
.tqarg(k3bcore->externalBinManager()->binObject( "growisofs" )->version), ERROR );
.arg(k3bcore->externalBinManager()->binObject( "growisofs" )->version), ERROR );
emit infoMessage( i18n("Disabling on-the-fly writing."), INFO );
}
@ -295,7 +295,7 @@ void K3bDvdCopyJob::slotDiskInfoReady( K3bDevice::DeviceHandler* dh )
//
TQFileInfo fi( m_imagePath );
if( !fi.isFile() ||
questionYesNo( i18n("Do you want to overwrite %1?").tqarg(m_imagePath),
questionYesNo( i18n("Do you want to overwrite %1?").arg(m_imagePath),
i18n("File Exists") ) ) {
if( fi.isDir() )
m_imagePath = K3b::findTempFile( "iso", m_imagePath );
@ -305,7 +305,7 @@ void K3bDvdCopyJob::slotDiskInfoReady( K3bDevice::DeviceHandler* dh )
}
// else the user specified a file in an existing dir
emit infoMessage( i18n("Writing image file to %1.").tqarg(m_imagePath), INFO );
emit infoMessage( i18n("Writing image file to %1.").arg(m_imagePath), INFO );
emit newSubTask( i18n("Reading source medium.") );
}
@ -316,7 +316,7 @@ void K3bDvdCopyJob::slotDiskInfoReady( K3bDevice::DeviceHandler* dh )
unsigned long avail, size;
TQString pathToTest = m_imagePath.left( m_imagePath.findRev( '/' ) );
if( !K3b::kbFreeOnFs( pathToTest, size, avail ) ) {
emit infoMessage( i18n("Unable to determine free space in temporary directory '%1'.").tqarg(pathToTest), ERROR );
emit infoMessage( i18n("Unable to determine free space in temporary directory '%1'.").arg(pathToTest), ERROR );
jobFinished(false);
d->running = false;
return;
@ -332,7 +332,7 @@ void K3bDvdCopyJob::slotDiskInfoReady( K3bDevice::DeviceHandler* dh )
d->imageFile.setName( m_imagePath );
if( !d->imageFile.open( IO_WriteOnly ) ) {
emit infoMessage( i18n("Unable to open '%1' for writing.").tqarg(m_imagePath), ERROR );
emit infoMessage( i18n("Unable to open '%1' for writing.").arg(m_imagePath), ERROR );
jobFinished( false );
d->running = false;
return;
@ -353,7 +353,7 @@ void K3bDvdCopyJob::slotDiskInfoReady( K3bDevice::DeviceHandler* dh )
if( m_simulate )
emit newTask( i18n("Simulating DVD copy") );
else if( m_copies > 1 )
emit newTask( i18n("Writing DVD copy %1").tqarg(d->doneCopies+1) );
emit newTask( i18n("Writing DVD copy %1").arg(d->doneCopies+1) );
else
emit newTask( i18n("Writing DVD copy") );
@ -434,7 +434,7 @@ void K3bDvdCopyJob::prepareWriter()
connect( d->writerJob, TQT_SIGNAL(percent(int)), this, TQT_SLOT(slotWriterProgress(int)) );
connect( d->writerJob, TQT_SIGNAL(processedSize(int, int)), this, TQT_SIGNAL(processedSize(int, int)) );
connect( d->writerJob, TQT_SIGNAL(processedSubSize(int, int)), this, TQT_SIGNAL(processedSubSize(int, int)) );
connect( d->writerJob, TQT_SIGNAL(buffer(int)), this, TQT_SIGNAL(buffertqStatus(int)) );
connect( d->writerJob, TQT_SIGNAL(buffer(int)), this, TQT_SIGNAL(bufferStatus(int)) );
connect( d->writerJob, TQT_SIGNAL(deviceBuffer(int)), this, TQT_SIGNAL(deviceBuffer(int)) );
connect( d->writerJob, TQT_SIGNAL(writeSpeed(int, int)), this, TQT_SIGNAL(writeSpeed(int, int)) );
connect( d->writerJob, TQT_SIGNAL(finished(bool)), this, TQT_SLOT(slotWriterFinished(bool)) );