Rename KGlobal, KProcess, and KClipboard to avoid conflicts with KDE4

pull/1/head
Timothy Pearson 12 years ago
parent 7ab25fa204
commit 6ee2a113c8

@ -23,7 +23,7 @@ K9Mplayer::K9Mplayer(TQObject *parent,const char *name,const TQStringList args)
m_initVol=TRUE; m_initVol=TRUE;
m_title=0; m_title=0;
m_process=new KProcess(TQT_TQOBJECT(this)); m_process=new TDEProcess(TQT_TQOBJECT(this));
m_ratio=4.0/3.0; m_ratio=4.0/3.0;
slider->setRange(0, 100); slider->setRange(0, 100);
@ -31,9 +31,9 @@ K9Mplayer::K9Mplayer(TQObject *parent,const char *name,const TQStringList args)
bPlay->setPixmap(SmallIcon("player_play")); bPlay->setPixmap(SmallIcon("player_play"));
bStop->setPixmap(SmallIcon("player_stop")); bStop->setPixmap(SmallIcon("player_stop"));
bSwitchAudio->setPixmap(SmallIcon("cycle")); bSwitchAudio->setPixmap(SmallIcon("cycle"));
connect(m_process,TQT_SIGNAL(receivedStdout( KProcess*, char*, int )),this,TQT_SLOT(receivedStdout( KProcess*, char*, int ))); connect(m_process,TQT_SIGNAL(receivedStdout( TDEProcess*, char*, int )),this,TQT_SLOT(receivedStdout( TDEProcess*, char*, int )));
m_timer=new TQTimer(this); m_timer=new TQTimer(this);
connect(m_process,TQT_SIGNAL(wroteStdin( KProcess* )),this,TQT_SLOT(wroteStdin( KProcess* ))); connect(m_process,TQT_SIGNAL(wroteStdin( TDEProcess* )),this,TQT_SLOT(wroteStdin( TDEProcess* )));
connect(m_timer,TQT_SIGNAL(timeout()),this,TQT_SLOT(timeout())); connect(m_timer,TQT_SIGNAL(timeout()),this,TQT_SLOT(timeout()));
m_container=new TQWidget(Label); m_container=new TQWidget(Label);
} }
@ -55,7 +55,7 @@ void K9Mplayer::resizeEvent ( TQResizeEvent * _resizeEvent) {
} }
void K9Mplayer::wroteStdin( KProcess *_process) { void K9Mplayer::wroteStdin( TDEProcess *_process) {
m_canwrite = TRUE; m_canwrite = TRUE;
} }
@ -93,7 +93,7 @@ void K9Mplayer::setTitle( const TQString & _numTitle,const TQString &_numChapter
*m_process << "-chapter" << _numChapter; *m_process << "-chapter" << _numChapter;
*m_process << TQString("dvd://%1").arg(_numTitle); *m_process << TQString("dvd://%1").arg(_numTitle);
if (!m_process->start( KProcess::NotifyOnExit,KProcess::All)) { if (!m_process->start( TDEProcess::NotifyOnExit,TDEProcess::All)) {
KMessageBox::error (tqApp->mainWidget(),i18n("Unable to run %1").arg("mplayer") , i18n("Preview")); KMessageBox::error (tqApp->mainWidget(),i18n("Unable to run %1").arg("mplayer") , i18n("Preview"));
} }
m_canwrite=TRUE; m_canwrite=TRUE;
@ -107,7 +107,7 @@ void K9Mplayer::setTitle( const TQString & _numTitle,const TQString &_numChapter
/*$SPECIALIZATION$*/ /*$SPECIALIZATION$*/
void K9Mplayer::receivedStdout (KProcess *proc, char *buffer, int buflen) { void K9Mplayer::receivedStdout (TDEProcess *proc, char *buffer, int buflen) {
TQString buf = TQString::fromLatin1(buffer, buflen); TQString buf = TQString::fromLatin1(buffer, buflen);
sscanf(buf.latin1(),"ANS_PERCENT_POSITION=%d",&m_position); sscanf(buf.latin1(),"ANS_PERCENT_POSITION=%d",&m_position);
if (!m_seeking && m_position>0) { if (!m_seeking && m_position>0) {

@ -8,7 +8,7 @@
class k9DVD; class k9DVD;
class k9DVDTitle; class k9DVDTitle;
class KProcess; class TDEProcess;
class TQTimer; class TQTimer;
class TQResizeEvent; class TQResizeEvent;
@ -17,7 +17,7 @@ class K9Mplayer : public MPlayer
Q_OBJECT Q_OBJECT
private: private:
KProcess *m_process; TDEProcess *m_process;
bool m_seeking,m_initVol; bool m_seeking,m_initVol;
int m_title; int m_title;
k9DVDTitle *m_dvdTitle; k9DVDTitle *m_dvdTitle;
@ -38,8 +38,8 @@ public:
private slots: private slots:
void slotLengthChanged(); void slotLengthChanged();
void slotNewPosition(int _pos,const TQTime & _time); void slotNewPosition(int _pos,const TQTime & _time);
void receivedStdout (KProcess *proc, char *buffer, int buflen); void receivedStdout (TDEProcess *proc, char *buffer, int buflen);
void wroteStdin(KProcess *_process); void wroteStdin(TDEProcess *_process);
void timeout(); void timeout();
public slots: public slots:
/*$PUBLIC_SLOTS$*/ /*$PUBLIC_SLOTS$*/

@ -51,7 +51,7 @@ void k9NewDVD::execute() {
m_cancel=false; m_cancel=false;
m_error=""; m_error="";
m_config=new k9Config(); m_config=new k9Config();
// connect(m_process, TQT_SIGNAL(receivedStderr(KProcess *, char *, int)),this, TQT_SLOT(getStderr(KProcess *, char *, int) )); // connect(m_process, TQT_SIGNAL(receivedStderr(TDEProcess *, char *, int)),this, TQT_SLOT(getStderr(TDEProcess *, char *, int) ));
connect(&m_aviDecode,TQT_SIGNAL(drawFrame(TQImage*)),this,TQT_SLOT(drawImage(TQImage*))); connect(&m_aviDecode,TQT_SIGNAL(drawFrame(TQImage*)),this,TQT_SLOT(drawImage(TQImage*)));
k9Tools::clearOutput(m_workDir+"dvd"); k9Tools::clearOutput(m_workDir+"dvd");
@ -120,7 +120,7 @@ void k9NewDVD::createXML() {
m_processList->clear(); m_processList->clear();
k9Process *process=m_processList->addProcess(i18n("authoring")); k9Process *process=m_processList->addProcess(i18n("authoring"));
connect(process, TQT_SIGNAL(receivedStderr(KProcess *, char *, int)),this, TQT_SLOT(getStderr(KProcess *, char *, int) )); connect(process, TQT_SIGNAL(receivedStderr(TDEProcess *, char *, int)),this, TQT_SLOT(getStderr(TDEProcess *, char *, int) ));
*process << "dvdauthor" << "-x" << dvdAuthor; *process << "dvdauthor" << "-x" << dvdAuthor;
m_processList->execute(); m_processList->execute();
m_cancel=m_processList->getCancel(); m_cancel=m_processList->getCancel();
@ -250,7 +250,7 @@ void k9NewDVD::createMencoderCmd(TQString &_cmd,TQString &_chapters, k9AviFile *
TQTime t(0,0); TQTime t(0,0);
t.start(); t.start();
m_timers[process]=t; m_timers[process]=t;
connect(process, TQT_SIGNAL(receivedStdout(KProcess *, char *, int)),this, TQT_SLOT(getStdout(KProcess *, char *, int) )); connect(process, TQT_SIGNAL(receivedStdout(TDEProcess *, char *, int)),this, TQT_SLOT(getStdout(TDEProcess *, char *, int) ));
//m_progress->setTitle(i18n("Encoding file")); //m_progress->setTitle(i18n("Encoding file"));
//m_process->clearArguments(); //m_process->clearArguments();
*process << "mencoder" << "-oac" << "lavc" << "-ovc" << "lavc" << "-of" << "mpeg" <<"-afm" <<"libmad"; *process << "mencoder" << "-oac" << "lavc" << "-ovc" << "lavc" << "-of" << "mpeg" <<"-afm" <<"libmad";
@ -272,7 +272,7 @@ void k9NewDVD::createMencoderCmd(TQString &_cmd,TQString &_chapters, k9AviFile *
// m_aviDecode.close(); // m_aviDecode.close();
} }
void k9NewDVD::getStderr(KProcess *_process, char *_buffer, int _length) { void k9NewDVD::getStderr(TDEProcess *_process, char *_buffer, int _length) {
TQCString tmp(_buffer,_length); TQCString tmp(_buffer,_length);
m_stdout=tmp; m_stdout=tmp;
int pos; int pos;
@ -308,7 +308,7 @@ void k9NewDVD::getStderr(KProcess *_process, char *_buffer, int _length) {
} }
void k9NewDVD::getStdout(KProcess *_process, char *_buffer, int _length) { void k9NewDVD::getStdout(TDEProcess *_process, char *_buffer, int _length) {
k9Process *process=(k9Process*) _process; k9Process *process=(k9Process*) _process;
if (m_timers[process].elapsed() >500) { if (m_timers[process].elapsed() >500) {
TQCString tmp(_buffer,_length); TQCString tmp(_buffer,_length);

@ -86,8 +86,8 @@ private:
void createMencoderCmd ( TQString &_cmd,TQString &_chapters, k9AviFile *_aviFile ); void createMencoderCmd ( TQString &_cmd,TQString &_chapters, k9AviFile *_aviFile );
k9Config *m_config; k9Config *m_config;
protected slots: protected slots:
void getStdout ( KProcess *, char *, int ); void getStdout ( TDEProcess *, char *, int );
void getStderr ( KProcess *, char *, int ); void getStderr ( TDEProcess *, char *, int );
void drawImage ( TQImage * _image ); void drawImage ( TQImage * _image );
signals: signals:
void sigAddTitle(); void sigAddTitle();

@ -128,7 +128,7 @@ void k9CdDrives::scanDrives() {
} }
void k9CdDrives::eject(const TQString & device) { void k9CdDrives::eject(const TQString & device) {
KProcess *process =new KProcess(); TDEProcess *process =new TDEProcess();
if (k9Tools::checkProgram("kdeeject")) if (k9Tools::checkProgram("kdeeject"))
*process <<"kdeeject" << device; *process <<"kdeeject" << device;
else else

@ -38,7 +38,7 @@ k9BurnDVD::k9BurnDVD()
iso=false; iso=false;
m_filename=""; m_filename="";
progress=new k9Progress(NULL,"progress",NULL); progress=new k9Progress(NULL,"progress",NULL);
TQString s= KGlobal::dirs()->findResource( "data", "k9copy/anim.mng"); TQString s= TDEGlobal::dirs()->findResource( "data", "k9copy/anim.mng");
progress->setMovie(s); progress->setMovie(s);
m_cdrkit=k9Tools::checkProgram("genisoimage") && k9Tools::checkProgram("wodim"); m_cdrkit=k9Tools::checkProgram("genisoimage") && k9Tools::checkProgram("wodim");
} }
@ -90,7 +90,7 @@ void k9BurnDVD::burn() {
} }
void k9BurnDVD::burnWithK3b() { void k9BurnDVD::burnWithK3b() {
KProcess *k3b = new KProcess(); TDEProcess *k3b = new TDEProcess();
*k3b << "k3b"; *k3b << "k3b";
*k3b << TQDir::cleanDirPath(workDir +"/dvd/VIDEO_TS"); *k3b << TQDir::cleanDirPath(workDir +"/dvd/VIDEO_TS");
@ -100,13 +100,13 @@ void k9BurnDVD::burnWithK3b() {
delete k3b; delete k3b;
} }
void k9BurnDVD::mkisoSizeStderr(KProcess *proc, char *buffer, int buflen) { void k9BurnDVD::mkisoSizeStderr(TDEProcess *proc, char *buffer, int buflen) {
TQString c=TQString::fromLatin1( buffer,buflen);// (proc2->readStderr()); TQString c=TQString::fromLatin1( buffer,buflen);// (proc2->readStderr());
imageSize=c.replace("\n",""); imageSize=c.replace("\n","");
; ;
} }
void k9BurnDVD::mkisoSizeStdout(KProcess *proc, char *buffer, int buflen) { void k9BurnDVD::mkisoSizeStdout(TDEProcess *proc, char *buffer, int buflen) {
TQString c=TQString::fromLatin1(buffer,buflen);// (proc2->readStdout()); TQString c=TQString::fromLatin1(buffer,buflen);// (proc2->readStdout());
imageSize=c.replace("\n",""); imageSize=c.replace("\n","");
; ;
@ -125,9 +125,9 @@ const TQString k9BurnDVD::getImageSize() {
*proc2 <<"-V "+volId; *proc2 <<"-V "+volId;
*proc2 << TQDir::cleanDirPath(workDir +"/dvd"); *proc2 << TQDir::cleanDirPath(workDir +"/dvd");
connect( proc2, TQT_SIGNAL(receivedStderr(KProcess *, char *, int )),this, TQT_SLOT(mkisoSizeStderr(KProcess *, char *, int)) ); connect( proc2, TQT_SIGNAL(receivedStderr(TDEProcess *, char *, int )),this, TQT_SLOT(mkisoSizeStderr(TDEProcess *, char *, int)) );
connect( proc2, TQT_SIGNAL(receivedStdout(KProcess *, char *, int)),this, TQT_SLOT(mkisoSizeStdout(KProcess *, char *, int)) ); connect( proc2, TQT_SIGNAL(receivedStdout(TDEProcess *, char *, int)),this, TQT_SLOT(mkisoSizeStdout(TDEProcess *, char *, int)) );
if (proc2->start(KProcess::NotifyOnExit,KProcess::All)) { if (proc2->start(TDEProcess::NotifyOnExit,TDEProcess::All)) {
// while (proc2->isRunning()) { // while (proc2->isRunning()) {
// tqApp->processEvents(); // tqApp->processEvents();
// } // }
@ -158,12 +158,12 @@ void k9BurnDVD::getGenisoimageCmd(k9Process *proc,TQString _fileName,bool _print
*proc <<"-o"; *proc <<"-o";
*proc <<_fileName; *proc <<_fileName;
} }
connect( proc, TQT_SIGNAL(receivedStderr(KProcess *, char *, int)),this, TQT_SLOT(growisoStderr(KProcess *, char *, int)) ); connect( proc, TQT_SIGNAL(receivedStderr(TDEProcess *, char *, int)),this, TQT_SLOT(growisoStderr(TDEProcess *, char *, int)) );
connect( proc, TQT_SIGNAL(receivedStdout(KProcess *, char *, int)),this, TQT_SLOT(growisoStdout(KProcess *, char *, int)) ); connect( proc, TQT_SIGNAL(receivedStdout(TDEProcess *, char *, int)),this, TQT_SLOT(growisoStdout(TDEProcess *, char *, int)) );
} else { } else {
*proc << "-print-size" << "-quiet"; *proc << "-print-size" << "-quiet";
connect( proc, TQT_SIGNAL(receivedStderr(KProcess *, char *, int )),this, TQT_SLOT(mkisoSizeStderr(KProcess *, char *, int)) ); connect( proc, TQT_SIGNAL(receivedStderr(TDEProcess *, char *, int )),this, TQT_SLOT(mkisoSizeStderr(TDEProcess *, char *, int)) );
connect( proc, TQT_SIGNAL(receivedStdout(KProcess *, char *, int)),this, TQT_SLOT(mkisoSizeStdout(KProcess *, char *, int)) ); connect( proc, TQT_SIGNAL(receivedStdout(TDEProcess *, char *, int)),this, TQT_SLOT(mkisoSizeStdout(TDEProcess *, char *, int)) );
} }
*proc <<TQDir::cleanDirPath(workDir +"/dvd"); *proc <<TQDir::cleanDirPath(workDir +"/dvd");
@ -207,7 +207,7 @@ void k9BurnDVD::burnWithGenisoimage() {
if (!iso) { if (!iso) {
k9Process *proc2=new k9Process(NULL,NULL); k9Process *proc2=new k9Process(NULL,NULL);
getGenisoimageCmd(proc2,"",true); getGenisoimageCmd(proc2,"",true);
proc2->start(KProcess::NotifyOnExit,KProcess::All); proc2->start(TDEProcess::NotifyOnExit,TDEProcess::All);
proc2->sync(); proc2->sync();
getWodimCmd(proc); getWodimCmd(proc);
proc->setUseShell(true); proc->setUseShell(true);
@ -296,8 +296,8 @@ void k9BurnDVD::burnWithGrowisofs() {
*proc <<"-V "+volId; *proc <<"-V "+volId;
*proc <<TQDir::cleanDirPath(workDir +"/dvd"); *proc <<TQDir::cleanDirPath(workDir +"/dvd");
connect( proc, TQT_SIGNAL(receivedStderr(KProcess *, char *, int)),this, TQT_SLOT(growisoStderr(KProcess *, char *, int)) ); connect( proc, TQT_SIGNAL(receivedStderr(TDEProcess *, char *, int)),this, TQT_SLOT(growisoStderr(TDEProcess *, char *, int)) );
connect( proc, TQT_SIGNAL(receivedStdout(KProcess *, char *, int)),this, TQT_SLOT(growisoStdout(KProcess *, char *, int)) ); connect( proc, TQT_SIGNAL(receivedStdout(TDEProcess *, char *, int)),this, TQT_SLOT(growisoStdout(TDEProcess *, char *, int)) );
if (!autoBurn && !iso) { if (!autoBurn && !iso) {
c=i18n("Insert a recordable DVD"); c=i18n("Insert a recordable DVD");
if ( KMessageBox::warningContinueCancel ( 0,c, i18n("DVD burning"))!=KMessageBox::Continue) if ( KMessageBox::warningContinueCancel ( 0,c, i18n("DVD burning"))!=KMessageBox::Continue)
@ -330,7 +330,7 @@ void k9BurnDVD::burnWithGrowisofs() {
} }
/** No descriptions */ /** No descriptions */
void k9BurnDVD::growisoStderr(KProcess *proc, char *buffer, int buflen) { void k9BurnDVD::growisoStderr(TDEProcess *proc, char *buffer, int buflen) {
TQString c=TQString::fromLatin1( buffer,buflen);// (proc->readStderr()); TQString c=TQString::fromLatin1( buffer,buflen);// (proc->readStderr());
char s[255]; char s[255];
int a,b; int a,b;
@ -370,7 +370,7 @@ void k9BurnDVD::growisoStderr(KProcess *proc, char *buffer, int buflen) {
} }
} }
} }
void k9BurnDVD::growisoStdout(KProcess *proc, char *buffer, int buflen) { void k9BurnDVD::growisoStdout(TDEProcess *proc, char *buffer, int buflen) {
TQString c=TQString::fromLatin1( buffer,buflen);// (proc->readStdout()); TQString c=TQString::fromLatin1( buffer,buflen);// (proc->readStdout());
int pos; int pos;
pos=c.find("STAT"); pos=c.find("STAT");

@ -75,10 +75,10 @@ private:
TQString imageSize; TQString imageSize;
TQString m_speed; TQString m_speed;
private slots: // Private slots private slots: // Private slots
void growisoStderr(KProcess *proc, char *buffer, int buflen); void growisoStderr(TDEProcess *proc, char *buffer, int buflen);
void growisoStdout(KProcess *proc, char *buffer, int buflen); void growisoStdout(TDEProcess *proc, char *buffer, int buflen);
void mkisoSizeStderr(KProcess *proc, char *buffer, int buflen); void mkisoSizeStderr(TDEProcess *proc, char *buffer, int buflen);
void mkisoSizeStdout(KProcess *proc, char *buffer, int buflen); void mkisoSizeStdout(TDEProcess *proc, char *buffer, int buflen);
}; };
#endif #endif

@ -444,10 +444,10 @@ void k9DVDAuthor::author() {
TQString c("dvdauthor"); TQString c("dvdauthor");
proc=progress->getProcess();// new TQProcess(c,0); proc=progress->getProcess();// new TQProcess(c,0);
*proc << c << "-x" << m_xml->name(); //locateLocal("tmp", "k9copy/k9author.xml"); *proc << c << "-x" << m_xml->name(); //locateLocal("tmp", "k9copy/k9author.xml");
connect( proc, TQT_SIGNAL(receivedStderr(KProcess *, char *, int)), connect( proc, TQT_SIGNAL(receivedStderr(TDEProcess *, char *, int)),
this, TQT_SLOT(DVDAuthorStderr(KProcess *, char *, int )) ); this, TQT_SLOT(DVDAuthorStderr(TDEProcess *, char *, int )) );
connect( proc, TQT_SIGNAL(receivedStdout(KProcess *, char *, int )), connect( proc, TQT_SIGNAL(receivedStdout(TDEProcess *, char *, int )),
this, TQT_SLOT(DVDAuthorStdout(KProcess *, char *, int)) ); this, TQT_SLOT(DVDAuthorStdout(TDEProcess *, char *, int)) );
// connect(progress, TQT_SIGNAL(cancelled()), this, TQT_SLOT(stopProcess())); // connect(progress, TQT_SIGNAL(cancelled()), this, TQT_SLOT(stopProcess()));
m_copied=0; m_copied=0;
@ -488,7 +488,7 @@ void k9DVDAuthor::author() {
/** No descriptions */ /** No descriptions */
void k9DVDAuthor::DVDAuthorStderr(KProcess *proc, char *buffer, int buflen ) { void k9DVDAuthor::DVDAuthorStderr(TDEProcess *proc, char *buffer, int buflen ) {
//TQString m_stderr(proc->readStderr()); //TQString m_stderr(proc->readStderr());
TQString m_stderr=TQString::fromLatin1(buffer, buflen); TQString m_stderr=TQString::fromLatin1(buffer, buflen);
@ -557,7 +557,7 @@ void k9DVDAuthor::DVDAuthorStderr(KProcess *proc, char *buffer, int buflen ) {
} }
void k9DVDAuthor::DVDAuthorStdout(KProcess *proc, char *buffer, int buflen) { void k9DVDAuthor::DVDAuthorStdout(TDEProcess *proc, char *buffer, int buflen) {
TQString c=TQString::fromLatin1( buffer,buflen); TQString c=TQString::fromLatin1( buffer,buflen);
//(proc->readStdout()); //(proc->readStdout());
int pos; int pos;

@ -75,8 +75,8 @@ private: // Private attributes
void spumux(); void spumux();
private slots: // Private slots private slots: // Private slots
/** No descriptions */ /** No descriptions */
void DVDAuthorStderr(KProcess *proc, char *buffer, int buflen); void DVDAuthorStderr(TDEProcess *proc, char *buffer, int buflen);
void DVDAuthorStdout(KProcess *proc, char *buffer, int buflen); void DVDAuthorStdout(TDEProcess *proc, char *buffer, int buflen);
/** No descriptions */ /** No descriptions */
void stopProcess(); void stopProcess();

@ -395,13 +395,13 @@ void k9MP4Enc::execute ( k9DVDTitle *_title )
tqDebug ( "%s", s.ascii() ); tqDebug ( "%s", s.ascii() );
time->start(); time->start();
m_timer3.start(); m_timer3.start();
connect ( m_process, TQT_SIGNAL ( receivedStdout ( KProcess *, char *, int ) ),this, TQT_SLOT ( getStdout ( KProcess *, char *, int ) ) ); connect ( m_process, TQT_SIGNAL ( receivedStdout ( TDEProcess *, char *, int ) ),this, TQT_SLOT ( getStdout ( TDEProcess *, char *, int ) ) );
connect ( m_process, TQT_SIGNAL ( receivedStderr ( KProcess *, char *, int ) ),this, TQT_SLOT ( getStderr ( KProcess *, char *, int ) ) ); connect ( m_process, TQT_SIGNAL ( receivedStderr ( TDEProcess *, char *, int ) ),this, TQT_SLOT ( getStderr ( TDEProcess *, char *, int ) ) );
//connect(m_process, TQT_SIGNAL(processExited(KProcess*)),this,TQT_SLOT(exited(KProcess*))); //connect(m_process, TQT_SIGNAL(processExited(TDEProcess*)),this,TQT_SLOT(exited(TDEProcess*)));
connect ( m_progress,TQT_SIGNAL ( sigCancel() ),this,TQT_SLOT ( slotCancel() ) ); connect ( m_progress,TQT_SIGNAL ( sigCancel() ),this,TQT_SLOT ( slotCancel() ) );
m_canceled=false; m_canceled=false;
m_progress->show(); m_progress->show();
m_process->start ( KProcess::OwnGroup, KProcess::All ); m_process->start ( TDEProcess::OwnGroup, TDEProcess::All );
timer->start ( 500, 0 ); timer->start ( 500, 0 );
m_process->sync(); m_process->sync();
//if application is exiting, kill the encoding process //if application is exiting, kill the encoding process
@ -473,7 +473,7 @@ int k9MP4Enc::getBitRate ( k9DVDTitle *_title )
} }
void k9MP4Enc::getStdout ( KProcess *, char *buffer, int buflen ) void k9MP4Enc::getStdout ( TDEProcess *, char *buffer, int buflen )
{ {
TQCString tmp ( buffer,buflen ); TQCString tmp ( buffer,buflen );
m_cpt++; m_cpt++;
@ -501,7 +501,7 @@ void k9MP4Enc::getStdout ( KProcess *, char *buffer, int buflen )
} }
void k9MP4Enc::getStderr ( KProcess *proc, char *buffer, int buflen ) void k9MP4Enc::getStderr ( TDEProcess *proc, char *buffer, int buflen )
{ {
//m_stderr=TQString::fromLatin1(buffer,buflen); //m_stderr=TQString::fromLatin1(buffer,buflen);
TQCString cstderr ( buffer,buflen+1 ); TQCString cstderr ( buffer,buflen+1 );

@ -64,8 +64,8 @@ private:
int getselectedSubp(k9DVDTitle *_title); int getselectedSubp(k9DVDTitle *_title);
private slots: private slots:
void getStdout(KProcess *proc, char *buffer, int buflen); void getStdout(TDEProcess *proc, char *buffer, int buflen);
void getStderr(KProcess *proc, char *buffer, int buflen); void getStderr(TDEProcess *proc, char *buffer, int buflen);
void timerDone(); void timerDone();
void slotCancel(); void slotCancel();

@ -15,9 +15,9 @@
#include <tqeventloop.h> #include <tqeventloop.h>
k9Process::k9Process(TQObject *parent, const char *name) k9Process::k9Process(TQObject *parent, const char *name)
: KProcess(parent, name),m_waitSync(false) : TDEProcess(parent, name),m_waitSync(false)
{ {
connect(this,TQT_SIGNAL(processExited( KProcess* )),this,TQT_SLOT(slotProcessExited( KProcess* ))); connect(this,TQT_SIGNAL(processExited( TDEProcess* )),this,TQT_SLOT(slotProcessExited( TDEProcess* )));
} }
@ -32,7 +32,7 @@ void k9Process::sync() {
} }
void k9Process::slotProcessExited( KProcess * proc) { void k9Process::slotProcessExited( TDEProcess * proc) {
if (m_waitSync) { if (m_waitSync) {
TQApplication::eventLoop()->exitLoop(); TQApplication::eventLoop()->exitLoop();
m_waitSync=false; m_waitSync=false;
@ -49,7 +49,7 @@ const TQString & k9Process::debug() {
bool k9Process::start (RunMode runmode, Communication comm) { bool k9Process::start (RunMode runmode, Communication comm) {
m_elapsed.start(); m_elapsed.start();
return KProcess::start(runmode,comm); return TDEProcess::start(runmode,comm);
} }
#include "k9process.moc" #include "k9process.moc"

@ -17,7 +17,7 @@
/** /**
@author Jean-Michel PETIT <k9copy@free.fr> @author Jean-Michel PETIT <k9copy@free.fr>
*/ */
class k9Process : public KProcess class k9Process : public TDEProcess
{ {
Q_OBJECT Q_OBJECT
@ -33,7 +33,7 @@ private:
TQString m_debug; TQString m_debug;
TQTime m_elapsed; TQTime m_elapsed;
private slots: private slots:
void slotProcessExited(KProcess *proc); void slotProcessExited(TDEProcess *proc);
}; };
#endif #endif

@ -103,7 +103,7 @@ void k9ProcessList::execute() {
} }
if (m_cancel) if (m_cancel)
break; break;
if (!p->start(KProcess::OwnGroup,KProcess::All)) if (!p->start(TDEProcess::OwnGroup,TDEProcess::All))
m_error=true; m_error=true;
} }
//waiting for processes //waiting for processes
@ -153,11 +153,11 @@ k9Process *k9ProcessList::addProcess(const TQString &label) {
TQListViewItem *item = new _k9ProcessListItem(lProcess,label); TQListViewItem *item = new _k9ProcessListItem(lProcess,label);
m_items[process]=item; m_items[process]=item;
setProgress(process,0,100); setProgress(process,0,100);
connect(process,TQT_SIGNAL(processExited( KProcess* )),this,TQT_SLOT(processExited(KProcess*))); connect(process,TQT_SIGNAL(processExited( TDEProcess* )),this,TQT_SLOT(processExited(TDEProcess*)));
return process; return process;
} }
void k9ProcessList::processExited(KProcess *_process){ void k9ProcessList::processExited(TDEProcess *_process){
if (!_process->normalExit()) if (!_process->normalExit())
m_cancel=true; m_cancel=true;
else if (_process->exitStatus() !=0 ) else if (_process->exitStatus() !=0 )

@ -59,7 +59,7 @@ protected slots:
/*$PROTECTED_SLOTS$*/ /*$PROTECTED_SLOTS$*/
void timeout(); void timeout();
virtual void bCancelClick(); virtual void bCancelClick();
virtual void processExited(KProcess *); virtual void processExited(TDEProcess *);
}; };
#endif #endif

@ -60,7 +60,7 @@ void k9Progress::setProgress(long _position,long _total) {
int k9Progress::execute() { int k9Progress::execute() {
if (! m_process->isRunning()) { if (! m_process->isRunning()) {
if (!m_process->start(KProcess::NotifyOnExit,KProcess::All )) if (!m_process->start(TDEProcess::NotifyOnExit,TDEProcess::All ))
return -1; return -1;
} }

@ -351,7 +351,7 @@ void k9Copy::optionsConfigureKeys() {
void k9Copy::optionsConfigureToolbars() { void k9Copy::optionsConfigureToolbars() {
// use the standard toolbar editor // use the standard toolbar editor
saveMainWindowSettings(KGlobal::config(), autoSaveGroup()); saveMainWindowSettings(TDEGlobal::config(), autoSaveGroup());
KEditToolbar dlg(factory()); KEditToolbar dlg(factory());
connect(&dlg,TQT_SIGNAL(newToolbarConfig()),this,TQT_SLOT(newToolbarConfig())); connect(&dlg,TQT_SIGNAL(newToolbarConfig()),this,TQT_SLOT(newToolbarConfig()));
dlg.exec(); dlg.exec();
@ -362,7 +362,7 @@ void k9Copy::newToolbarConfig() {
// recreate our GUI, and re-apply the settings (e.g. "text under icons", etc.) // recreate our GUI, and re-apply the settings (e.g. "text under icons", etc.)
createGUI(0); createGUI(0);
applyMainWindowSettings(KGlobal::config(), autoSaveGroup()); applyMainWindowSettings(TDEGlobal::config(), autoSaveGroup());
} }
void k9Copy::fileOpen() { void k9Copy::fileOpen() {

@ -136,7 +136,7 @@ void k9MencoderCmdGen::listViewCurrentChanged(TQListViewItem *_item) {
} }
void k9MencoderCmdGen::loadXml() { void k9MencoderCmdGen::loadXml() {
TQFile file(KGlobal::dirs()->findResource( "data", "k9copy/mencoder.xml")); TQFile file(TDEGlobal::dirs()->findResource( "data", "k9copy/mencoder.xml"));
if ( !file.open( IO_ReadOnly ) ) if ( !file.open( IO_ReadOnly ) )
return; return;
if ( !m_doc.setContent( &file ) ) { if ( !m_doc.setContent( &file ) ) {

@ -21,11 +21,11 @@ k9Redirect::~k9Redirect()
} }
void k9Redirect::execute() { void k9Redirect::execute() {
KProcess *p=new KProcess(); TDEProcess *p=new TDEProcess();
*p << "mencoder"; *p << "mencoder";
*p << "-oac" << "lavc" << "-ovc" << "lavc" << "-of" << "mpeg"; *p << "-oac" << "lavc" << "-ovc" << "lavc" << "-of" << "mpeg";
*p << "-mpegopts" << "format=dvd" << "-vf" << "scale=720:576,harddup" << "-srate" << "48000" << "-af" << "lavcresample=48000" << "-lavcopts" << "vcodec=mpeg2video:vrc_buf_size=1835:vrc_maxrate=9800:vbitrate=5000:keyint=15:acodec=ac3:abitrate=192:aspect=16/9" << "-ofps" << "25" << "-o" << "/tmp/tde-jmp/k9copy/tmp.mpeg" << "-ss" << "00:00:00.000" << "-endpos" << "00:00:57.360" << "-really-quiet" << "/home/jmp/t.avi"; *p << "-mpegopts" << "format=dvd" << "-vf" << "scale=720:576,harddup" << "-srate" << "48000" << "-af" << "lavcresample=48000" << "-lavcopts" << "vcodec=mpeg2video:vrc_buf_size=1835:vrc_maxrate=9800:vbitrate=5000:keyint=15:acodec=ac3:abitrate=192:aspect=16/9" << "-ofps" << "25" << "-o" << "/tmp/tde-jmp/k9copy/tmp.mpeg" << "-ss" << "00:00:00.000" << "-endpos" << "00:00:57.360" << "-really-quiet" << "/home/jmp/t.avi";
p->start(KProcess::NotifyOnExit); p->start(TDEProcess::NotifyOnExit);
p->wait(); p->wait();

@ -24,14 +24,14 @@ k9settings::k9settings(TQWidget *parent,const TQString &caption): KDialogBase (
setInitialSize(TQSize(750,350), false); setInitialSize(TQSize(750,350), false);
TQFrame *frDevices; TQFrame *frDevices;
frDevices=addPage (i18n("Devices"),i18n("Devices not detected by k9copy"),KGlobal::iconLoader()->loadIcon("blockdevice", KIcon::Panel, KIcon::SizeMedium)); frDevices=addPage (i18n("Devices"),i18n("Devices not detected by k9copy"),TDEGlobal::iconLoader()->loadIcon("blockdevice", KIcon::Panel, KIcon::SizeMedium));
TQGridLayout *grid = new TQGridLayout(frDevices, 0, 0, 10 ); TQGridLayout *grid = new TQGridLayout(frDevices, 0, 0, 10 );
m_configDlg=new kConfigDlg(frDevices); m_configDlg=new kConfigDlg(frDevices);
grid->addWidget(m_configDlg,0,0); grid->addWidget(m_configDlg,0,0);
TQFrame *frDVD; TQFrame *frDVD;
frDVD=addPage (i18n("DVD"),i18n("DVD Backup"),KGlobal::iconLoader()->loadIcon("dvdcopy", KIcon::Panel, KIcon::SizeMedium)); frDVD=addPage (i18n("DVD"),i18n("DVD Backup"),TDEGlobal::iconLoader()->loadIcon("dvdcopy", KIcon::Panel, KIcon::SizeMedium));
grid = new TQGridLayout(frDVD, 0, 0, 10 ); grid = new TQGridLayout(frDVD, 0, 0, 10 );
m_prefDVD =new k9prefDVD(frDVD); m_prefDVD =new k9prefDVD(frDVD);
grid->addWidget(m_prefDVD,0,0); grid->addWidget(m_prefDVD,0,0);
@ -39,13 +39,13 @@ k9settings::k9settings(TQWidget *parent,const TQString &caption): KDialogBase (
//TODO afficher uniquement si mencoder et mplayer installés //TODO afficher uniquement si mencoder et mplayer installés
TQFrame *frMencoder; TQFrame *frMencoder;
frMencoder=addPage (i18n("MEncoder"),i18n("MPEG-4 Codecs"),KGlobal::iconLoader()->loadIcon("mencoder", KIcon::Panel, KIcon::SizeMedium)); frMencoder=addPage (i18n("MEncoder"),i18n("MPEG-4 Codecs"),TDEGlobal::iconLoader()->loadIcon("mencoder", KIcon::Panel, KIcon::SizeMedium));
m_prefMencoder =new k9prefMencoder(frMencoder); m_prefMencoder =new k9prefMencoder(frMencoder);
TQFrame *frMPEG4; TQFrame *frMPEG4;
frMPEG4=addPage (i18n("MPEG-4"),i18n("MPEG-4 Encoding"),KGlobal::iconLoader()->loadIcon("mp4", KIcon::Panel, KIcon::SizeMedium)); frMPEG4=addPage (i18n("MPEG-4"),i18n("MPEG-4 Encoding"),TDEGlobal::iconLoader()->loadIcon("mp4", KIcon::Panel, KIcon::SizeMedium));
grid = new TQGridLayout(frMPEG4, 0, 0, 10 ); grid = new TQGridLayout(frMPEG4, 0, 0, 10 );
m_prefMPEG4 =new k9prefMPEG4(frMPEG4); m_prefMPEG4 =new k9prefMPEG4(frMPEG4);
grid->addWidget(m_prefMPEG4,0,0); grid->addWidget(m_prefMPEG4,0,0);
@ -54,13 +54,13 @@ k9settings::k9settings(TQWidget *parent,const TQString &caption): KDialogBase (
grid->addWidget(m_prefMencoder,0,0); grid->addWidget(m_prefMencoder,0,0);
TQFrame *frPreview; TQFrame *frPreview;
frPreview=addPage (i18n("Preview"),i18n("Title preview"),KGlobal::iconLoader()->loadIcon("mplayer", KIcon::Panel, KIcon::SizeMedium)); frPreview=addPage (i18n("Preview"),i18n("Title preview"),TDEGlobal::iconLoader()->loadIcon("mplayer", KIcon::Panel, KIcon::SizeMedium));
grid = new TQGridLayout(frPreview, 0, 0, 10 ); grid = new TQGridLayout(frPreview, 0, 0, 10 );
m_prefPreview =new k9prefPreview(frPreview); m_prefPreview =new k9prefPreview(frPreview);
grid->addWidget(m_prefPreview,0,0); grid->addWidget(m_prefPreview,0,0);
TQFrame *frAuthor; TQFrame *frAuthor;
frAuthor=addPage(i18n("Authoring"),i18n("Authoring"),KGlobal::iconLoader()->loadIcon("author",KIcon::Panel,KIcon::SizeMedium)); frAuthor=addPage(i18n("Authoring"),i18n("Authoring"),TDEGlobal::iconLoader()->loadIcon("author",KIcon::Panel,KIcon::SizeMedium));
grid = new TQGridLayout(frAuthor, 0, 0, 10 ); grid = new TQGridLayout(frAuthor, 0, 0, 10 );
m_prefAuthor =new k9prefAuthor(frAuthor); m_prefAuthor =new k9prefAuthor(frAuthor);
grid->addWidget(m_prefAuthor,0,0); grid->addWidget(m_prefAuthor,0,0);

Loading…
Cancel
Save