Diffstat (limited to 'microkde/kdeui/kmainwindow.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | microkde/kdeui/kmainwindow.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/microkde/kdeui/kmainwindow.cpp b/microkde/kdeui/kmainwindow.cpp index bd5a2cc..3ae4c87 100644 --- a/microkde/kdeui/kmainwindow.cpp +++ b/microkde/kdeui/kmainwindow.cpp | |||
@@ -279,48 +279,49 @@ void KMainWindow::setPlainCaption( const QString &caption ) | |||
279 | QMainWindow::setCaption( caption ); | 279 | QMainWindow::setCaption( caption ); |
280 | #ifndef Q_WS_QWS | 280 | #ifndef Q_WS_QWS |
281 | //US the following is disabled for the embedded version | 281 | //US the following is disabled for the embedded version |
282 | //US NETWinInfo info( qt_xdisplay(), winId(), qt_xrootwin(), 0 ); | 282 | //US NETWinInfo info( qt_xdisplay(), winId(), qt_xrootwin(), 0 ); |
283 | //US info.setName( caption.utf8().data() ); | 283 | //US info.setName( caption.utf8().data() ); |
284 | #endif | 284 | #endif |
285 | } | 285 | } |
286 | 286 | ||
287 | void KMainWindow::slotStateChanged(const QString &newstate) | 287 | void KMainWindow::slotStateChanged(const QString &newstate) |
288 | { | 288 | { |
289 | stateChanged(newstate, KXMLGUIClient::StateNoReverse); | 289 | stateChanged(newstate, KXMLGUIClient::StateNoReverse); |
290 | } | 290 | } |
291 | 291 | ||
292 | /* | 292 | /* |
293 | * Get rid of this for KDE 4.0 | 293 | * Get rid of this for KDE 4.0 |
294 | */ | 294 | */ |
295 | void KMainWindow::slotStateChanged(const QString &newstate, | 295 | void KMainWindow::slotStateChanged(const QString &newstate, |
296 | KXMLGUIClient::ReverseStateChange reverse) | 296 | KXMLGUIClient::ReverseStateChange reverse) |
297 | { | 297 | { |
298 | stateChanged(newstate, reverse); | 298 | stateChanged(newstate, reverse); |
299 | } | 299 | } |
300 | 300 | ||
301 | void KMainWindow::closeEvent ( QCloseEvent *e ) | 301 | void KMainWindow::closeEvent ( QCloseEvent *e ) |
302 | { | 302 | { |
303 | //qDebug("MainWindow::closeEvent "); | ||
303 | // Save settings if auto-save is enabled, and settings have changed | 304 | // Save settings if auto-save is enabled, and settings have changed |
304 | if (d->settingsDirty && d->autoSaveSettings) | 305 | if (d->settingsDirty && d->autoSaveSettings) |
305 | saveAutoSaveSettings(); | 306 | saveAutoSaveSettings(); |
306 | 307 | ||
307 | if (queryClose()) { | 308 | if (queryClose()) { |
308 | e->accept(); | 309 | e->accept(); |
309 | 310 | ||
310 | int not_withdrawn = 0; | 311 | int not_withdrawn = 0; |
311 | /*US | 312 | /*US |
312 | QPtrListIterator<KMainWindow> it(*KMainWindow::memberList); | 313 | QPtrListIterator<KMainWindow> it(*KMainWindow::memberList); |
313 | for (it.toFirst(); it.current(); ++it){ | 314 | for (it.toFirst(); it.current(); ++it){ |
314 | if ( !it.current()->isHidden() && it.current()->isTopLevel() && it.current() != this ) | 315 | if ( !it.current()->isHidden() && it.current()->isTopLevel() && it.current() != this ) |
315 | not_withdrawn++; | 316 | not_withdrawn++; |
316 | } | 317 | } |
317 | */ | 318 | */ |
318 | if ( !no_query_exit && not_withdrawn <= 0 ) { // last window close accepted? | 319 | if ( !no_query_exit && not_withdrawn <= 0 ) { // last window close accepted? |
319 | /*US | 320 | /*US |
320 | if ( queryExit() && !kapp->sessionSaving()) { // Yes, Quit app? | 321 | if ( queryExit() && !kapp->sessionSaving()) { // Yes, Quit app? |
321 | // don't call queryExit() twice | 322 | // don't call queryExit() twice |
322 | disconnect(kapp, SIGNAL(shutDown()), this, SLOT(shuttingDown())); | 323 | disconnect(kapp, SIGNAL(shutDown()), this, SLOT(shuttingDown())); |
323 | kapp->deref(); // ...and quit aplication. | 324 | kapp->deref(); // ...and quit aplication. |
324 | } else { | 325 | } else { |
325 | // cancel closing, it's stupid to end up with no windows at all.... | 326 | // cancel closing, it's stupid to end up with no windows at all.... |
326 | e->ignore(); | 327 | e->ignore(); |