summaryrefslogtreecommitdiffabout
path: root/pwmanager
authorzautrix <zautrix>2004-10-27 22:35:41 (UTC)
committer zautrix <zautrix>2004-10-27 22:35:41 (UTC)
commit5afbc6ae0908ce12fd5abb1c4eadf9c61a01503c (patch) (side-by-side diff)
tree914ce70d7e5a1afcd2da0c2fda34b959d65d0462 /pwmanager
parent9c88346fc757fd1dc54b3fca151a2a610159d8cf (diff)
downloadkdepimpi-5afbc6ae0908ce12fd5abb1c4eadf9c61a01503c.zip
kdepimpi-5afbc6ae0908ce12fd5abb1c4eadf9c61a01503c.tar.gz
kdepimpi-5afbc6ae0908ce12fd5abb1c4eadf9c61a01503c.tar.bz2
pwm close fix
Diffstat (limited to 'pwmanager') (more/less context) (ignore whitespace changes)
-rw-r--r--pwmanager/pwmanager/pwminit.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/pwmanager/pwmanager/pwminit.cpp b/pwmanager/pwmanager/pwminit.cpp
index fbd17a7..68f3637 100644
--- a/pwmanager/pwmanager/pwminit.cpp
+++ b/pwmanager/pwmanager/pwminit.cpp
@@ -176,24 +176,33 @@ void PwMInit::initializeApp()
} else {
createMainWnd(conf()->confGlobAutoStart(),
openDeeplocked,
true,
0,
savedCmd.minimized);
}
runStatus = running;
}
void PwMInit::shutdownApp(int exitStatus)
{
+
+
+ PwM * iii;
+ while ( iii = _mainWndList.first() ) {
+ disconnect(iii, SIGNAL(closed(PwM *)),
+ this, SLOT(mainWndClosed(PwM *)));
+ mainWndClosed((iii));
+ }
+
printDebug(string("PwMInit::shutdownApp(")
+ tostr(exitStatus) + ") called.");
PWM_ASSERT((runStatus == running) || (runStatus == init));
runStatus = shutdown;
QApplication::exit(exitStatus);
/* The destructor of PwMInit is called when control
* leaves main()
*/
}
void PwMInit::initPosixSignalHandler()
{
@@ -415,24 +424,25 @@ again:
}
}
#ifndef PWM_EMBEDDED
// find the closed window in the "mainWndList" and delete it.
QValueList<PwM *>::iterator i = _mainWndList.begin(),
end = _mainWndList.end();
#else
// find the closed window in the "mainWndList" and delete it.
QValueList<PwM *>::Iterator i = _mainWndList.begin(),
end = _mainWndList.end();
#endif
while (i != end) {
+ //qDebug("iii %x end %x wnd %x", (*i), (*end), wnd);
if (*i == wnd) {
#ifndef PWM_EMBEDDED
_mainWndList.erase(i);
#else
_mainWndList.remove(i);
#endif
if ( app->mainWidget() == wnd ) {
if ( _mainWndList.count() ) {
#ifndef DESKTOP_VERSION
app->showMainWidget(_mainWndList.first() );
#endif //DESKTOP_VERSION