Rename KApplication to TDEApplication to avoid conflicts with KDE4

pull/1/head
Timothy Pearson 12 years ago
parent ca1ec6eeaa
commit f7307c9513

@ -47,7 +47,7 @@ int main(int argc, char *argv[])
TDECmdLineArgs::init(argc, argv, &about); TDECmdLineArgs::init(argc, argv, &about);
TDECmdLineArgs::addCmdLineOptions( options ); TDECmdLineArgs::addCmdLineOptions( options );
KApplication app; TDEApplication app;
// see if we are starting with session management // see if we are starting with session management
if (app.isRestored()) if (app.isRestored())

@ -821,7 +821,7 @@ void KImageMapEditor::slotUpdateSelectionCoords( const TQRect & r )
kapp->processEvents(); kapp->processEvents();
} }
KApplication* KImageMapEditor::app() const TDEApplication* KImageMapEditor::app() const
{ {
return kapp; return kapp;
} }

@ -116,7 +116,7 @@ class KAction;
#endif #endif
///class TQListViewItem; ///class TQListViewItem;
class KCommandHistory; class KCommandHistory;
class KApplication; class TDEApplication;
class TQTabWidget; class TQTabWidget;
class AreaListView; class AreaListView;
class ImagesListView; class ImagesListView;
@ -174,7 +174,7 @@ public :
int showTagEditor(Area *); int showTagEditor(Area *);
KCommandHistory *commandHistory() const; KCommandHistory *commandHistory() const;
KApplication* app() const; TDEApplication* app() const;
// Only refreshes the listView // Only refreshes the listView
void updateSelection() const; void updateSelection() const;

@ -52,7 +52,7 @@ int main(int argc, char *argv[])
TDECmdLineArgs::init( argc, argv, &aboutData ); TDECmdLineArgs::init( argc, argv, &aboutData );
TDECmdLineArgs::addCmdLineOptions( options ); // Add our own options. TDECmdLineArgs::addCmdLineOptions( options ); // Add our own options.
KApplication a; TDEApplication a;
a.dcopClient()->registerAs(a.name()); a.dcopClient()->registerAs(a.name());

@ -112,7 +112,7 @@ void KLinkStatus::setupActions()
register it with staticKLSConfigDeleter due to the lack of static deleter register it with staticKLSConfigDeleter due to the lack of static deleter
administration. administration.
The easiest solution is to call close() on the mainwindow instead of The easiest solution is to call close() on the mainwindow instead of
KApplication::quit()*/ TDEApplication::quit()*/
KStdAction::quit(TQT_TQOBJECT(this), TQT_SLOT(close()), actionCollection()); KStdAction::quit(TQT_TQOBJECT(this), TQT_SLOT(close()), actionCollection());
//m_toolbarAction = KStdAction::showToolbar(this, TQT_SLOT(optionsShowToolbar()), actionCollection()); //m_toolbarAction = KStdAction::showToolbar(this, TQT_SLOT(optionsShowToolbar()), actionCollection());

@ -64,7 +64,7 @@ int main(int argc, char *argv[])
TDECmdLineArgs::init(argc, argv, &about); TDECmdLineArgs::init(argc, argv, &about);
TDECmdLineArgs::addCmdLineOptions( options ); TDECmdLineArgs::addCmdLineOptions( options );
KApplication app; TDEApplication app;
// see if we are starting with session management // see if we are starting with session management
if (app.isRestored()) if (app.isRestored())

@ -218,7 +218,7 @@ void SessionWidget::slotCheck()
if(!validFields()) if(!validFields())
{ {
ready_ = true; ready_ = true;
KApplication::beep(); TDEApplication::beep();
return; return;
} }
@ -430,7 +430,7 @@ void SessionWidget::slotSearchFinished()
Q_ASSERT(!paused_); Q_ASSERT(!paused_);
Q_ASSERT(!stopped_); Q_ASSERT(!stopped_);
KApplication::beep (); TDEApplication::beep ();
textlabel_progressbar->setText(i18n( "Ready" )); textlabel_progressbar->setText(i18n( "Ready" ));
progressbar_checker->reset(); progressbar_checker->reset();
@ -458,7 +458,7 @@ void SessionWidget::slotSearchPaused()
Q_ASSERT(pendingActions()); Q_ASSERT(pendingActions());
Q_ASSERT(in_progress_); Q_ASSERT(in_progress_);
KApplication::beep(); TDEApplication::beep();
textlabel_progressbar->setText(i18n("Stopped")); textlabel_progressbar->setText(i18n("Stopped"));
@ -591,7 +591,7 @@ void SessionWidget::slotStartSearch()
{ {
start_search_action_->setChecked(true); // do not toggle start_search_action_->setChecked(true); // do not toggle
Q_ASSERT(!stopped_); Q_ASSERT(!stopped_);
KApplication::beep(); TDEApplication::beep();
return; return;
} }

@ -141,7 +141,7 @@ TQString KopeteXSLThread::xsltTransform( const TQString &xmlString, xsltStyleshe
{ {
if ( styleSheet ) if ( styleSheet )
{ {
static TQCString appPath( TQString::fromLatin1("\"%1\"").arg( KApplication::kApplication()->dirs()->findDirs("appdata", TQString::fromLatin1("styles/data") ).front() ).utf8() ); static TQCString appPath( TQString::fromLatin1("\"%1\"").arg( TDEApplication::kApplication()->dirs()->findDirs("appdata", TQString::fromLatin1("styles/data") ).front() ).utf8() );
static const char* params[3] = { static const char* params[3] = {
"appdata", "appdata",

@ -55,7 +55,7 @@ int main( int argc, char *argv[] )
KommanderWidget::inEditor = true; KommanderWidget::inEditor = true;
KLocale::setMainCatalogue("kommander"); KLocale::setMainCatalogue("kommander");
KApplication a(true, true); TDEApplication a(true, true);
KConfig *config = kapp->config(); KConfig *config = kapp->config();
config->setGroup("General"); config->setGroup("General");

@ -79,7 +79,7 @@ int main(int argc, char *argv[])
} }
else else
KLocale::setMainCatalogue("kommander"); KLocale::setMainCatalogue("kommander");
KApplication app; TDEApplication app;
TQObject::connect(&app, TQT_SIGNAL(lastWindowClosed()), &app, TQT_SLOT(quit())); TQObject::connect(&app, TQT_SIGNAL(lastWindowClosed()), &app, TQT_SLOT(quit()));
if (!args->count()) if (!args->count())

@ -66,7 +66,7 @@ int main(int argc, char *argv[])
TDECmdLineArgs::addCmdLineOptions(options); // Add our own options. TDECmdLineArgs::addCmdLineOptions(options); // Add our own options.
TDECmdLineArgs *args = TDECmdLineArgs::parsedArgs(); TDECmdLineArgs *args = TDECmdLineArgs::parsedArgs();
KApplication app; TDEApplication app;
if (!args->getOption("add").isNull() || !args->getOption("remove").isNull() || args->isSet("check") || args->isSet("list")) if (!args->getOption("add").isNull() || !args->getOption("remove").isNull() || args->isSet("check") || args->isSet("list"))
{ {

@ -363,7 +363,7 @@ static ParseNode f_dcop(Parser*, const ParameterList& params)
} }
function.append(TQString("(%1)").arg(items.join(","))); function.append(TQString("(%1)").arg(items.join(",")));
TQCString replyType, byteReply; TQCString replyType, byteReply;
DCOPClient* cl = KApplication::dcopClient(); DCOPClient* cl = TDEApplication::dcopClient();
if (!cl || !cl->call(appId, object, function.latin1(), if (!cl || !cl->call(appId, object, function.latin1(),
byteData, replyType, byteReply)) byteData, replyType, byteReply))
{ {

@ -304,7 +304,7 @@ TQString KommanderWidget::DCOPQuery(const TQStringList& a_query)
byteDataStream << a_query[i+3]; byteDataStream << a_query[i+3];
} }
DCOPClient *cl = KApplication::dcopClient(); DCOPClient *cl = TDEApplication::dcopClient();
if (!cl || !cl->call(appId, object, function.latin1(), byteData, replyType, byteReply)) if (!cl || !cl->call(appId, object, function.latin1(), byteData, replyType, byteReply))
{ {
printError(i18n("Tried to perform DCOP query, but failed.")); printError(i18n("Tried to perform DCOP query, but failed."));

@ -117,14 +117,14 @@ void ExecButton::startProcess()
if (m_blockGUI != None) if (m_blockGUI != None)
setEnabled(false); setEnabled(false);
if (m_blockGUI == GUI) if (m_blockGUI == GUI)
KApplication::setOverrideCursor(TQCursor(TQt::WaitCursor)); TDEApplication::setOverrideCursor(TQCursor(TQt::WaitCursor));
MyProcess* process = new MyProcess(this); MyProcess* process = new MyProcess(this);
process->setBlocking(m_blockGUI == GUI); process->setBlocking(m_blockGUI == GUI);
connect(process, TQT_SIGNAL(processExited(MyProcess*)), TQT_SLOT(processExited(MyProcess*))); connect(process, TQT_SIGNAL(processExited(MyProcess*)), TQT_SLOT(processExited(MyProcess*)));
m_output = process->run(at); m_output = process->run(at);
if (m_blockGUI == GUI) if (m_blockGUI == GUI)
{ {
KApplication::restoreOverrideCursor(); TDEApplication::restoreOverrideCursor();
if (writeStdout()) if (writeStdout())
cout << m_output << flush; cout << m_output << flush;
} }

@ -23,7 +23,7 @@ int main(int argc, char **argv)
about.addAuthor( "Keith Isdale", 0, "k_isdale@tpg.com.au" ); about.addAuthor( "Keith Isdale", 0, "k_isdale@tpg.com.au" );
TDECmdLineArgs::init(argc, argv, &about); TDECmdLineArgs::init(argc, argv, &about);
TDECmdLineArgs::addCmdLineOptions( options ); TDECmdLineArgs::addCmdLineOptions( options );
KApplication app; TDEApplication app;
// see if we are starting with session management // see if we are starting with session management
if (app.isRestored()) if (app.isRestored())

@ -99,11 +99,11 @@ static const KCmdLineOptions options[] =
KCmdLineLastOption // End of options. KCmdLineLastOption // End of options.
}; };
class XsldbgApp : public KApplication class XsldbgApp : public TDEApplication
{ {
public: public:
XsldbgApp() XsldbgApp()
:KApplication(false, false) :TDEApplication(false, false)
{ {
xsldbgSetAppFunc(notifyXsldbgAppSimple); xsldbgSetAppFunc(notifyXsldbgAppSimple);
xsldbgSetAppStateFunc(notifyStateXsldbgAppSimple); xsldbgSetAppStateFunc(notifyStateXsldbgAppSimple);

@ -72,7 +72,7 @@ void KNewStuff::download()
TQString KNewStuff::downloadDestination( Entry * ) TQString KNewStuff::downloadDestination( Entry * )
{ {
return KGlobal::dirs()->saveLocation( "tmp" ) + return KGlobal::dirs()->saveLocation( "tmp" ) +
KApplication::randomString( 10 ); TDEApplication::randomString( 10 );
} }
void KNewStuff::upload() void KNewStuff::upload()

@ -537,7 +537,7 @@ void CVSService::startService()
if (!m_cvsService) if (!m_cvsService)
{ {
TQString error; TQString error;
KApplication::startServiceByDesktopName("cvsservice", TQStringList(), &error, TDEApplication::startServiceByDesktopName("cvsservice", TQStringList(), &error,
&m_appId); &m_appId);
m_cvsService = new CvsService_stub(m_appId, "CvsService"); m_cvsService = new CvsService_stub(m_appId, "CvsService");
} }

@ -788,7 +788,7 @@ void ActionConfigDialog::slotNewAction()
{ {
TQDomDocument doc; TQDomDocument doc;
TQDomElement el = doc.createElement("action"); TQDomElement el = doc.createElement("action");
el.setAttribute( "name", "user_"+KApplication::randomString(10) ); el.setAttribute( "name", "user_"+TDEApplication::randomString(10) );
el.setAttribute( "icon", "ball" ); el.setAttribute( "icon", "ball" );
currentAction = new TagAction(&el, m_mainWindow); currentAction = new TagAction(&el, m_mainWindow);

@ -1525,7 +1525,7 @@ See the operations in order to get a picture what's here." name="QuantaDoc" stat
<UML:Attribute stereotype="" package="" xmi.id="1270" value="" type="QPopupMenu *" abstract="0" documentation="" name="fileMenu" static="0" scope="200" /> <UML:Attribute stereotype="" package="" xmi.id="1270" value="" type="QPopupMenu *" abstract="0" documentation="" name="fileMenu" static="0" scope="200" />
<UML:Attribute stereotype="" package="" xmi.id="1271" value="" type="QPopupMenu *" abstract="0" documentation="" name="folderMenu" static="0" scope="200" /> <UML:Attribute stereotype="" package="" xmi.id="1271" value="" type="QPopupMenu *" abstract="0" documentation="" name="folderMenu" static="0" scope="200" />
</UML:Class> </UML:Class>
<UML:Class stereotype="" package="" xmi.id="1298" abstract="0" documentation="" name="KApplication" static="0" scope="200" /> <UML:Class stereotype="" package="" xmi.id="1298" abstract="0" documentation="" name="TDEApplication" static="0" scope="200" />
<UML:Association nameb="" stereotype="" assoctype="dependency" rolea="274" roleb="307" multia="" multib="" package="" xmi.id="1311" abstract="0" documentation="" name="" static="0" scope="200" namea="" /> <UML:Association nameb="" stereotype="" assoctype="dependency" rolea="274" roleb="307" multia="" multib="" package="" xmi.id="1311" abstract="0" documentation="" name="" static="0" scope="200" namea="" />
<UML:Association nameb="" stereotype="" assoctype="dependency" rolea="74" roleb="307" multia="" multib="" package="" xmi.id="1312" abstract="0" documentation="" name="" static="0" scope="200" namea="" /> <UML:Association nameb="" stereotype="" assoctype="dependency" rolea="74" roleb="307" multia="" multib="" package="" xmi.id="1312" abstract="0" documentation="" name="" static="0" scope="200" namea="" />
<UML:Association nameb="" stereotype="" assoctype="dependency" rolea="695" roleb="307" multia="" multib="" package="" xmi.id="1313" abstract="0" documentation="" name="" static="0" scope="200" namea="" /> <UML:Association nameb="" stereotype="" assoctype="dependency" rolea="695" roleb="307" multia="" multib="" package="" xmi.id="1313" abstract="0" documentation="" name="" static="0" scope="200" namea="" />
@ -2661,7 +2661,7 @@ See the operations in order to get a picture what's here." name="QuantaDoc" stat
<listitem open="0" type="815" id="1265" label="slotReload" /> <listitem open="0" type="815" id="1265" label="slotReload" />
<listitem open="0" type="815" id="1266" label="~FilesTreeView" /> <listitem open="0" type="815" id="1266" label="~FilesTreeView" />
</listitem> </listitem>
<listitem open="1" type="813" id="1298" label="KApplication" /> <listitem open="1" type="813" id="1298" label="TDEApplication" />
<listitem open="1" type="813" id="1570" label="KListView" /> <listitem open="1" type="813" id="1570" label="KListView" />
<listitem open="0" type="813" id="564" label="KQApplication" > <listitem open="0" type="813" id="564" label="KQApplication" >
<listitem open="0" type="815" id="565" label="KQApplication" /> <listitem open="0" type="815" id="565" label="KQApplication" />

@ -60,7 +60,7 @@ KSplash::~KSplash()
KQApplication::KQApplication() KQApplication::KQApplication()
: KApplication() : TDEApplication()
{ {
args = TDECmdLineArgs::parsedArgs(); args = TDECmdLineArgs::parsedArgs();
splash = 0L; splash = 0L;

@ -49,7 +49,7 @@ class KQApplicationPrivate
KSplashScreen *sp; KSplashScreen *sp;
}; };
class KQApplication : public KApplication, KQApplicationPrivate class KQApplication : public TDEApplication, KQApplicationPrivate
{ {
Q_OBJECT Q_OBJECT

@ -192,8 +192,8 @@ int main(int argc, char *argv[])
} }
} }
KApplication *app; TDEApplication *app;
KApplication::disableAutoDcopRegistration(); TDEApplication::disableAutoDcopRegistration();
if (isUnique) { if (isUnique) {
KUniqueApplication::dcopClient()->registerAs("quanta-foo"); KUniqueApplication::dcopClient()->registerAs("quanta-foo");

@ -1150,7 +1150,7 @@ void QuantaApp::slotOptionsConfigureActions()
void QuantaApp::slotPreviewOptions() void QuantaApp::slotPreviewOptions()
{ {
KMessageBox::information(this, i18n("Changes made in the preview configuration dialog are global and have effect on every application using the KHTML part to display web pages, including Konqueror."), i18n("Warning"), "configure_preview_warning"); KMessageBox::information(this, i18n("Changes made in the preview configuration dialog are global and have effect on every application using the KHTML part to display web pages, including Konqueror."), i18n("Warning"), "configure_preview_warning");
KApplication::startServiceByDesktopName("quanta_preview_config"); TDEApplication::startServiceByDesktopName("quanta_preview_config");
} }
void QuantaApp::slotOptions() void QuantaApp::slotOptions()

@ -1484,7 +1484,7 @@ void QuantaInit::checkRuntimeDependencies()
TQString error; TQString error;
TQCString appId; TQCString appId;
KApplication::startServiceByDesktopName("cvsservice", TQStringList(), &error, TDEApplication::startServiceByDesktopName("cvsservice", TQStringList(), &error,
&appId); &appId);
if (appId.isEmpty()) if (appId.isEmpty())
{ {

@ -505,7 +505,7 @@ void StructTreeView::slotMouseClicked(int button, TQListViewItem *item, const TQ
setOpen(item, !isOpen(item)); setOpen(item, !isOpen(item));
setSelected(item, true); setSelected(item, true);
bool const ctrlPressed = KApplication::keyboardMouseState() & TQt::ControlButton; bool const ctrlPressed = TDEApplication::keyboardMouseState() & TQt::ControlButton;
if(ctrlPressed) if(ctrlPressed)
setContiguousSelectedItems(); setContiguousSelectedItems();

Loading…
Cancel
Save