Article View: comp.windows.ms.programmer
Article #443SC_RESTORE problems.
From: M. Guyott
Date: Thu, 16 Apr 1992 19:51
Date: Thu, 16 Apr 1992 19:51
31 lines
2008 bytes
2008 bytes
Has anyone ever had any problems with sending a WM_SYSCOMMAND message
with wParam set to SC_RESTORE?
I have a child window that I have "maximized" within the client area of
it's parent. If the user selects certain menu items I want to return the
maximized window to it's original size and position. I believe that the
way to do this is to send a WM_SYSCOMMAND message with wParam set to
SC_RESTORE. But when I do this it works sometime but not all of the time.
I have gone in with the debugger to try and see what's happening and
everything works fine except that the call to CallWindowProc() to pass
the message to the default window procedure does not work.
I've checked the last four bits of the wParam when I restore the window
via a mouse click and the maximize box and they are 0 just like when I
generate the message (0xF120). The only difference is that the lParam
when I use the mouse contains a mouse position and it contains 0L when
I generate the message myself. Is this the problem? If so why do my
generated messages work sometime but not all the time?
Any idea's will be greatly appreciated!
Marc
----
Two of the worst things we teach our children are that a knowledge of science
is nice but not necessary, and a knowledge of sex is necessary but not nice.
Marc Guyott Constellation Software, Inc. (508) 620-2800
Framingham, Mass. 01701 USA Ext. 3135
mguyott@primerd.prime.com ...!{uunet, decwrl}!primerd.prime.com!mguyott
mguyott@eriador.prime.com ...!{uunet, decwrl}!eriador.prime.com!mguyott
Technical Details
Message-ID:
<1992Apr16.195152.28692@primerd.prime.com>Path:
arc1-ca.pugleaf.net!sparky!uunet!think.com!yale.edu!jvnc.net!primerd.prime.com!eriador!mguyottShow Full Headers
Complete Article Headers
Newsgroups: comp.windows.ms.programmer Path: arc1-ca.pugleaf.net!sparky!uunet!think.com!yale.edu!jvnc.net!primerd.prime.com!eriador!mguyott From: mguyott@eriador.prime.com (M. Guyott) Subject: SC_RESTORE problems. Message-ID: <1992Apr16.195152.28692@primerd.prime.com> Sender: usenet@primerd.prime.com (Usenet) Organization: Prime Computer R&D Date: Thu, 16 Apr 1992 19:51:52 GMT Lines: 31