From e3ba75101a94cff9b1409c58f796587cf2702f10 Mon Sep 17 00:00:00 2001 From: Mnikolenko Productengine Date: Thu, 21 Sep 2023 14:41:00 +0300 Subject: DRTVWR-589 - adding menu items to the top menu --- indra/llui/llmenugl.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'indra/llui') diff --git a/indra/llui/llmenugl.h b/indra/llui/llmenugl.h index 9d3be8d94f..1a330b18cc 100644 --- a/indra/llui/llmenugl.h +++ b/indra/llui/llmenugl.h @@ -555,11 +555,12 @@ public: // add a context menu branch BOOL appendContextSubMenu(LLMenuGL *menu); + // Add the menu item to this menu. + virtual BOOL append( LLMenuItemGL* item ); + protected: void createSpilloverBranch(); void cleanupSpilloverBranch(); - // Add the menu item to this menu. - virtual BOOL append( LLMenuItemGL* item ); // add a menu - this will create a cascading menu virtual BOOL appendMenu( LLMenuGL* menu ); @@ -798,9 +799,10 @@ public: void resetMenuTrigger() { mAltKeyTrigger = FALSE; } + // add a menu - this will create a drop down menu. + virtual BOOL appendMenu(LLMenuGL *menu); + private: - // add a menu - this will create a drop down menu. - virtual BOOL appendMenu( LLMenuGL* menu ); // rearrange the child rects so they fit the shape of the menu // bar. virtual void arrange( void ); -- cgit v1.2.3 From fac31ad392c3df22b2254a00e75c841050195763 Mon Sep 17 00:00:00 2001 From: Mnikolenko Productengine Date: Thu, 21 Sep 2023 16:16:00 +0300 Subject: DRTVWR-589 - allow adding branch to the menu --- indra/llui/llmenugl.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'indra/llui') diff --git a/indra/llui/llmenugl.h b/indra/llui/llmenugl.h index 1a330b18cc..4f1098b1d8 100644 --- a/indra/llui/llmenugl.h +++ b/indra/llui/llmenugl.h @@ -558,13 +558,13 @@ public: // Add the menu item to this menu. virtual BOOL append( LLMenuItemGL* item ); + // add a menu - this will create a cascading menu + virtual BOOL appendMenu(LLMenuGL *menu); + protected: void createSpilloverBranch(); void cleanupSpilloverBranch(); - // add a menu - this will create a cascading menu - virtual BOOL appendMenu( LLMenuGL* menu ); - // Used in LLContextMenu and in LLTogleableMenu // to add an item of context menu branch bool addContextChild(LLView* view, S32 tab_group); -- cgit v1.2.3 From de61551df3219dae2238591bae5fa7b6c857e6b0 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Sat, 30 Sep 2023 11:51:09 -0400 Subject: DRTVWR-589: Emulate print() better, show output on Lua floater. Break out a lua_print_msg() function common to print_debug(), print_info() and print_warning(). Instead of accepting a single argument, lua_print_msg() accepts arbitrary arguments, passing each to the Lua tostring() function and concatenating the results. In addition to returning the combined string to its caller for level-appropriate logging, it also posts the message to a "lua output" LLEventPump for any interested party. Make LLFloaterLUADebug listen on "lua output" when the floater is constructed, storing the connection in an LLTempBoundListener to stop listening when the floater is destroyed. Append each message to the floater's output panel with a line break. Make LLTextEditor::addLineBreakChar() public. insertText("\n") only appends a little rectangle glyph. Enlarge the text capacity of the floater's output panel to be able to report whatever messages a Lua script wants to print. Add diagnostic logging for posting events from Lua, and receiving events to forward to Lua. Since lua_pop() is a macro implemented on lua_settop(), replace the awkward construct lua_pop(L, lua_gettop(L)) with lua_settop(L, 0). Use lambdas instead of std::bind() to connect LuaListener and LLLeapListener. --- indra/llui/lltexteditor.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'indra/llui') diff --git a/indra/llui/lltexteditor.h b/indra/llui/lltexteditor.h index f3939248c2..ec2b9a4b7d 100644 --- a/indra/llui/lltexteditor.h +++ b/indra/llui/lltexteditor.h @@ -241,7 +241,9 @@ protected: // Undoable operations void addChar(llwchar c); // at mCursorPos S32 addChar(S32 pos, llwchar wc); +public: void addLineBreakChar(BOOL group_together = FALSE); +protected: S32 overwriteChar(S32 pos, llwchar wc); void removeChar(); S32 removeChar(S32 pos); -- cgit v1.2.3