LibreOffice Module vcl (master) 1
|
#include <gtksalmenu.hxx>
Public Member Functions | |
GtkSalMenu (bool bMenuBar) | |
virtual | ~GtkSalMenu () override |
virtual bool | VisibleMenuBar () override |
virtual void | InsertItem (SalMenuItem *pSalMenuItem, unsigned nPos) override |
virtual void | RemoveItem (unsigned nPos) override |
virtual void | SetSubMenu (SalMenuItem *pSalMenuItem, SalMenu *pSubMenu, unsigned nPos) override |
virtual void | SetFrame (const SalFrame *pFrame) override |
const GtkSalFrame * | GetFrame () const |
virtual void | CheckItem (unsigned nPos, bool bCheck) override |
virtual void | EnableItem (unsigned nPos, bool bEnable) override |
virtual void | ShowItem (unsigned nPos, bool bShow) override |
virtual void | SetItemText (unsigned nPos, SalMenuItem *pSalMenuItem, const OUString &rText) override |
virtual void | SetItemImage (unsigned nPos, SalMenuItem *pSalMenuItem, const Image &rImage) override |
virtual void | SetAccelerator (unsigned nPos, SalMenuItem *pSalMenuItem, const vcl::KeyCode &rKeyCode, const OUString &rKeyName) override |
virtual void | GetSystemMenuData (SystemMenuData *pData) override |
void | SetMenu (Menu *pMenu) |
Menu * | GetMenu () |
void | SetMenuModel (GMenuModel *pMenuModel) |
unsigned | GetItemCount () const |
GtkSalMenuItem * | GetItemAtPos (unsigned nPos) |
void | SetActionGroup (GActionGroup *pActionGroup) |
bool | IsItemVisible (unsigned nPos) |
void | NativeSetItemText (unsigned nSection, unsigned nItemPos, const OUString &rText) |
void | NativeSetItemIcon (unsigned nSection, unsigned nItemPos, const Image &rImage) |
bool | NativeSetItemCommand (unsigned nSection, unsigned nItemPos, sal_uInt16 nId, const gchar *aCommand, MenuItemBits nBits, bool bChecked, bool bIsSubmenu) |
void | NativeSetEnableItem (gchar const *aCommand, gboolean bEnable) |
void | NativeCheckItem (unsigned nSection, unsigned nItemPos, MenuItemBits bits, gboolean bCheck) |
void | NativeSetAccelerator (unsigned nSection, unsigned nItemPos, const vcl::KeyCode &rKeyCode, std::u16string_view rKeyName) |
void | EnableUnity (bool bEnable) |
virtual void | ShowMenuBar (bool bVisible) override |
bool | PrepUpdate () const |
virtual void | Update () override |
void | UpdateFull () |
void | ClearActionGroupAndMenuModel () |
GtkSalMenu * | GetTopLevel () |
void | SetNeedsUpdate () |
GtkWidget * | GetMenuBarWidget () const |
GtkWidget * | GetMenuBarContainerWidget () const |
void | CreateMenuBarWidget () |
void | DestroyMenuBarWidget () |
gboolean | SignalKey (GdkEventKey const *pEvent) |
void | ReturnFocus () |
virtual bool | ShowNativePopupMenu (FloatingWindow *pWin, const tools::Rectangle &rRect, FloatWinPopupFlags nFlags) override |
virtual void | ShowCloseButton (bool bShow) override |
virtual bool | AddMenuBarButton (const SalMenuButtonItem &rNewItem) override |
virtual void | RemoveMenuBarButton (sal_uInt16 nId) override |
virtual tools::Rectangle | GetMenuBarButtonRectPixel (sal_uInt16 i_nItemId, SalFrame *i_pReferenceFrame) override |
virtual bool | CanGetFocus () const override |
virtual bool | TakeFocus () override |
virtual int | GetMenuBarHeight () const override |
virtual void | ApplyPersona () override |
Public Member Functions inherited from SalMenu | |
virtual | ~SalMenu () |
virtual bool | VisibleMenuBar ()=0 |
virtual void | ShowMenuBar (bool) |
virtual void | InsertItem (SalMenuItem *pSalMenuItem, unsigned nPos)=0 |
virtual void | RemoveItem (unsigned nPos)=0 |
virtual void | SetSubMenu (SalMenuItem *pSalMenuItem, SalMenu *pSubMenu, unsigned nPos)=0 |
virtual void | SetFrame (const SalFrame *pFrame)=0 |
virtual void | SetItemBits (unsigned, MenuItemBits) |
virtual void | CheckItem (unsigned nPos, bool bCheck)=0 |
virtual void | EnableItem (unsigned nPos, bool bEnable)=0 |
virtual void | SetItemText (unsigned nPos, SalMenuItem *pSalMenuItem, const OUString &rText)=0 |
virtual void | SetItemImage (unsigned nPos, SalMenuItem *pSalMenuItem, const Image &rImage)=0 |
virtual void | SetAccelerator (unsigned nPos, SalMenuItem *pSalMenuItem, const vcl::KeyCode &rKeyCode, const OUString &rKeyName)=0 |
virtual void | GetSystemMenuData (SystemMenuData *pData)=0 |
virtual bool | ShowNativePopupMenu (FloatingWindow *pWin, const tools::Rectangle &rRect, FloatWinPopupFlags nFlags) |
virtual void | ShowCloseButton (bool bShow) |
virtual bool | AddMenuBarButton (const SalMenuButtonItem &) |
virtual void | RemoveMenuBarButton (sal_uInt16 nId) |
virtual void | Update () |
virtual bool | CanGetFocus () const |
virtual bool | TakeFocus () |
virtual void | ShowItem (unsigned nPos, bool bShow) |
virtual tools::Rectangle | GetMenuBarButtonRectPixel (sal_uInt16 i_nItemId, SalFrame *i_pReferenceFrame) |
virtual int | GetMenuBarHeight () const |
virtual void | ApplyPersona () |
Static Public Member Functions | |
static void | DispatchCommand (const gchar *pMenuCommand) |
static void | Activate (const gchar *pMenuCommand) |
static void | Deactivate (const gchar *pMenuCommand) |
Private Member Functions | |
void | ImplUpdate (bool bRecurse, bool bRemoveDisabledEntries) |
void | ActivateAllSubmenus (Menu *pMenuBar) |
DECL_LINK (MenuBarHierarchyChangeHandler, Timer *, void) | |
Static Private Member Functions | |
static GtkWidget * | AddButton (GtkWidget *pImage) |
Private Attributes | |
std::vector< GtkSalMenuItem * > | maItems |
std::vector< std::pair< sal_uInt16, GtkWidget * > > | maExtraButtons |
Idle | maUpdateMenuBarIdle |
bool | mbInActivateCallback |
bool | mbMenuBar |
bool | mbNeedsUpdate |
bool | mbReturnFocusToDocument |
bool | mbAddedGrab |
bool | mbHasNullItemIcon = true |
Even setting null icon on a menuitem can be expensive, so cache state to avoid that call. More... | |
GtkWidget * | mpMenuBarContainerWidget |
std::unique_ptr< utl::TempFileNamed > | mxPersonaImage |
BitmapEx | maPersonaBitmap |
GtkWidget * | mpMenuAllowShrinkWidget |
GtkWidget * | mpMenuBarWidget |
GtkWidget * | mpMenuWidget |
GtkCssProvider * | mpMenuBarContainerProvider |
GtkCssProvider * | mpMenuBarProvider |
GtkWidget * | mpCloseButton |
VclPtr< Menu > | mpVCLMenu |
GtkSalMenu * | mpParentSalMenu |
GtkSalFrame * | mpFrame |
GMenuModel * | mpMenuModel |
GActionGroup * | mpActionGroup |
Definition at line 32 of file gtksalmenu.hxx.
GtkSalMenu::GtkSalMenu | ( | bool | bMenuBar | ) |
|
overridevirtual |
|
static |
|
private |
Referenced by UpdateFull().
|
overridevirtual |
Reimplemented from SalMenu.
|
overridevirtual |
Reimplemented from SalMenu.
|
overridevirtual |
Reimplemented from SalMenu.
|
overridevirtual |
Implements SalMenu.
void GtkSalMenu::ClearActionGroupAndMenuModel | ( | ) |
void GtkSalMenu::CreateMenuBarWidget | ( | ) |
|
static |
|
private |
void GtkSalMenu::DestroyMenuBarWidget | ( | ) |
|
static |
|
overridevirtual |
Implements SalMenu.
void GtkSalMenu::EnableUnity | ( | bool | bEnable | ) |
const GtkSalFrame * GtkSalMenu::GetFrame | ( | ) | const |
|
inline |
Definition at line 94 of file gtksalmenu.hxx.
|
inline |
Definition at line 93 of file gtksalmenu.hxx.
References maItems.
|
inline |
Definition at line 91 of file gtksalmenu.hxx.
References mpVCLMenu.
|
overridevirtual |
Reimplemented from SalMenu.
|
inline |
Definition at line 126 of file gtksalmenu.hxx.
References mpMenuBarContainerWidget.
|
inline |
Definition at line 125 of file gtksalmenu.hxx.
References mpMenuBarWidget.
|
overridevirtual |
Implements SalMenu.
GtkSalMenu * GtkSalMenu::GetTopLevel | ( | ) |
|
private |
|
overridevirtual |
Implements SalMenu.
bool GtkSalMenu::IsItemVisible | ( | unsigned | nPos | ) |
void GtkSalMenu::NativeCheckItem | ( | unsigned | nSection, |
unsigned | nItemPos, | ||
MenuItemBits | bits, | ||
gboolean | bCheck | ||
) |
void GtkSalMenu::NativeSetAccelerator | ( | unsigned | nSection, |
unsigned | nItemPos, | ||
const vcl::KeyCode & | rKeyCode, | ||
std::u16string_view | rKeyName | ||
) |
void GtkSalMenu::NativeSetEnableItem | ( | gchar const * | aCommand, |
gboolean | bEnable | ||
) |
bool GtkSalMenu::NativeSetItemCommand | ( | unsigned | nSection, |
unsigned | nItemPos, | ||
sal_uInt16 | nId, | ||
const gchar * | aCommand, | ||
MenuItemBits | nBits, | ||
bool | bChecked, | ||
bool | bIsSubmenu | ||
) |
void GtkSalMenu::NativeSetItemIcon | ( | unsigned | nSection, |
unsigned | nItemPos, | ||
const Image & | rImage | ||
) |
void GtkSalMenu::NativeSetItemText | ( | unsigned | nSection, |
unsigned | nItemPos, | ||
const OUString & | rText | ||
) |
bool GtkSalMenu::PrepUpdate | ( | ) | const |
|
overridevirtual |
Implements SalMenu.
|
overridevirtual |
Reimplemented from SalMenu.
void GtkSalMenu::ReturnFocus | ( | ) |
|
overridevirtual |
Implements SalMenu.
|
inline |
Definition at line 95 of file gtksalmenu.hxx.
References mpActionGroup.
|
overridevirtual |
Implements SalMenu.
|
overridevirtual |
Implements SalMenu.
|
inline |
Definition at line 90 of file gtksalmenu.hxx.
References mpVCLMenu.
void GtkSalMenu::SetMenuModel | ( | GMenuModel * | pMenuModel | ) |
void GtkSalMenu::SetNeedsUpdate | ( | ) |
|
overridevirtual |
Implements SalMenu.
|
overridevirtual |
Reimplemented from SalMenu.
|
overridevirtual |
Reimplemented from SalMenu.
|
overridevirtual |
Reimplemented from SalMenu.
|
overridevirtual |
Reimplemented from SalMenu.
gboolean GtkSalMenu::SignalKey | ( | GdkEventKey const * | pEvent | ) |
|
overridevirtual |
Reimplemented from SalMenu.
|
overridevirtual |
Reimplemented from SalMenu.
|
inline |
Definition at line 119 of file gtksalmenu.hxx.
References ActivateAllSubmenus(), and mpVCLMenu.
|
overridevirtual |
Implements SalMenu.
|
private |
Definition at line 36 of file gtksalmenu.hxx.
|
private |
Definition at line 35 of file gtksalmenu.hxx.
Referenced by GetItemAtPos(), and GetItemCount().
|
private |
Definition at line 48 of file gtksalmenu.hxx.
|
private |
Definition at line 37 of file gtksalmenu.hxx.
|
private |
Definition at line 43 of file gtksalmenu.hxx.
|
private |
Even setting null icon on a menuitem can be expensive, so cache state to avoid that call.
Definition at line 45 of file gtksalmenu.hxx.
|
private |
Definition at line 39 of file gtksalmenu.hxx.
|
private |
Definition at line 40 of file gtksalmenu.hxx.
|
private |
Definition at line 41 of file gtksalmenu.hxx.
|
private |
Definition at line 42 of file gtksalmenu.hxx.
|
private |
Definition at line 61 of file gtksalmenu.hxx.
Referenced by SetActionGroup().
|
private |
Definition at line 54 of file gtksalmenu.hxx.
|
private |
Definition at line 57 of file gtksalmenu.hxx.
|
private |
Definition at line 49 of file gtksalmenu.hxx.
|
private |
Definition at line 52 of file gtksalmenu.hxx.
|
private |
Definition at line 46 of file gtksalmenu.hxx.
Referenced by GetMenuBarContainerWidget().
|
private |
Definition at line 53 of file gtksalmenu.hxx.
|
private |
Definition at line 50 of file gtksalmenu.hxx.
Referenced by GetMenuBarWidget().
|
private |
Definition at line 60 of file gtksalmenu.hxx.
|
private |
Definition at line 51 of file gtksalmenu.hxx.
|
private |
Definition at line 56 of file gtksalmenu.hxx.
Definition at line 55 of file gtksalmenu.hxx.
Referenced by GetMenu(), SetMenu(), and UpdateFull().
|
private |
Definition at line 47 of file gtksalmenu.hxx.