|
|
|
|
|
Re: Howto dispose an MWindow? [message #959107 is a reply to message #959066] |
Fri, 26 October 2012 13:01 |
Thomas Schindl Messages: 6651 Registered: July 2009 |
Senior Member |
|
|
So you are saying that toBeRendered(false) is only making the Shell
invisible (visible=false)? I would expect toBeRendered to dispose the
resource (=shell).
Remembering the current position makes sense, because the MWindow stays
part of the workbench model and so opens on the next time at the old
position. So if you also want to wipe it from the model you need to
remove it from there manually!
IMHO toBeRendered=false should (and does) dispose the underlying shell.
Tom
Am 26.10.12 14:31, schrieb Alex Kipling:
> The difference is in different window behaviour:
>
> When I use toBeRendered(false), then the Windows remembers its last
> position, when it reapears.
> It won't happen, when closing Windows by the shell-close-button.
>
>
> The other difference is in code:
> When I close the Window by the ShellButton, the shell is disposed, so I
> have to restructure my code, to recreate the Window, when it should
> reapear.
>
> The toBeRendered(false) doesnt dispose teh window, so I doesnt't have to
> recreate the Window on toBeRendered(false).
|
|
|
Re: Howto dispose an MWindow? [message #959229 is a reply to message #959107] |
Fri, 26 October 2012 14:59 |
Alex Kipling Messages: 260 Registered: July 2012 |
Senior Member |
|
|
I keep a pointer to the Window, and a MWindow still exists, after doing "toBeRendered(false)".
I do not know, if the undelying shell still exists, but I guess so.
I guess so, because of the following effect:
When doing "toBeRendered(false); toBeRendered(true)" - the MWindow disapears and reapears without any problems.
When doing "push-close-button; toBeRendered(true)" - the MWindow disapears and do not reapears. The MWindow still exists, so I guess that the underlying shell is disposed.
[Updated on: Fri, 26 October 2012 15:00] Report message to a moderator
|
|
|
|
Powered by
FUDForum. Page generated in 0.03837 seconds