X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/2d36b3d84768e49e8693ba1c42f8358bb45b1f0f..0f07e3dc2480b6a9e963162fe9bf53495b3f1f71:/src/msw/toplevel.cpp diff --git a/src/msw/toplevel.cpp b/src/msw/toplevel.cpp index 9c1391dbbe..47bc5ff54a 100644 --- a/src/msw/toplevel.cpp +++ b/src/msw/toplevel.cpp @@ -41,6 +41,7 @@ #include "wx/module.h" #include "wx/msw/private.h" +#include "wx/msw/missing.h" #if defined(__WXWINCE__) #include @@ -514,6 +515,23 @@ bool wxTopLevelWindowMSW::Create(wxWindow *parent, EnableCloseButton(false); } + // for some reason we need to manually send ourselves this message as + // otherwise the mnemonics are always shown -- even if they're configured + // to be hidden until "Alt" is pressed in the control panel + // + // this could indicate a bug somewhere else but for now this is the only + // fix we have + if ( ret ) + { + SendMessage + ( + GetHwnd(), + WM_UPDATEUISTATE, + MAKEWPARAM(UIS_INITIALIZE, UISF_HIDEFOCUS | UISF_HIDEACCEL), + 0 + ); + } + return ret; } @@ -740,7 +758,7 @@ bool wxTopLevelWindowMSW::ShowFullScreen(bool show, long style) rect.x, rect.y, rect.width, rect.height, flags); -#if __WXWINCE__ && _WIN32_WCE < 400 +#if defined(__WXWINCE__) && _WIN32_WCE < 400 ::SHFullScreen(GetHwnd(), SHFS_HIDETASKBAR | SHFS_HIDESIPBUTTON); #endif @@ -750,7 +768,7 @@ bool wxTopLevelWindowMSW::ShowFullScreen(bool show, long style) } else // stop showing full screen { -#if __WXWINCE__ && _WIN32_WCE < 400 +#if defined(__WXWINCE__) && _WIN32_WCE < 400 ::SHFullScreen(GetHwnd(), SHFS_SHOWTASKBAR | SHFS_SHOWSIPBUTTON); #endif Maximize(m_fsIsMaximized);