GetScreenPosition and iconize
Jorgen Bodde
jorgen.maillist at gmail.com
Fri Feb 9 01:50:52 PST 2007
Well I would still expect GetSize() to return a valid size. If a
window is hidden or iconized, it still has that size when restored, so
GetSize should always report this. And indeed we have IsIconized() to
discriminate between the two states. I would say returning other
values based upon a window state is confusing.
- Jorgen
On 2/9/07, Fabian Cenedese <Cenedese at indel.ch> wrote:
> At 09:56 09.02.2007 +0100, Jorgen Bodde wrote:
> >I would still vote for uniform functionality. And I am in favor of
> >returning the restored size. Reason is when you save your settings and
> >you want to save the size of the window for restoring it later, you
> >get weird -32000 or -1 or whatever. Storing that as your size in your
> >settings, will screw up your app the next time you run it. So you have
> >to do smart stuff to prevent saving the size when the app is
> >minimized, which has the nasty stide effect again that the last used
> >position cannot be saved! So everytime my app restores after iconized
> >state, it always comes back to the last known valid position.
> >
> >This is why always giving back the actual size, iconized or not, is better.
>
> Yup, that's why we use GetWindowPlacement on Windows as this
> always gives back the "useful" position, no matter if it's iconized
> or not. This is opposed to GetWindowPosition (or whatever it's called).
>
> bye Fabi
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: wx-users-unsubscribe at lists.wxwidgets.org
> For additional commands, e-mail: wx-users-help at lists.wxwidgets.org
>
>
More information about the wx-users
mailing list