Use tdeApp

Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
master
Michele Calgaro 1 month ago
parent 3af7b2c3ed
commit 8ac5ca6df7
Signed by: MicheleC
GPG Key ID: 2A75B7CA8ADED5CF

@ -202,15 +202,15 @@ void ProgressDialog::done( int errors, int successfull, bool allowundo )
buttonUndo->setEnabled( true ); buttonUndo->setEnabled( true );
buttonCancel->setEnabled( false ); buttonCancel->setEnabled( false );
kapp->processEvents( 0 ); tdeApp->processEvents( 0 );
} }
void ProgressDialog::show() void ProgressDialog::show()
{ {
TQWidget::show(); TQWidget::show();
int w = kapp->desktop()->width(); int w = tdeApp->desktop()->width();
int h = kapp->desktop()->height(); int h = tdeApp->desktop()->height();
move( (w-width())/2,(h-height())/2 ); move( (w-width())/2,(h-height())/2 );
} }
@ -348,7 +348,7 @@ void ProgressDialog::undo()
void ProgressDialog::slotTimer() void ProgressDialog::slotTimer()
{ {
kapp->processEvents( 0 ); tdeApp->processEvents( 0 );
} }
#include "ProgressDialog.moc" #include "ProgressDialog.moc"

@ -97,7 +97,7 @@ void CommandPlugin::drawInterface( TQWidget* w, TQVBoxLayout* l )
connect( buttonRemove, TQ_SIGNAL( clicked() ), this, TQ_SLOT( remove() ) ); connect( buttonRemove, TQ_SIGNAL( clicked() ), this, TQ_SLOT( remove() ) );
connect( list, TQ_SIGNAL( executed( TQListBoxItem* ) ), this, TQ_SLOT( exec() ) ); connect( list, TQ_SIGNAL( executed( TQListBoxItem* ) ), this, TQ_SLOT( exec() ) );
TDEConfig* conf = kapp->config(); TDEConfig* conf = tdeApp->config();
conf->setGroup("CommandPlugin"); conf->setGroup("CommandPlugin");
list->insertStringList( conf->readListEntry("commandlines" ) ); list->insertStringList( conf->readListEntry("commandlines" ) );
@ -144,7 +144,7 @@ TQString CommandPlugin::processFile( BatchRenamer* b, int i, TQString, int )
void CommandPlugin::finished() void CommandPlugin::finished()
{ {
TDEConfig* conf = kapp->config(); TDEConfig* conf = tdeApp->config();
conf->setGroup("CommandPlugin"); conf->setGroup("CommandPlugin");
TQStringList slist; TQStringList slist;
for( unsigned int i = 0; i < list->count(); i++ ) for( unsigned int i = 0; i < list->count(); i++ )
@ -186,7 +186,7 @@ void CommandPlugin::exec()
const TQPixmap CommandPlugin::getIcon() const const TQPixmap CommandPlugin::getIcon() const
{ {
return kapp->iconLoader()->loadIcon( "konsole", TDEIcon::Small ); return tdeApp->iconLoader()->loadIcon( "konsole", TDEIcon::Small );
} }
#include "commandplugin.moc" #include "commandplugin.moc"

@ -61,7 +61,7 @@ bool MyDatePlugin::checkError()
const TQPixmap MyDatePlugin::getIcon() const const TQPixmap MyDatePlugin::getIcon() const
{ {
return kapp->iconLoader()->loadIcon( "kalarm", TDEIcon::Small ); return tdeApp->iconLoader()->loadIcon( "kalarm", TDEIcon::Small );
} }
void MyDatePlugin::drawInterface( TQWidget* w, TQVBoxLayout* l ) void MyDatePlugin::drawInterface( TQWidget* w, TQVBoxLayout* l )

@ -122,7 +122,7 @@ void EncodingPlugin::finished()
const TQPixmap EncodingPlugin::getIcon() const const TQPixmap EncodingPlugin::getIcon() const
{ {
return kapp->iconLoader()->loadIcon( "fonts", TDEIcon::Small ); return tdeApp->iconLoader()->loadIcon( "fonts", TDEIcon::Small );
} }
void EncodingPlugin::enableControls() void EncodingPlugin::enableControls()

@ -86,7 +86,7 @@ bool FileOperation::start( const KURL & src, const KURL & dest, int mode, bool o
connect( job, TQ_SIGNAL( result (TDEIO::Job *) ), connect( job, TQ_SIGNAL( result (TDEIO::Job *) ),
this, TQ_SLOT( slotResult (TDEIO::Job *) ) ); this, TQ_SLOT( slotResult (TDEIO::Job *) ) );
kapp->eventLoop()->enterLoop(); tdeApp->eventLoop()->enterLoop();
return !result; return !result;
} }
@ -107,7 +107,7 @@ void FileOperation::slotResult( TDEIO::Job * job )
if( result ) if( result )
m_error = job->errorString(); m_error = job->errorString();
kapp->eventLoop()->exitLoop(); tdeApp->eventLoop()->exitLoop();
} }
#include "fileoperation.moc" #include "fileoperation.moc"

@ -129,7 +129,7 @@ void FilePlugin::drawInterface( TQWidget* w, TQVBoxLayout* l )
TQHBoxLayout* hbox = new TQHBoxLayout( 0, 6, 6 ); TQHBoxLayout* hbox = new TQHBoxLayout( 0, 6, 6 );
TQLabel* pix = new TQLabel( w ); TQLabel* pix = new TQLabel( w );
pix->setPixmap( kapp->iconLoader()->loadIcon( m_icon, TDEIcon::Desktop ) ); pix->setPixmap( tdeApp->iconLoader()->loadIcon( m_icon, TDEIcon::Desktop ) );
hbox->addWidget( pix ); hbox->addWidget( pix );
hbox->addWidget( new TQLabel( "<qt><b>"+getName()+"</b></qt>", w ) ); hbox->addWidget( new TQLabel( "<qt><b>"+getName()+"</b></qt>", w ) );
@ -175,7 +175,7 @@ TQString FilePlugin::processFile( BatchRenamer* b, int i, TQString token, int )
cache.remove( cache.begin() ); cache.remove( cache.begin() );
cache.insert( filename + "::" + token, ret ); cache.insert( filename + "::" + token, ret );
kapp->processEvents(); tdeApp->processEvents();
return ret; return ret;
} }
} }
@ -195,7 +195,7 @@ void FilePlugin::addHelp( HelpDialogData* data )
const TQPixmap FilePlugin::getIcon() const const TQPixmap FilePlugin::getIcon() const
{ {
return kapp->iconLoader()->loadIcon( m_icon, TDEIcon::Small ); return tdeApp->iconLoader()->loadIcon( m_icon, TDEIcon::Small );
} }
bool FilePlugin::supports( const TQString & token ) bool FilePlugin::supports( const TQString & token )

@ -41,7 +41,7 @@ KMyHistoryCombo::KMyHistoryCombo( bool customPopup, TQWidget* parent, const char
{ {
TQStringList history; TQStringList history;
TQStringList completion; TQStringList completion;
TDEConfig* config = kapp->config(); TDEConfig* config = tdeApp->config();
config->setGroup( name ); config->setGroup( name );
this->setDuplicatesEnabled( false ); this->setDuplicatesEnabled( false );
@ -71,7 +71,7 @@ void KMyHistoryCombo::saveSettings()
{ {
addToHistory( text() ); addToHistory( text() );
TDEConfig* config = kapp->config(); TDEConfig* config = tdeApp->config();
config->setGroup( name() ? name() : "KMyHistoryCombo" ); config->setGroup( name() ? name() : "KMyHistoryCombo" );
config->writeEntry( "History", historyItems() ); config->writeEntry( "History", historyItems() );

@ -102,7 +102,7 @@ KRenameImpl::KRenameImpl( TQWidget* p, KMenuBar* m, TQPushButton* finish )
m_switching = false; m_switching = false;
kapp->dcopClient()->registerAs( kapp->name() ); tdeApp->dcopClient()->registerAs( tdeApp->name() );
} }
@ -157,7 +157,7 @@ void KRenameImpl::setup( bool wizardmode )
connect( preview, TQ_SIGNAL( removeItem(int) ), this, TQ_SLOT( removeFile(int) )); connect( preview, TQ_SIGNAL( removeItem(int) ), this, TQ_SLOT( removeFile(int) ));
connect( preview, TQ_SIGNAL( addFile() ), this, TQ_SLOT( addFile() )); connect( preview, TQ_SIGNAL( addFile() ), this, TQ_SLOT( addFile() ));
connect( undorequester, TQ_SIGNAL( urlSelected(const TQString &)), this, TQ_SLOT( changeUndoScriptName() )); connect( undorequester, TQ_SIGNAL( urlSelected(const TQString &)), this, TQ_SLOT( changeUndoScriptName() ));
connect( kapp, TQ_SIGNAL( aboutToQuit() ), this, TQ_SLOT( saveConfig() ) ); connect( tdeApp, TQ_SIGNAL( aboutToQuit() ), this, TQ_SLOT( saveConfig() ) );
connect( buttonMove, TQ_SIGNAL( clicked()), fileList, TQ_SLOT( moveMode() )); connect( buttonMove, TQ_SIGNAL( clicked()), fileList, TQ_SLOT( moveMode() ));
connect( checkName, TQ_SIGNAL( clicked()), this, TQ_SLOT( toggleName() )); connect( checkName, TQ_SIGNAL( clicked()), this, TQ_SLOT( toggleName() ));
connect( buttonNumber, TQ_SIGNAL( clicked()), this, TQ_SLOT( changeNumbers() )); connect( buttonNumber, TQ_SIGNAL( clicked()), this, TQ_SLOT( changeNumbers() ));
@ -283,7 +283,7 @@ void KRenameImpl::parseCommandline()
// so let's wait for file adding to finish first // so let's wait for file adding to finish first
// before starting. // before starting.
while( fileList->runningAddListeners() > 0 ) while( fileList->runningAddListeners() > 0 )
kapp->processEvents(); tdeApp->processEvents();
if( fileList->count() ) if( fileList->count() )
// start renaming // start renaming
@ -987,7 +987,7 @@ void KRenameImpl::removeFile( int index )
void KRenameImpl::help() void KRenameImpl::help()
{ {
kapp->invokeHelp(); tdeApp->invokeHelp();
} }
void KRenameImpl::start() void KRenameImpl::start()
@ -1011,7 +1011,7 @@ void KRenameImpl::start()
filename->saveSettings(); filename->saveSettings();
extemplate->saveSettings(); extemplate->saveSettings();
TDEConfig * config = kapp->config(); TDEConfig * config = tdeApp->config();
config->setGroup("FileExtension"); config->setGroup("FileExtension");
config->writeEntry("FileExtensionCombo", comboExtension->currentItem() ); config->writeEntry("FileExtensionCombo", comboExtension->currentItem() );
@ -1258,7 +1258,7 @@ void KRenameImpl::updatePreview()
void KRenameImpl::loadConfig() void KRenameImpl::loadConfig()
{ {
TDEConfig* config = kapp->config(); TDEConfig* config = tdeApp->config();
config->setGroup("HistSize"); config->setGroup("HistSize");
m_hist = config->readNumEntry("HistoryItems", 10 ); m_hist = config->readNumEntry("HistoryItems", 10 );
@ -1324,7 +1324,7 @@ void KRenameImpl::loadConfig()
void KRenameImpl::saveConfig() void KRenameImpl::saveConfig()
{ {
TDEConfig* config = kapp->config(); TDEConfig* config = tdeApp->config();
config->setGroup("HistSize"); config->setGroup("HistSize");
config->writeEntry("HistoryItems", m_hist ); config->writeEntry("HistoryItems", m_hist );
@ -1610,7 +1610,7 @@ void KRenameImpl::changeNumbers()
void KRenameImpl::about() void KRenameImpl::about()
{ {
TDEAboutApplication * d = new TDEAboutApplication( kapp->aboutData(), parent ); TDEAboutApplication * d = new TDEAboutApplication( tdeApp->aboutData(), parent );
d->show(); d->show();
} }
@ -1663,7 +1663,7 @@ void KRenameImpl::changeParent( TQWidget* p, KMenuBar* m, TQPushButton* finish,
TQWidget* KRenameImpl::launch( TQRect rect, const KURL::List & list, KRenameImpl* impl, bool loadprofile ) TQWidget* KRenameImpl::launch( TQRect rect, const KURL::List & list, KRenameImpl* impl, bool loadprofile )
{ {
TDEConfig* config = kapp->config(); TDEConfig* config = tdeApp->config();
config->setGroup("GUISettings"); config->setGroup("GUISettings");
bool firststart = config->readBoolEntry( "firststart", true ); bool firststart = config->readBoolEntry( "firststart", true );
bool wizardmode = config->readBoolEntry( "GUIWizardMode", false ); bool wizardmode = config->readBoolEntry( "GUIWizardMode", false );
@ -1693,7 +1693,7 @@ TQWidget* KRenameImpl::launch( TQRect rect, const KURL::List & list, KRenameImpl
w = (TQWidget*)krename; w = (TQWidget*)krename;
} }
kapp->setMainWidget( w ); tdeApp->setMainWidget( w );
for( unsigned int i = 0; i < list.count(); i++ ) for( unsigned int i = 0; i < list.count(); i++ )
k->addFileOrDir( list[i] ); k->addFileOrDir( list[i] );

@ -54,7 +54,7 @@ bool MyDirPlugin::checkError()
const TQPixmap MyDirPlugin::getIcon() const const TQPixmap MyDirPlugin::getIcon() const
{ {
return kapp->iconLoader()->loadIcon( "folder", TDEIcon::Small ); return tdeApp->iconLoader()->loadIcon( "folder", TDEIcon::Small );
} }
void MyDirPlugin::drawInterface( TQWidget* w, TQVBoxLayout* l ) void MyDirPlugin::drawInterface( TQWidget* w, TQVBoxLayout* l )

@ -323,7 +323,7 @@ void MyPermPlugin::enableControls()
const TQPixmap MyPermPlugin::getIcon() const const TQPixmap MyPermPlugin::getIcon() const
{ {
return kapp->iconLoader()->loadIcon( "clanbomber", TDEIcon::Small ); return tdeApp->iconLoader()->loadIcon( "clanbomber", TDEIcon::Small );
} }
#include "permission.moc" #include "permission.moc"

@ -169,7 +169,7 @@ void PluginLoader::loadFilePlugins()
FilePlugin* tdefileplugin = new FilePlugin( s ); FilePlugin* tdefileplugin = new FilePlugin( s );
if( tdefileplugin->isValid() ) { if( tdefileplugin->isValid() ) {
addPlugin( tdefileplugin ); addPlugin( tdefileplugin );
kapp->processEvents(); tdeApp->processEvents();
} else } else
delete tdefileplugin; delete tdefileplugin;
} }

@ -96,7 +96,7 @@ ProfileManager::ProfileManager( KRenameImpl* krename )
const TQString ProfileManager::readProfilePath( const TQString & name ) const TQString ProfileManager::readProfilePath( const TQString & name )
{ {
TQString path; TQString path;
TDEConfig* conf = kapp->config(); TDEConfig* conf = tdeApp->config();
conf->setGroup( "Profiles" ); conf->setGroup( "Profiles" );
path = conf->readEntry( name, TQString() ); path = conf->readEntry( name, TQString() );
@ -115,7 +115,7 @@ const TQString ProfileManager::getProfilePath( const TQString & name )
TQString path = locateLocal( "data", TQString( "krename/%1.xml" ).arg( name ) ); TQString path = locateLocal( "data", TQString( "krename/%1.xml" ).arg( name ) );
TDEConfig* conf = kapp->config(); TDEConfig* conf = tdeApp->config();
conf->setGroup( "ProfilesHeader" ); conf->setGroup( "ProfilesHeader" );
list = conf->readListEntry( "list" ); list = conf->readListEntry( "list" );
@ -364,7 +364,7 @@ const TQValueList<int> ProfileManager::stringToList( const TQString & data )
bool ProfileManager::hasDefaultProfile() bool ProfileManager::hasDefaultProfile()
{ {
TDEConfig* conf = kapp->config(); TDEConfig* conf = tdeApp->config();
conf->setGroup( "ProfilesHeader" ); conf->setGroup( "ProfilesHeader" );
TQString def = conf->readEntry( "defprofile", TQString() ); TQString def = conf->readEntry( "defprofile", TQString() );
@ -374,7 +374,7 @@ bool ProfileManager::hasDefaultProfile()
void ProfileManager::loadDefaultProfile( KRenameImpl* krename ) void ProfileManager::loadDefaultProfile( KRenameImpl* krename )
{ {
TDEConfig* conf = kapp->config(); TDEConfig* conf = tdeApp->config();
conf->setGroup( "ProfilesHeader" ); conf->setGroup( "ProfilesHeader" );
TQString def = conf->readEntry( "defprofile", TQString() ); TQString def = conf->readEntry( "defprofile", TQString() );
@ -437,7 +437,7 @@ ProfileDlg::ProfileDlg(KRenameImpl* krename, TQWidget *parent, const char *name)
connect( checkDefault, TQ_SIGNAL( clicked() ), this, TQ_SLOT( slotSetDefault() ) ); connect( checkDefault, TQ_SIGNAL( clicked() ), this, TQ_SLOT( slotSetDefault() ) );
connect( this, TQ_SIGNAL( hidden() ), this, TQ_SLOT( slotHidden() ) ); connect( this, TQ_SIGNAL( hidden() ), this, TQ_SLOT( slotHidden() ) );
TDEConfig* conf = kapp->config(); TDEConfig* conf = tdeApp->config();
conf->setGroup( "ProfilesHeader" ); conf->setGroup( "ProfilesHeader" );
ProfileListBoxText* item; ProfileListBoxText* item;
@ -565,7 +565,7 @@ void ProfileDlg::slotDeleteProfile()
if( item ) if( item )
delete item; delete item;
TDEConfig* conf = kapp->config(); TDEConfig* conf = tdeApp->config();
conf->setGroup( "ProfilesHeader" ); conf->setGroup( "ProfilesHeader" );
TQStringList list = conf->readListEntry( "list" ); TQStringList list = conf->readListEntry( "list" );
@ -580,7 +580,7 @@ void ProfileDlg::slotDeleteProfile()
void ProfileDlg::slotHidden() void ProfileDlg::slotHidden()
{ {
int i; int i;
TDEConfig* conf = kapp->config(); TDEConfig* conf = tdeApp->config();
TQString def = TQString(); TQString def = TQString();
ProfileListBoxText* item; ProfileListBoxText* item;

@ -78,7 +78,7 @@ tabs::tabs(KRenameImpl* impl, TQRect r, TQWidget *parent, const char *name )
// Tell TDEStartupInfo that KRename has been loaded completly // Tell TDEStartupInfo that KRename has been loaded completly
TDEStartupInfoId id; TDEStartupInfoId id;
id.initId( kapp->startupId() ); id.initId( tdeApp->startupId() );
TDEStartupInfo::sendFinish( id ); TDEStartupInfo::sendFinish( id );
} }

@ -40,7 +40,7 @@ const TQString TranslitPlugin::getAccelName() const
const TQPixmap TranslitPlugin::getIcon() const const TQPixmap TranslitPlugin::getIcon() const
{ {
return kapp->iconLoader()->loadIcon( "fonts", TDEIcon::Small ); return tdeApp->iconLoader()->loadIcon( "fonts", TDEIcon::Small );
} }
const int TranslitPlugin::type() const const int TranslitPlugin::type() const

@ -55,7 +55,7 @@ wizard::wizard( KRenameImpl* impl, TQRect r, TQWidget* parent, const char* name
// Tell TDEStartupInfo that KRename has been loaded completly // Tell TDEStartupInfo that KRename has been loaded completly
TDEStartupInfoId id; TDEStartupInfoId id;
id.initId( kapp->startupId() ); id.initId( tdeApp->startupId() );
TDEStartupInfo::sendFinish( id ); TDEStartupInfo::sendFinish( id );
// Disable ESC key // Disable ESC key

Loading…
Cancel
Save