[GD-Windows] IsIconic() vs. trapping window messages
                
                Brought to you by:
                
                    vexxed72
                    
                
            
            
        
        
        
    | 
      
      
      From: Brian H. <bri...@py...> - 2001-11-09 20:34:28
      
     | 
| I've seen two different ways of detecting minimized state. The first is the standard trapping of WM_MOVE, WM_SIZE, WM_ACTIVATE, etc. messages. However, I've seen other code that uses IsIconic(HWND). The latter obviously can't provide you the state change detection, but assuming you don't need to capture a change in state but only need to know if you're iconic or not, is there any place where IsIconic() will fail? For example, a game might only need to know if it's active or not, and whether to render. Activation can be handled through the usual suspects, and the render loop could just do: if ( active && !IsIconic( hwnd ) ) render(); ...instead of all the cruft that normally goes into the WndProc. |