[prev in list] [next in list] [prev in thread] [next in thread]
List: kfm-devel
Subject: Re: kio::netaccess and imagepreview
From: David Faure <david () mandrakesoft ! com>
Date: 2000-06-10 21:50:39
[Download RAW message or body]
> Yes, this is exactly the problem I filed a bugreport for the other day.. if
> you do a saveAs in konqueror and then close the window, the "save-as" action
> gets aborted.
>
> What about registering network operations to kapp and/or ktmainwindow
> (refcounting)?
>
> Basically you want a generic signal like
> "no active parts left". KTMainWindow::queryExit() is a signal like this but
> specific to "mainwindows", to handle this situation we need a more generic
> solution.
>
> Note that a typical KDE application never actually should do something with
> queryExit() besides returning true.
>
> What about adding something like "ref()" and "deref()" to KApplication. When
> the ref-count decreases and becomes 0 or smaller we quit. Then it's just a
> matter of letting KTMainWindow do a ref() and ~KTMainWindow do a deref(),
> things like download then need to do their own ref() and deref().
I totally agree with this very good (and very general) solution.
Note, however that it will fix the problem you reported (konqueror aborting
the download because exiting) but _not_, as far as I can see, the problem
that Simon reported.
Unless I misunderstood, the problem with NetAccess is that enter_loop/exit_loop trick.
You make a call, the control supposedly stays there but in fact the application still
process events. If somebody closes the window (even if it's not the last one !)
you would still get a crash, when the NetAccess call returns... into a class
that was deleted.
:-(
--
David FAURE, david@mandrakesoft.com, faure@kde.org
http://home.clara.net/faure/
KDE, Making The Future of Computing Available Today
See http://www.kde.org/kde1-and-kde2.html for how to set up KDE 2
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic