Ignore:
Timestamp:
Jul 4, 2001, 7:46:05 PM (24 years ago)
Author:
sandervl
Message:

fix for GetTopWindow/GetWindow calls during WM_NCCREATE

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/user32/win32wbase.h

    r6166 r6169  
    1 /* $Id: win32wbase.h,v 1.122 2001-07-04 09:29:52 sandervl Exp $ */
     1/* $Id: win32wbase.h,v 1.123 2001-07-04 17:46:05 sandervl Exp $ */
    22/*
    33 * Win32 Window Base Class for OS/2
     
    108108
    109109#define HAS_MENU() (!(getStyle() & WS_CHILD) && (GetMenu() != 0))
     110
     111#define STATE_INIT               0   //initial state
     112#define STATE_PRE_WMNCCREATE     1   //before WM_NCCREATE
     113#define STATE_POST_WMNCCREATE    2   //after WM_NCCREATE
     114#define STATE_PRE_WMCREATE       3   //before WM_CREATE
     115#define STATE_POST_WMCREATE      4   //after WM_CREATE
     116#define STATE_CREATED            5   //after successful return of WinCreateWindow
     117#define STATE_DESTROYED          6   //DestroyWindow called for window
     118
    110119
    111120class Win32BaseWindow : public GenericObject, public ChildWindow
     
    252261         VOID   setOS2HwndModalDialog(HWND aHwnd) { OS2HwndModalDialog = aHwnd; };
    253262         HWND   getOS2HwndModalDialog()       { return OS2HwndModalDialog; };
    254          BOOL   CanReceiveSizeMsgs()          { return !fNoSizeMsg; };
     263         BOOL   CanReceiveSizeMsgs()          { return state >= STATE_PRE_WMCREATE; };
    255264         BOOL   IsParentChanging()            { return fParentChange; };
    256          BOOL   IsWindowCreated()             { return fCreated; }
    257          BOOL   IsWindowDestroyed()           { return fIsDestroyed; };
     265         BOOL   IsWindowCreated()             { return state >= STATE_PRE_WMNCCREATE; }
     266         BOOL   IsWindowDestroyed()           { return state >= STATE_DESTROYED; };
    258267         BOOL   IsWindowIconic();
    259268         //Window procedure type
     
    373382                 fInternalMsg:1,         //Used to distinguish between messages
    374383                                         //sent by PM and those sent by apps
    375                  fNoSizeMsg:1,
    376384                 fParentChange:1,
    377                  fIsDestroyed:1,
    378385                 fDestroyWindowCalled:1, //DestroyWindow was called for this window
    379                  fCreated:1,
    380                  fCreationFinished:1,    //True when window or dialog has been created successfully
    381                                          //Needed to prevent DestroyWindow from deleting the window
    382                                          //object during construction
    383386                 fTaskList:1,            //should be listed in PM tasklist or not
    384387                 fXDefault:1,
     
    386389                 fParentDC:1,
    387390                 fComingToTop:1,
    388                  fCreateSetWindowPos:1,  //FALSE -> SetWindowPos in Win32BaseWindow::MsgCreate not yet called
    389391                 isUnicode:1,
    390392                 fMinMaxChange:1,        //set when switching between min/max/restored state
     
    392394                 fEraseBkgndFlag:1;
    393395
     396        ULONG   state;
    394397        HRGN    hWindowRegion;
    395398        HRGN    hClipRegion;
Note: See TracChangeset for help on using the changeset viewer.