News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

WM_SIZE wParam values

Started by dedndave, January 18, 2011, 05:36:14 PM

Previous topic - Next topic

dedndave

trying to learn, here   :P

i have looked at several WinProc examples, but i do not see any that examine the wParam value passed for WM_SIZE
i am wondering if i am interpreting the documentation correctly, as it isn't very descriptive
0) SIZE_RESTORED   window has been resized, but neither the SIZE_MINIMIZED nor SIZE_MAXIMIZED value applies
1) SIZE_MINIMIZED  window has been minimized
2) SIZE_MAXIMIZED  window has been maximized
3) SIZE_MAXSHOW    sent to all pop-up windows when some other window has been restored to its former size
4) SIZE_MAXHIDE    sent to all pop-up windows when some other window is maximized


first of all, i am not writing a WinProc for a pop-up window
is it safe to assume that i won't recieve #3 or #4 ?

next, for #1 and #2, i think the system handles these, really
should i have to perform any sizing operations for these values ?

that leaves #0 - this is the one i have to process, correct ?

EDIT - correction
i DO have to process #2, much the same as #0 ?

xandaz

    I'm not sure what to say... When you're sizing a window what is the value of wParam? Try to process the window sizing disregarding wParam and you'll see it works everytime.

dedndave

 :bg

well - that's why i asked
it is better to ask those who know than to assume my testing covers all possible cases
i think i can test wParam for SIZE_RESTORED or SIZE_MAXIMIZED and process those cases
and do nothing other than return EAX = 0 for the other values

i guess it really boils down to:
do i have to do anything to process SIZE_MINIMIZED ?

xandaz

  but hey.... are you processing WM_SIZE to resize the contents of the window? Or do you actually need to intercept it for the main window?

dedndave

well - i am processing WM_SIZE for the main window - resizing controls (child windows) as required
however, windows knows the answer to your question better than i do - lol

xandaz

   lol... Is it a costumized window? you're just exploring or what are you doing?
   I bet it does. Anyway... i'm not sure if i'm right, but just leave wParam alone, and use MoveWindow....