summaryrefslogtreecommitdiff
path: root/indra/llui/llmenugl.h
diff options
context:
space:
mode:
authorAndrey Lihatskiy <alihatskiy@productengine.com>2021-04-01 20:49:45 +0300
committerAndrey Lihatskiy <alihatskiy@productengine.com>2021-04-01 20:49:45 +0300
commit0bf68ce7363dc9114000a6a5a40de87f79b28f37 (patch)
treeacd4a2a3c1d6e83bc389cf99bf90c492bc383c9d /indra/llui/llmenugl.h
parent1fe0033a7e8dc2b68fb1e5a25144fa0bc719b1af (diff)
parent167e45e309ebeaccb346b8ca05884b8e10bf05eb (diff)
Merge branch 'master' into DRTVWR-483
Diffstat (limited to 'indra/llui/llmenugl.h')
-rw-r--r--indra/llui/llmenugl.h18
1 files changed, 14 insertions, 4 deletions
diff --git a/indra/llui/llmenugl.h b/indra/llui/llmenugl.h
index 1f11f26192..8cef9c6463 100644
--- a/indra/llui/llmenugl.h
+++ b/indra/llui/llmenugl.h
@@ -42,6 +42,13 @@
extern S32 MENU_BAR_HEIGHT;
extern S32 MENU_BAR_WIDTH;
+class LLMenuKeyboardBinding
+{
+public:
+ KEY mKey;
+ MASK mMask;
+};
+
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Class LLMenuItemGL
//
@@ -91,6 +98,7 @@ public:
/*virtual*/ void setValue(const LLSD& value);
/*virtual*/ LLSD getValue() const;
+ virtual bool hasAccelerator(const KEY &key, const MASK &mask) const;
virtual BOOL handleAcceleratorKey(KEY key, MASK mask);
LLColor4 getHighlightBgColor() { return mHighlightBackground.get(); }
@@ -109,7 +117,7 @@ public:
virtual void setBriefItem(BOOL brief);
virtual BOOL isBriefItem() const;
- virtual BOOL addToAcceleratorList(std::list<LLKeyBinding*> *listp);
+ virtual BOOL addToAcceleratorList(std::list<LLMenuKeyboardBinding*> *listp);
void setAllowKeyRepeat(BOOL allow) { mAllowKeyRepeat = allow; }
BOOL getAllowKeyRepeat() const { return mAllowKeyRepeat; }
@@ -436,7 +444,8 @@ public:
/*virtual*/ bool addChild(LLView* view, S32 tab_group = 0);
/*virtual*/ void removeChild( LLView* ctrl);
/*virtual*/ BOOL postBuild();
-
+
+ virtual bool hasAccelerator(const KEY &key, const MASK &mask) const;
virtual BOOL handleAcceleratorKey(KEY key, MASK mask);
LLMenuGL* findChildMenuByName(const std::string& name, BOOL recurse) const;
@@ -628,10 +637,11 @@ public:
virtual BOOL handleMouseUp(S32 x, S32 y, MASK mask);
+ virtual bool hasAccelerator(const KEY &key, const MASK &mask) const;
virtual BOOL handleAcceleratorKey(KEY key, MASK mask);
// check if we've used these accelerators already
- virtual BOOL addToAcceleratorList(std::list <LLKeyBinding*> *listp);
+ virtual BOOL addToAcceleratorList(std::list <LLMenuKeyboardBinding*> *listp);
// called to rebuild the draw label
virtual void buildDrawLabel( void );
@@ -797,7 +807,7 @@ private:
void checkMenuTrigger();
- std::list <LLKeyBinding*> mAccelerators;
+ std::list <LLMenuKeyboardBinding*> mAccelerators;
BOOL mAltKeyTrigger;
};