]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk1/menu.h
1 /////////////////////////////////////////////////////////////////////////////
4 // Author: Robert Roebling
7 // Copyright: (c) 1998 Robert Roebling, Julian Smart and Markus Holzem
8 // Licence: wxWindows licence
9 /////////////////////////////////////////////////////////////////////////////
20 #include "wx/object.h"
22 #include "wx/window.h"
24 //-----------------------------------------------------------------------------
26 //-----------------------------------------------------------------------------
32 //-----------------------------------------------------------------------------
34 //-----------------------------------------------------------------------------
36 class wxMenuBar
: public wxWindow
38 DECLARE_DYNAMIC_CLASS(wxMenuBar
)
43 void Append( wxMenu
*menu
, const wxString
&title
);
44 int FindMenuItem( const wxString
&menuString
, const wxString
&itemString
) const;
50 //-----------------------------------------------------------------------------
52 //-----------------------------------------------------------------------------
54 class wxMenuItem
: public wxObject
56 DECLARE_DYNAMIC_CLASS(wxMenuItem
)
71 GtkWidget
*m_menuItem
; // GtkMenuItem
75 class wxMenu
: public wxEvtHandler
77 DECLARE_DYNAMIC_CLASS(wxMenu
)
81 wxMenu( const wxString
&title
= "" );
82 void AppendSeparator(void);
83 void Append( const int id
, const wxString
&item
,
84 const wxString
&helpStr
= "", const bool checkable
= FALSE
);
85 void Append( const int id
, const wxString
&item
,
86 wxMenu
*subMenu
, const wxString
&helpStr
= "" );
87 int FindItem( const wxString itemString
) const;
89 void Enable( const int id
, const bool enable
);
90 bool Enabled( const int id
) const;
91 void SetLabel( const int id
, const wxString
&label
);
95 int FindMenuIdByMenuItem( GtkWidget
*menuItem
) const;
96 void SetInvokingWindow( wxWindow
*win
);
97 wxWindow
*GetInvokingWindow(void);
101 wxWindow
*m_invokingWindow
;
103 GtkWidget
*m_menu
; // GtkMenu
107 #endif // __GTKMENUH__