Changeset View
Changeset View
Standalone View
Standalone View
src/App.cpp
Show First 20 Lines • Show All 68 Lines • ▼ Show 20 Line(s) | |||||
69 | 69 | | |||
70 | #include <KDirLister> | 70 | #include <KDirLister> | ||
71 | #include <KEditToolBar> //slotConfigToolbars() | 71 | #include <KEditToolBar> //slotConfigToolbars() | ||
72 | #include <KIO/CopyJob> | 72 | #include <KIO/CopyJob> | ||
73 | #include <KJobUiDelegate> | 73 | #include <KJobUiDelegate> | ||
74 | #include <KLocalizedString> | 74 | #include <KLocalizedString> | ||
75 | #include <KMessageBox> | 75 | #include <KMessageBox> | ||
76 | #include <KShortcutsDialog> //slotConfigShortcuts() | 76 | #include <KShortcutsDialog> //slotConfigShortcuts() | ||
77 | #include <ThreadWeaver/Queue> | ||||
77 | 78 | | |||
78 | #include <QAction> | 79 | #include <QAction> | ||
79 | #include <QByteArray> | 80 | #include <QByteArray> | ||
80 | #include <QCommandLineParser> | 81 | #include <QCommandLineParser> | ||
81 | #include <QDesktopServices> | 82 | #include <QDesktopServices> | ||
82 | #include <QFile> | 83 | #include <QFile> | ||
83 | #include <QFileOpenEvent> | 84 | #include <QFileOpenEvent> | ||
84 | #include <QStringList> | 85 | #include <QStringList> | ||
▲ Show 20 Lines • Show All 125 Lines • ▼ Show 20 Line(s) | 208 | #ifndef Q_WS_MAC | |||
210 | AmarokConfig::self()->save(); | 211 | AmarokConfig::self()->save(); | ||
211 | #else | 212 | #else | ||
212 | // for some reason on OS X the main window always reports being hidden | 213 | // for some reason on OS X the main window always reports being hidden | ||
213 | // this means if you have the tray icon enabled, amarok will always open minimized | 214 | // this means if you have the tray icon enabled, amarok will always open minimized | ||
214 | Amarok::config().writeEntry( "HiddenOnExit", false ); | 215 | Amarok::config().writeEntry( "HiddenOnExit", false ); | ||
215 | AmarokConfig::self()->save(); | 216 | AmarokConfig::self()->save(); | ||
216 | #endif | 217 | #endif | ||
217 | 218 | | |||
219 | // wait for threads to finish | ||||
220 | ThreadWeaver::Queue::instance()->requestAbort(); | ||||
221 | ThreadWeaver::Queue::instance()->finish(); | ||||
222 | ThreadWeaver::Queue::instance()->shutDown(); | ||||
223 | | ||||
218 | ScriptManager::destroy(); | 224 | ScriptManager::destroy(); | ||
219 | 225 | | |||
220 | // this must be deleted before the connection to the Xserver is | 226 | // this must be deleted before the connection to the Xserver is | ||
221 | // severed, or we risk a crash when the QApplication is exited, | 227 | // severed, or we risk a crash when the QApplication is exited, | ||
222 | // I asked Trolltech! *smug* | 228 | // I asked Trolltech! *smug* | ||
223 | Amarok::OSD::destroy(); | 229 | Amarok::OSD::destroy(); | ||
224 | Amarok::KNotificationBackend::destroy(); | 230 | Amarok::KNotificationBackend::destroy(); | ||
225 | 231 | | |||
▲ Show 20 Lines • Show All 449 Lines • Show Last 20 Lines |