Richard Heck wrote:
Abdelrazak Younes wrote:
I've figured that out and no longer have quite this problem. The
question now is: Suppose I want the dialog to completely reset
itself. What do I call?
initParams?
I've found the real issue here. Suppose the dialog is open and the user
clicks in a new paragraph. Then update_contents() is called by
QView::update, which is called by Dialog::checkStatus, as well it should
be. But nowhere along the way has initaliseParams() been called again,
so the dialog gets updated on the basis of the original paragraph's
parameters. This seems as if it could be quite a general problem. Should
initParams() be called in QView::update()?
No. What you should do is just transfer the relevant code in
initParams() to update_contents(). Not all dialogs needs to be
re-initialised on each key-stroke. But I am wondering if this is really
the problem because I've read in Bugzilla that the former frontends
(xform and gtk) manage to do this without changing the controller...
Could you send please again your patch so that I have a look?
Abdel.