]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/menuitem.cpp
merged new strings into updated translation
[wxWidgets.git] / src / msw / menuitem.cpp
index 8b9127fe3f994bdf6680902d901c98e0fae02d25..e4a9d1beb90e7e780156978fd013249bdabd1541 100644 (file)
@@ -170,9 +170,13 @@ void wxMenuItem::Init()
 
     #undef  SYS_COLOR
 
-    // we don't want normal items be owner-drawn
+    // setting default colors switched ownerdraw on: switch it off again
     ResetOwnerDrawn();
 
+    //  switch ownerdraw back on if using a non default margin
+    if ( GetId() != wxID_SEPARATOR )
+        SetMarginWidth(GetMarginWidth());
+
     // tell the owner drawing code to to show the accel string as well
     SetAccelString(m_text.AfterFirst(_T('\t')));
 #endif // wxUSE_OWNER_DRAWN
@@ -330,7 +334,7 @@ void wxMenuItem::Check(bool check)
                              GetRealId(),
                              MF_BYCOMMAND | flags) == (DWORD)-1 )
         {
-            wxLogLastError(wxT("CheckMenuItem"));
+            wxFAIL_MSG( _T("CheckMenuItem() failed, item not in the menu?") );
         }
     }