On Mon, 17 Jul 2000, Angus Leeming wrote:

> I've just been looking at how the old lyx cvs branch dealt with the problem of
> what to do with the graphical dialog when its inset is deleted whilst
> the dialog is visible. The solution in this branch was to store the signal in
> the inset class itself:
> 
>       Signal0<void> hide;
> 
> and connect the dialod::hide() method to it when the dialog was launched. 
> 
> I think this is a neater solution than that implemented in the current cvs
> branch, where the signal is stored in frontends/Dialogs.h as
> 
>       Signal1<void, InsetCitation *> hideCitation;
> 
> etc etc ad nauseum for all insets.
> 
> Does anybody else have any views on this?

I'm glad somebody took a look at how I did it in the old branch.  I
haven't had the time to check out your current implementation and that's
why I hadn't commented yet.  From the comments in a few of the threads
I've read I suspect there may be a couple of other signals you can get rid
of also (or replace in a similar manner).

I had been thinking that I should have concentrated on getting an example
inset dialog completed at the FILM instead of starting the Preferences
dialog.  Seems you got to spend some time struggling with the
"delete-an-inset-with-an-open-dialog" problem as a result.  A good
learning experience and I'm glad you like my solution.  I'm sure you would
have come up with the same thing eventually, my first steps were similar
to your description of your current scheme.

Allan. (ARRae)

Reply via email to