X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/938aa9c4618c9ed67fa791063681875106d3ef35..01a4679360888aa030c31ea194a676b12ed52b92:/include/wx/os2/menu.h diff --git a/include/wx/os2/menu.h b/include/wx/os2/menu.h index 944f3617eb..14205d6759 100644 --- a/include/wx/os2/menu.h +++ b/include/wx/os2/menu.h @@ -13,11 +13,11 @@ #define _WX_MENU_H_ #if wxUSE_ACCEL -// #include "wx/accel.h" -// #include "wx/list.h" // for "template" list classes -// #include "wx/dynarray.h" + #include "wx/accel.h" + #include "wx/list.h" // for "template" list classes + #include "wx/dynarray.h" -// WX_DECLARE_EXPORTED_LIST(wxAcceleratorEntry, wxAcceleratorList); + WX_DEFINE_EXPORTED_ARRAY(wxAcceleratorEntry *, wxAcceleratorArray); #endif // wxUSE_ACCEL class WXDLLEXPORT wxFrame; @@ -78,6 +78,8 @@ public: // Implementation only from now on // ------------------------------- // + virtual void Attach(wxMenuBarBase* pMenubar); + bool OS2Command( WXUINT uParam ,WXWORD wId ); @@ -100,8 +102,8 @@ public: // // Called by wxMenuBar to build its accel table from the accels of all menus // - bool HasAccels(void) const { return m_vAccels[0] != NULL; } - size_t GetAccelCount(void) const { return (size_t)m_nNextAccel; } + bool HasAccels(void) const { return m_vAccels.IsEmpty(); } + size_t GetAccelCount(void) const { return m_vAccels.GetCount(); } size_t CopyAccels(wxAcceleratorEntry* pAccels) const; // @@ -160,7 +162,7 @@ private: // // The helper variable for creating unique IDs. // - static USHORT m_nextMenuId; + static USHORT m_nextMenuId; // // The position of the first item in the current radio group or -1 @@ -171,8 +173,7 @@ private: // // The accelerators for our menu items // - wxAcceleratorEntry* m_vAccels[128]; - int m_nNextAccel; + wxAcceleratorArray m_vAccels; #endif // wxUSE_ACCEL DECLARE_DYNAMIC_CLASS(wxMenu)