#include "wx/module.h"
#include "wx/msw/private.h"
+#include "wx/msw/missing.h"
#if defined(__WXWINCE__)
#include <ole2.h>
// wxTopLevelWindowMSW creation
// ----------------------------------------------------------------------------
-wxTopLevelWindowMSW::wxTopLevelWindowMSW()
-{
- Init();
-}
-
-wxTopLevelWindowMSW::wxTopLevelWindowMSW(wxWindow *parent,
- wxWindowID id,
- const wxString& title,
- const wxPoint& pos,
- const wxSize& size,
- long style,
- const wxString& name)
-{
- Init();
-
- (void)Create(parent, id, title, pos, size, style, name);
-}
-
void wxTopLevelWindowMSW::Init()
{
m_iconized =
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;
}