![]() |
Clapkit
|
Defines a menubar for the application. More...
#include <ckMenu.h>
Public Member Functions | |
CKMenuBar (bool createStandardItems=false) | |
Create a new menubar. | |
virtual | ~CKMenuBar () |
void | AddMenu (CKMenu *item) |
Add a menu item to the bar. | |
void | AddSystemMenuItem (CKMenu *item) |
Add the menu to Apple Menu (Classic Mac OS) or App Menu (OS X) | |
void | RemoveMenu (CKMenu *item) |
Remove item from the menu bar. | |
bool | HasMenu (CKMenu *item) |
Check if item is already in this menubar. | |
bool | HasMenuItem (CKMenuItem *item) |
Check if item is already in this any of the menus. | |
CKMenu * | GetStdFileMenu () |
CKMenu * | GetStdEditMenu () |
![]() | |
CKObject () | |
virtual | ~CKObject () |
virtual void | AddHandler (CKEventType type, CKEventHandlerFunc cb) |
virtual void | RemoveHandler (CKEventType type) |
virtual bool | HasHandler (CKEventType type) const |
virtual bool | HandleEvent (const CKEvent &evt) |
virtual void | SetPropertyObserver (CKPropertyObserverFunc cb) |
virtual void | UnsetPropertyObserver () |
virtual void | RaisePropertyChange (const char *propertyName) |
Protected Attributes | |
std::vector< CKMenuItem * > | appleMenuItems |
std::vector< CKMenu * > | items |
![]() | |
std::map< CKEventType, CKEventHandlerFunc > | __handlers |
CKPropertyObserverFunc | propertyObserverCB = nullptr |
Friends | |
class | CKApp |
Defines a menubar for the application.
CKMenuBar::CKMenuBar | ( | bool | createStandardItems = false | ) |
Create a new menubar.
createStandardItems | Adds "File" and "Edit" menus and their items if true. |
|
virtual |
void CKMenuBar::AddMenu | ( | CKMenu * | item | ) |
Add a menu item to the bar.
void CKMenuBar::AddSystemMenuItem | ( | CKMenu * | item | ) |
Add the menu to Apple Menu (Classic Mac OS) or App Menu (OS X)
|
inline |
|
inline |
bool CKMenuBar::HasMenu | ( | CKMenu * | item | ) |
Check if item is already in this menubar.
bool CKMenuBar::HasMenuItem | ( | CKMenuItem * | item | ) |
Check if item is already in this any of the menus.
void CKMenuBar::RemoveMenu | ( | CKMenu * | item | ) |
Remove item from the menu bar.
|
friend |
|
protected |
|
protected |