Ignore:
Timestamp:
Apr 24, 2003, 3:59:15 PM (22 years ago)
Author:
sandervl
Message:

EndDialog: Enable owner window regardless of whether it was enabled before dialog creation & check for fake windows in GetWindowFromOS2Handle

File:
1 edited

Legend:

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

    r10031 r10033  
    1 /* $Id: win32wbase.cpp,v 1.367 2003-04-23 18:00:59 sandervl Exp $ */
     1/* $Id: win32wbase.cpp,v 1.368 2003-04-24 13:59:14 sandervl Exp $ */
    22/*
    33 * Win32 Window Base Class for OS/2
     
    4848#include <custombuild.h>
    4949#include "win32wbase.h"
     50#include "win32wfake.h"
    5051#include "wndmsg.h"
    5152#include "oslibwin.h"
     
    11431144                                        MAKELONG( lastHitTestVal, msg->message) );
    11441145
    1145                 dprintf2(("WM_MOUSEACTIVATE returned %d", ret));
     1146                dprintf2(("WM_MOUSEACTIVATE returned %d foreground %x top %x", ret, GetForegroundWindow(), hwndTop));
    11461147#if 0
    11471148                if ((ret == MA_ACTIVATEANDEAT) || (ret == MA_NOACTIVATEANDEAT))
     
    11571158
    11581159                    //SvL: Calling OSLibSetActiveWindow(hwndTop); causes focus problems
    1159                     if (win32top && !win32top->isFakeWindow()) {
     1160                    if (win32top) {
    11601161                        //Must use client window handle (not frame!!)
    11611162                        SetFocus(win32top->getWindowHandle());
     
    26252626            NotifyFrameChanged(&wpos, &oldClientRect);
    26262627        }
    2627         if(!fShowWindow && !(getStyle() & WS_MINIMIZE) && !(fuFlags & (SWP_NOSIZE | SWP_NOMOVE)))
     2628        if(!fShowWindow && !(getStyle() & (WS_MINIMIZE|WS_MAXIMIZE)) && !(fuFlags & (SWP_NOSIZE | SWP_NOMOVE)))
    26282629        {
    26292630            //Restore position always changes when the window position is changed
     
    27002701        NotifyFrameChanged(&wpos, &oldClientRect);
    27012702    }
    2702     if(!fShowWindow && !(getStyle() & WS_MINIMIZE))
     2703    if(!fShowWindow && !(getStyle() & (WS_MINIMIZE|WS_MAXIMIZE)))
    27032704    {
    27042705        //Restore position always changes when the window position is changed
     
    36173618}
    36183619//******************************************************************************
    3619 //WM_ENABLE is sent to hwnd, but not to it's children (as it should be)
     3620//WM_ENABLE is sent to hwnd, but not to its children (as it should be)
    36203621//******************************************************************************
    36213622BOOL Win32BaseWindow::EnableWindow(BOOL fEnable)
     
    41154116    }
    41164117//  dprintf2(("Win32BaseWindow::GetWindowFromOS2Handle: not an Odin os2 window %x", hwndOS2));
     4118
     4119    //Now check if it's a fake window
     4120    Win32FakeWindow *window = Win32FakeWindow::GetWindowFromOS2Handle(hwndOS2);
     4121    if(window) {
     4122        return window;
     4123    }
    41174124    return 0;
    41184125}
Note: See TracChangeset for help on using the changeset viewer.