Showing results for Code - The Old New Thing

May 13, 2015
Post comments count0
Post likes count0

Why don't you forward WM_GETMINMAXINFO and clamp the results?

Raymond Chen
Raymond Chen

In my illustration of how to make a window resizable in only one direction, commenter Josua asks, "Why don't you forward and clamp the results?" I'm going to assume the question is really "Why don't you forward before clamping the results?" rather than "Why did you bother writing all this code in the first place? Why not simply forward and cla...

Code
Apr 29, 2015
Post comments count0
Post likes count0

Is the atom returned by RegisterClass(Ex) a "real" atom?

Raymond Chen
Raymond Chen

A customer was debugging some code that calls on a class that's already been registered. In this case, it was registered by another DLL in the same process. Normally, this wouldn't be a problem, because each DLL passes its own instance handle to so that there are no name collisions. However, in this case, both DLLs are passing the flag, which m...

Code