Cleaner ifdef's for Windows CE WindowExStyle. This allows dialogs on Windows CE to have an OKAY box instead of the minimize box. This change is WINCE only. b=297683 r/sr=dveditz, a=asa

This commit is contained in:
dougt%meer.net 2005-08-09 07:21:27 +00:00
parent 8f7328f4d3
commit 1dc95e376e

View File

@ -5474,6 +5474,33 @@ DWORD nsWindow::WindowStyle()
//-------------------------------------------------------------------------
DWORD nsWindow::WindowExStyle()
{
#ifdef WINCE
switch (mWindowType)
{
case eWindowType_child:
return 0;
case eWindowType_dialog:
return WS_EX_WINDOWEDGE | WS_EX_CAPTIONOKBTN;
case eWindowType_popup:
return WS_EX_TOOLWINDOW;
default:
NS_ASSERTION(0, "unknown border style");
// fall through
case eWindowType_toplevel:
case eWindowType_invisible:
if (gUseOkayButton)
return WS_EX_WINDOWEDGE | WS_EX_CAPTIONOKBTN;
else
return WS_EX_WINDOWEDGE;
}
#else
switch (mWindowType)
{
case eWindowType_child:
@ -5491,15 +5518,9 @@ DWORD nsWindow::WindowExStyle()
case eWindowType_toplevel:
case eWindowType_invisible:
#ifndef WINCE
return WS_EX_APPWINDOW | WS_EX_WINDOWEDGE;
#else
if (gUseOkayButton)
return WS_EX_WINDOWEDGE | WS_EX_CAPTIONOKBTN;
else
return WS_EX_WINDOWEDGE;
#endif
return WS_EX_APPWINDOW | WS_EX_WINDOWEDGE;
}
#endif
}