From 5888ae934be6f520b770898ca7f973462217d667 Mon Sep 17 00:00:00 2001 From: WolfGangS Date: Fri, 27 Jun 2025 21:49:56 +0100 Subject: Fixes for first click moap --- indra/newview/lltoolpie.cpp | 8 +------- indra/newview/lltoolpie.h | 11 ++++------- .../newview/skins/default/xui/en/panel_preferences_sound.xml | 10 +++++----- 3 files changed, 10 insertions(+), 19 deletions(-) diff --git a/indra/newview/lltoolpie.cpp b/indra/newview/lltoolpie.cpp index e5bbc73af0..ac51a9fa3e 100644 --- a/indra/newview/lltoolpie.cpp +++ b/indra/newview/lltoolpie.cpp @@ -1520,14 +1520,8 @@ bool LLToolPie::shouldAllowFirstMediaInteraction(const LLPickInfo& pick, bool mo LL_DEBUGS_ONCE() << "FirstClickPref == MEDIA_FIRST_CLICK_NONE" << LL_ENDL; return false; } - // All objects (overriding PRIM_MEDIA_FIRST_CLICK_INTERACT) - if(FirstClickPref == MEDIA_FIRST_CLICK_ALL) - { - LL_DEBUGS_ONCE() << "FirstClickPref & MEDIA_FIRST_CLICK_ALL" << LL_ENDL; - return true; - } // Every check beyond this point requires PRIM_MEDIA_FIRST_CLICK_INTERACT to be TRUE - if(!moap_flag) + if(!moap_flag && !(FirstClickPref & MEDIA_FIRST_BYPASS_MOAP_FLAG)) { LL_DEBUGS_ONCE() << "PRIM_MEDIA_FIRST_CLICK_INTERACT not set" << LL_ENDL; return false; diff --git a/indra/newview/lltoolpie.h b/indra/newview/lltoolpie.h index f88fc00b4a..b2175a67e8 100644 --- a/indra/newview/lltoolpie.h +++ b/indra/newview/lltoolpie.h @@ -98,15 +98,12 @@ private: MEDIA_FIRST_CLICK_FRIEND = 1 << 3, // 0b00001000 (8) MEDIA_FIRST_CLICK_LAND = 1 << 4, // 0b00010000 (16) - // Covers any object with PRIM_MEDIA_FIRST_CLICK_INTERACT (combines all other flags) - MEDIA_FIRST_CLICK_ANY = MEDIA_FIRST_CLICK_HUD & - MEDIA_FIRST_CLICK_OWN & - MEDIA_FIRST_CLICK_GROUP & - MEDIA_FIRST_CLICK_FRIEND & - MEDIA_FIRST_CLICK_LAND, + // Covers any object with PRIM_MEDIA_FIRST_CLICK_INTERACT (combines all previous flags) + MEDIA_FIRST_CLICK_ANY = 1073741823,// 0b00111111111111111111111111111111 + // // Covers all media regardless of other rules or PRIM_MEDIA_FIRST_CLICK_INTERACT - MEDIA_FIRST_CLICK_ALL = 1 << 30 // 0b01000000000000000000000000000000 (1073741824) + MEDIA_FIRST_BYPASS_MOAP_FLAG = 1 << 30 // 0b01000000000000000000000000000000 (1073741824) }; bool shouldAllowFirstMediaInteraction(const LLPickInfo& info, bool moap_flag); bool handleMediaClick(const LLPickInfo& info); diff --git a/indra/newview/skins/default/xui/en/panel_preferences_sound.xml b/indra/newview/skins/default/xui/en/panel_preferences_sound.xml index efe3d4fb42..d84b025d37 100644 --- a/indra/newview/skins/default/xui/en/panel_preferences_sound.xml +++ b/indra/newview/skins/default/xui/en/panel_preferences_sound.xml @@ -409,20 +409,20 @@ value="3"/> + name="media_first_click_friend" + value="11"/> + value="1073741823"/> Date: Fri, 27 Jun 2025 21:51:44 +0100 Subject: Make sure all moap option, includes 'all' --- indra/newview/skins/default/xui/en/panel_preferences_sound.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/indra/newview/skins/default/xui/en/panel_preferences_sound.xml b/indra/newview/skins/default/xui/en/panel_preferences_sound.xml index d84b025d37..d4fe8b2e79 100644 --- a/indra/newview/skins/default/xui/en/panel_preferences_sound.xml +++ b/indra/newview/skins/default/xui/en/panel_preferences_sound.xml @@ -426,7 +426,7 @@ + value="2147483647"/> Date: Fri, 27 Jun 2025 21:57:51 +0100 Subject: Fix enum option name --- indra/newview/lltoolpie.cpp | 2 +- indra/newview/lltoolpie.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/indra/newview/lltoolpie.cpp b/indra/newview/lltoolpie.cpp index ac51a9fa3e..75b980d358 100644 --- a/indra/newview/lltoolpie.cpp +++ b/indra/newview/lltoolpie.cpp @@ -1521,7 +1521,7 @@ bool LLToolPie::shouldAllowFirstMediaInteraction(const LLPickInfo& pick, bool mo return false; } // Every check beyond this point requires PRIM_MEDIA_FIRST_CLICK_INTERACT to be TRUE - if(!moap_flag && !(FirstClickPref & MEDIA_FIRST_BYPASS_MOAP_FLAG)) + if(!moap_flag && !(FirstClickPref & MEDIA_FIRST_CLICK_BYPASS_MOAP_FLAG)) { LL_DEBUGS_ONCE() << "PRIM_MEDIA_FIRST_CLICK_INTERACT not set" << LL_ENDL; return false; diff --git a/indra/newview/lltoolpie.h b/indra/newview/lltoolpie.h index b2175a67e8..ce02ea7d60 100644 --- a/indra/newview/lltoolpie.h +++ b/indra/newview/lltoolpie.h @@ -103,7 +103,7 @@ private: // // Covers all media regardless of other rules or PRIM_MEDIA_FIRST_CLICK_INTERACT - MEDIA_FIRST_BYPASS_MOAP_FLAG = 1 << 30 // 0b01000000000000000000000000000000 (1073741824) + MEDIA_FIRST_CLICK_BYPASS_MOAP_FLAG = 1 << 30 // 0b01000000000000000000000000000000 (1073741824) }; bool shouldAllowFirstMediaInteraction(const LLPickInfo& info, bool moap_flag); bool handleMediaClick(const LLPickInfo& info); -- cgit v1.2.3 From 13a8e3b830bfcf67d4376165f74da4def6947fce Mon Sep 17 00:00:00 2001 From: WolfGangS Date: Fri, 27 Jun 2025 22:19:43 +0100 Subject: Reviewed changes --- indra/newview/lltoolpie.h | 3 +-- indra/newview/skins/default/xui/en/panel_preferences_sound.xml | 4 ++-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/indra/newview/lltoolpie.h b/indra/newview/lltoolpie.h index ce02ea7d60..ee7945d16f 100644 --- a/indra/newview/lltoolpie.h +++ b/indra/newview/lltoolpie.h @@ -99,8 +99,7 @@ private: MEDIA_FIRST_CLICK_LAND = 1 << 4, // 0b00010000 (16) // Covers any object with PRIM_MEDIA_FIRST_CLICK_INTERACT (combines all previous flags) - MEDIA_FIRST_CLICK_ANY = 1073741823,// 0b00111111111111111111111111111111 - // + MEDIA_FIRST_CLICK_ANY = ~(3<<30), // 0b00111111111111111111111111111111 // Covers all media regardless of other rules or PRIM_MEDIA_FIRST_CLICK_INTERACT MEDIA_FIRST_CLICK_BYPASS_MOAP_FLAG = 1 << 30 // 0b01000000000000000000000000000000 (1073741824) diff --git a/indra/newview/skins/default/xui/en/panel_preferences_sound.xml b/indra/newview/skins/default/xui/en/panel_preferences_sound.xml index d4fe8b2e79..473e54812d 100644 --- a/indra/newview/skins/default/xui/en/panel_preferences_sound.xml +++ b/indra/newview/skins/default/xui/en/panel_preferences_sound.xml @@ -408,7 +408,7 @@ name="media_first_click_own" value="3"/>