summaryrefslogtreecommitdiffstats
path: root/krec/krecord.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'krec/krecord.cpp')
-rw-r--r--krec/krecord.cpp72
1 files changed, 36 insertions, 36 deletions
diff --git a/krec/krecord.cpp b/krec/krecord.cpp
index 72fbde7c..3bd18c72 100644
--- a/krec/krecord.cpp
+++ b/krec/krecord.cpp
@@ -32,13 +32,13 @@
#include <kapplication.h>
#include <kaction.h>
#include <kconfig.h>
-#include <qlayout.h>
-#include <qtimer.h>
+#include <tqlayout.h>
+#include <tqtimer.h>
#include <ksettings/dialog.h>
#include <ktip.h>
KRecPrivate::KRecPrivate( KRecord* p, const char* n )
- : QObject( p,n )
+ : TQObject( p,n )
, _confdlg( 0 )
, server( new KArtsServer( 0 ) )
, dispatcher( new KArtsDispatcher( 0 ) )
@@ -99,7 +99,7 @@ void KRecPrivate::openFile() {
//kdDebug( 60005 ) << k_funcinfo << endl;
if ( _currentFile ) closeFile();
if ( !_currentFile ) {
- QString filename = KFileDialog::getOpenFileName( "", "*.krec", _impl );
+ TQString filename = KFileDialog::getOpenFileName( "", "*.krec", _impl );
//kdDebug( 60005 ) << k_funcinfo << filename << endl;
if ( !filename.isNull() )
pNewFile( new KRecFile( filename, this ) );
@@ -107,8 +107,8 @@ void KRecPrivate::openFile() {
}
void KRecPrivate::pNewFile( KRecFile* file ) {
_currentFile = file;
- connect( m_recStream, SIGNAL( data( QByteArray& ) ), _currentFile, SLOT( writeData( QByteArray& ) ) );
- connect( m_playStream, SIGNAL( requestData( QByteArray& ) ), _currentFile, SLOT( getData( QByteArray& ) ) );
+ connect( m_recStream, TQT_SIGNAL( data( TQByteArray& ) ), _currentFile, TQT_SLOT( writeData( TQByteArray& ) ) );
+ connect( m_playStream, TQT_SIGNAL( requestData( TQByteArray& ) ), _currentFile, TQT_SLOT( getData( TQByteArray& ) ) );
mainwidget->_fileview->setFile( _currentFile );
checkActions();
}
@@ -119,16 +119,16 @@ void KRecPrivate::saveFile() {
}
void KRecPrivate::saveAsFile() {
//kdDebug( 60005 ) << k_funcinfo << endl;
- if ( _currentFile ) pSaveFile( QString::null );
+ if ( _currentFile ) pSaveFile( TQString::null );
}
-void KRecPrivate::pSaveFile( const QString &filename ) {
+void KRecPrivate::pSaveFile( const TQString &filename ) {
if ( !_currentFile )
return;
if ( !filename.isNull() )
_currentFile->save( filename );
else {
- QString userFilename = KFileDialog::getSaveFileName( "", "*.krec", _impl, i18n( "Save File As" ) );
+ TQString userFilename = KFileDialog::getSaveFileName( "", "*.krec", _impl, i18n( "Save File As" ) );
if ( !userFilename.isNull() )
_currentFile->save( userFilename );
}
@@ -138,7 +138,7 @@ bool KRecPrivate::closeFile() {
//kdDebug( 60005 ) << k_funcinfo << endl;
if ( _currentFile ) {
if ( !_currentFile->saved() ) {
- int choice = KMessageBox::questionYesNoCancel( _impl, i18n( "The document \"%1\" has been modified.\nDo you want to save it?" ).arg( _currentFile->filename() ), QString::null, KStdGuiItem::save(), KStdGuiItem::discard() );
+ int choice = KMessageBox::questionYesNoCancel( _impl, i18n( "The document \"%1\" has been modified.\nDo you want to save it?" ).arg( _currentFile->filename() ), TQString::null, KStdGuiItem::save(), KStdGuiItem::discard() );
if ( choice == KMessageBox::Yes ) saveFile();
if ( choice == KMessageBox::Cancel ) return false;
// go on if KMessageBox::No
@@ -154,17 +154,17 @@ bool KRecPrivate::closeFile() {
void KRecPrivate::exportFile() {
kdDebug( 60005 ) << k_funcinfo << endl;
if ( _currentFile ) {
- QString filename = KFileDialog::getSaveFileName( "", KRecGlobal::the()->exportFormatEndings(), _impl, "Export File As" );
+ TQString filename = KFileDialog::getSaveFileName( "", KRecGlobal::the()->exportFormatEndings(), _impl, "Export File As" );
if ( !filename.isNull() ) {
int lastdot = filename.find( '.', -5 );
- QString ending = filename.right( filename.length()-lastdot-1 );
+ TQString ending = filename.right( filename.length()-lastdot-1 );
_exportitem = KRecGlobal::the()->getExportItemForEnding( ending );
if ( _exportitem ) {
_exportitem->initialize( _currentFile->samplerate(), _currentFile->bits(), _currentFile->channels() );
if ( _exportitem->initialize( filename ) ) {
- connect( _exportitem, SIGNAL( getData( QByteArray& ) ), _currentFile, SLOT( getData( QByteArray& ) ) );
- connect( _currentFile, SIGNAL( endReached() ), _exportitem, SLOT( stop() ) );
- connect( _currentFile, SIGNAL( endReached() ), this, SLOT( endExportFile() ) );
+ connect( _exportitem, TQT_SIGNAL( getData( TQByteArray& ) ), _currentFile, TQT_SLOT( getData( TQByteArray& ) ) );
+ connect( _currentFile, TQT_SIGNAL( endReached() ), _exportitem, TQT_SLOT( stop() ) );
+ connect( _currentFile, TQT_SIGNAL( endReached() ), this, TQT_SLOT( endExportFile() ) );
_exportitem->start();
}
} else
@@ -185,7 +185,7 @@ void KRecPrivate::exportFile() {
} else KRecGlobal::the()->message( i18n( "There is nothing to export." ) );
checkActions();
}
-void KRecPrivate::endExportFile() { QTimer::singleShot( 20, this, SLOT( endExportFile2() ) ); }
+void KRecPrivate::endExportFile() { TQTimer::singleShot( 20, this, TQT_SLOT( endExportFile2() ) ); }
void KRecPrivate::endExportFile2() {
_exportitem->finalize();
disconnect( _currentFile, 0, _exportitem, 0 );
@@ -248,7 +248,7 @@ void KRecPrivate::toEnd() {
}
void KRecPrivate::forceTipOfDay() {
- KTipDialog::showTip( _impl, QString::null, true );
+ KTipDialog::showTip( _impl, TQString::null, true );
}
void KRecPrivate::execaRtsControl() {
@@ -264,12 +264,12 @@ void KRecPrivate::execKMix() {
*/
-KRecord::KRecord(QWidget *parent, const char *name )
+KRecord::KRecord(TQWidget *parent, const char *name )
: KMainWindow(parent,name)
, d( new KRecPrivate( this ) )
{
kdDebug( 60005 ) << k_funcinfo << endl;
- //kdDebug( 60005 )<<"KRecord::KRecord( QWidget *"<<parent<<", const char* "<<name<<" )"<<endl; // (DEBUG)
+ //kdDebug( 60005 )<<"KRecord::KRecord( TQWidget *"<<parent<<", const char* "<<name<<" )"<<endl; // (DEBUG)
KRecGlobal::the()->setMainWidget( this );
KRecGlobal::the()->setStatusBar( statusBar() );
@@ -283,40 +283,40 @@ KRecord::KRecord(QWidget *parent, const char *name )
// * * * Actions * * *
d->artsactions = new ArtsActions( d->server, actionCollection(), this );
- KStdAction::preferences( d, SLOT( showConfDialog() ), actionCollection() );
+ KStdAction::preferences( d, TQT_SLOT( showConfDialog() ), actionCollection() );
- KStdAction::openNew( d, SLOT( newFile() ), actionCollection() );
- KStdAction::open( d, SLOT( openFile() ), actionCollection() );
- KStdAction::save( d, SLOT( saveFile() ), actionCollection() );
- KStdAction::saveAs( d, SLOT( saveAsFile() ), actionCollection() );
- KStdAction::close( d, SLOT( closeFile() ), actionCollection() );
- KStdAction::quit( this, SLOT( close() ), actionCollection() );
+ KStdAction::openNew( d, TQT_SLOT( newFile() ), actionCollection() );
+ KStdAction::open( d, TQT_SLOT( openFile() ), actionCollection() );
+ KStdAction::save( d, TQT_SLOT( saveFile() ), actionCollection() );
+ KStdAction::saveAs( d, TQT_SLOT( saveAsFile() ), actionCollection() );
+ KStdAction::close( d, TQT_SLOT( closeFile() ), actionCollection() );
+ KStdAction::quit( this, TQT_SLOT( close() ), actionCollection() );
- KStdAction::tipOfDay( d, SLOT( forceTipOfDay() ), actionCollection() );
+ KStdAction::tipOfDay( d, TQT_SLOT( forceTipOfDay() ), actionCollection() );
d->aExportFile = new KAction( i18n( "Export..." ), KShortcut(),
- d, SLOT( exportFile() ), actionCollection(), "export_file" );
+ d, TQT_SLOT( exportFile() ), actionCollection(), "export_file" );
d->aRecord = new KAction( i18n( "&Record" ), KShortcut( Key_R ),
- this, SLOT( startRec() ), actionCollection(), "player_record" );
+ this, TQT_SLOT( startRec() ), actionCollection(), "player_record" );
d->aPlay = new KAction( i18n( "&Play" ), KShortcut( Key_P ),
- this, SLOT( startPlay() ), actionCollection(), "player_play" );
+ this, TQT_SLOT( startPlay() ), actionCollection(), "player_play" );
d->aStop = new KAction( i18n( "&Stop" ), KShortcut( Key_S ),
- this, SLOT( stopRec() ), actionCollection(), "player_stop" );
+ this, TQT_SLOT( stopRec() ), actionCollection(), "player_stop" );
d->aThru = new KToggleAction( i18n( "Play Through" ), KShortcut( CTRL + Key_P), actionCollection(), "play_thru" );
- connect( d->aThru, SIGNAL( toggled( bool ) ), d, SLOT( playthru( bool ) ) );
+ connect( d->aThru, TQT_SIGNAL( toggled( bool ) ), d, TQT_SLOT( playthru( bool ) ) );
d->aBegin = new KAction( i18n( "Go to &Beginning" ), KShortcut( SHIFT + Key_Left ),
- d, SLOT( toBegin() ), actionCollection(), "player_gobegin" );
+ d, TQT_SLOT( toBegin() ), actionCollection(), "player_gobegin" );
d->aEnd = new KAction( i18n( "Go to &End" ), KShortcut( SHIFT + Key_Right ),
- d, SLOT( toEnd() ), actionCollection(), "player_goend" );
+ d, TQT_SLOT( toEnd() ), actionCollection(), "player_goend" );
( void* ) d->artsactions->actionAudioManager();
d->aExecaRtsControl = new KAction( i18n( "Start aRts Control Tool" ), KShortcut(),
- d, SLOT( execaRtsControl() ), actionCollection(), "exec_artscontrol" );
+ d, TQT_SLOT( execaRtsControl() ), actionCollection(), "exec_artscontrol" );
d->aExecKMix = new KAction( i18n( "Start KMix" ), KShortcut(),
- d, SLOT( execKMix() ), actionCollection(), "exec_kmix" );
+ d, TQT_SLOT( execKMix() ), actionCollection(), "exec_kmix" );
// * * * GUI * * *
// TODO Fix toolbar config so this line can just be setupGUI()