diff options
author | Michele Calgaro <[email protected]> | 2025-01-21 11:34:11 +0900 |
---|---|---|
committer | Michele Calgaro <[email protected]> | 2025-01-21 11:34:11 +0900 |
commit | d05b646280d9b464284c534578ca8d98b34e7ce7 (patch) | |
tree | 6e8a518b4723bcc3343e4adcaa55de5b45a8eb52 | |
parent | 7d033d1ca0f89077d775b888b1b80fb51382eade (diff) | |
download | tdedocker-d05b646280d9b464284c534578ca8d98b34e7ce7.tar.gz tdedocker-d05b646280d9b464284c534578ca8d98b34e7ce7.zip |
Signed-off-by: Michele Calgaro <[email protected]>
-rw-r--r-- | src/main.cpp | 4 | ||||
-rw-r--r-- | src/tdedocker.cpp | 4 | ||||
-rw-r--r-- | src/traylabelmgr.cpp | 20 |
3 files changed, 14 insertions, 14 deletions
diff --git a/src/main.cpp b/src/main.cpp index 9cc5211..ddb9136 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -45,8 +45,8 @@ static void sighandler(int sig) } tqDebug("%s", i18n("Caught signal %1. Cleaning up.").arg(sig).local8Bit().data()); - ((TDEDocker*)TDEApplication::kApplication())->trayLabelMgr()->undockAll(); - TDEApplication::kApplication()->quit(); + ((TDEDocker*)tdeApp)->trayLabelMgr()->undockAll(); + tdeApp->quit(); } static const TDECmdLineOptions options[] = diff --git a/src/tdedocker.cpp b/src/tdedocker.cpp index 12afca3..d37a096 100644 --- a/src/tdedocker.cpp +++ b/src/tdedocker.cpp @@ -50,9 +50,9 @@ TDEDocker::TDEDocker() // Required so that the saved config is correctly loaded // (see TrayLabelMgr::doRestoreSession() for usage) - if (TDEApplication::kApplication()->isRestored()) + if (tdeApp->isRestored()) { - TDEApplication::kApplication()->sessionConfig(); + tdeApp->sessionConfig(); } } diff --git a/src/traylabelmgr.cpp b/src/traylabelmgr.cpp index b262ac8..6eacdf7 100644 --- a/src/traylabelmgr.cpp +++ b/src/traylabelmgr.cpp @@ -67,7 +67,7 @@ void TrayLabelMgr::startup(void) * stdout is a tty) OR if we are getting restored, wait for WAIT_TIME until * the system tray shows up (before informing the user) */ - static bool do_wait = !isatty(fileno(stdout)) || TDEApplication::kApplication()->isRestored(); + static bool do_wait = !isatty(fileno(stdout)) || tdeApp->isRestored(); SysTrayState state = sysTrayStatus(TQPaintDevice::x11AppDisplay()); @@ -84,7 +84,7 @@ void TrayLabelMgr::startup(void) state == SysTrayAbsent ? i18n("No system tray found") : i18n("System tray appears to be hidden"), i18n("TDEDocker")) == KMessageBox::Cancel) { - TDEApplication::kApplication()->quit(); + tdeApp->quit(); return; } } @@ -92,7 +92,7 @@ void TrayLabelMgr::startup(void) // Things are fine or user with OK with the state of system tray mReady = true; bool ok = false; - if (TDEApplication::kApplication()->isRestored()) + if (tdeApp->isRestored()) { restoreSession(); ok = true; @@ -110,7 +110,7 @@ void TrayLabelMgr::startup(void) } if (!ok) { - TDEApplication::kApplication()->quit(); + tdeApp->quit(); } } @@ -426,7 +426,7 @@ TQTrayLabel *TrayLabelMgr::dockApplication(char *argv[]) { tqDebug("%s", i18n("Failed to exec [%1]: %2").arg(argv[0]).arg(strerror(errno)).local8Bit().data()); // Exit the forked process only. - // Using TDEApplication::kApplication()->quit() crashes the parent application. + // Using tdeApp->quit() crashes the parent application. exit(0); return NULL; } @@ -447,7 +447,7 @@ TQTrayLabel *TrayLabelMgr::dockApplication(char *argv[]) } TQTrayLabel *label = new TQTrayLabel(cmd_line, pid); - TDEApplication::kApplication()->syncX(); + tdeApp->syncX(); write(filedes[1], buf, sizeof(buf)); close(filedes[0]); close(filedes[1]); @@ -479,7 +479,7 @@ void TrayLabelMgr::trayLabelDestroyed(TQObject *t) mTrayLabels.removeRef((TQTrayLabel*)t); if (mTrayLabels.isEmpty()) { - TDEApplication::kApplication()->quit(); + tdeApp->quit(); } else if (reconnect) { @@ -526,7 +526,7 @@ void TrayLabelMgr::doRestoreSession() { TRACE("Restoring session"); - TDEConfig *config = TDEApplication::kApplication()->sessionConfig(); + TDEConfig *config = tdeApp->sessionConfig(); if (config->hasGroup("General")) { config->setGroup("General"); @@ -554,7 +554,7 @@ void TrayLabelMgr::doRestoreSession() // Exit if no application could be restored if (mTrayLabels.isEmpty()) { - TDEApplication::kApplication()->quit(); + tdeApp->quit(); } } @@ -564,7 +564,7 @@ bool TrayLabelMgr::saveState(TQSessionManager &sm) int i = 0; TQTrayLabel *t; - TDEConfig *config = TDEApplication::kApplication()->sessionConfig(); + TDEConfig *config = tdeApp->sessionConfig(); TQPtrListIterator<TQTrayLabel> it(mTrayLabels); for (it.toFirst(); it.current(); ++it) { |