]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk1/menu.cpp
corrected name of wxWS_EX_PROCESS_UI_UPDATES style (part of patch 1686335)
[wxWidgets.git] / src / gtk1 / menu.cpp
index 10fee257c64899a109fb7768d8005927c5129b33..32295957b91943d7244744de2d4f96fe0e4f738f 100644 (file)
@@ -769,10 +769,11 @@ wxString wxMenuItemBase::GetLabelFromText(const wxString& text)
 void wxMenuItem::SetText( const wxString& string )
 {
     wxString str = string;
-    if (str.IsEmpty())
+    if ( str.empty() && !IsSeparator() )
     {
         wxASSERT_MSG(wxIsStockID(GetId()), wxT("A non-stock menu item with an empty label?"));
-        str = wxGetStockLabel(GetId(), wxSTOCK_WITH_ACCELERATOR|wxSTOCK_WITH_MNEMONIC);
+        str = wxGetStockLabel(GetId(), wxSTOCK_WITH_ACCELERATOR |
+                                       wxSTOCK_WITH_MNEMONIC);
     }
 
     // Some optimization to avoid flicker
@@ -1243,10 +1244,10 @@ static wxString GetGtkHotKey( const wxMenuItem& item )
                 hotkey << wxT("Down" );
                 break;
             case WXK_PAGEUP:
-                hotkey << wxT("PgUp" );
+                hotkey << wxT("Page_Up" );
                 break;
             case WXK_PAGEDOWN:
-                hotkey << wxT("PgDn" );
+                hotkey << wxT("Page_Down" );
                 break;
             case WXK_LEFT:
                 hotkey << wxT("Left" );
@@ -1364,10 +1365,10 @@ static wxString GetGtkHotKey( const wxMenuItem& item )
                 hotkey << wxT("KP_Down" );
                 break;
             case WXK_NUMPAD_PAGEUP:
-                hotkey << wxT("KP_PgUp" );
+                hotkey << wxT("KP_Page_Up" );
                 break;
             case WXK_NUMPAD_PAGEDOWN:
-                hotkey << wxT("KP_PgDn" );
+                hotkey << wxT("KP_Page_Down" );
                 break;
             case WXK_NUMPAD_END:
                 hotkey << wxT("KP_End" );