X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/717a57c2fabb054c8f00dc5dae70df1d03cfe532..b76f0023ae275de2d71ed735a95d2ecb81d4ea74:/include/wx/gtk1/menu.h diff --git a/include/wx/gtk1/menu.h b/include/wx/gtk1/menu.h index 07f1575111..123f23b86b 100644 --- a/include/wx/gtk1/menu.h +++ b/include/wx/gtk1/menu.h @@ -10,7 +10,7 @@ #ifndef __GTKMENUH__ #define __GTKMENUH__ -#ifdef __GNUG__ +#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) #pragma interface "menu.h" #endif @@ -45,8 +45,12 @@ public: void SetInvokingWindow( wxWindow *win ); void UnsetInvokingWindow( wxWindow *win ); + // common part of Append and Insert + bool GtkAppend(wxMenu *menu, const wxString& title); + +#ifndef __WXGTK20__ GtkAccelGroup *m_accel; - GtkItemFactory *m_factory; +#endif GtkWidget *m_menubar; long m_style; wxWindow *m_invokingWindow; @@ -71,20 +75,12 @@ public: virtual ~wxMenu(); // implement base class virtuals - virtual bool DoAppend(wxMenuItem *item); - virtual bool DoInsert(size_t pos, wxMenuItem *item); - virtual wxMenuItem *DoRemove(wxMenuItem *item); + virtual wxMenuItem* DoAppend(wxMenuItem *item); + virtual wxMenuItem* DoInsert(size_t pos, wxMenuItem *item); + virtual wxMenuItem* DoRemove(wxMenuItem *item); // TODO: virtual void SetTitle(const wxString& title); -#ifdef WXWIN_COMPATIBILITY - wxMenu(const wxString& title, const wxFunction func) - : wxMenuBase(title) - { - Callback(func); - } -#endif // WXWIN_COMPATIBILITY - // implementation int FindMenuIdByMenuItem( GtkWidget *menuItem ) const; @@ -92,12 +88,16 @@ public: GtkWidget *m_menu; // GtkMenu GtkWidget *m_owner; GtkAccelGroup *m_accel; - GtkItemFactory *m_factory; private: // common code for all constructors: void Init(); + // common part of Append and Insert + bool GtkAppend(wxMenuItem *item); + + GtkWidget *m_prevRadio; + DECLARE_DYNAMIC_CLASS(wxMenu) };