summaryrefslogtreecommitdiff
path: root/indra/newview/llfloaterpreference.cpp
diff options
context:
space:
mode:
authorAndrey Lihatskiy <alihatskiy@productengine.com>2023-12-14 02:47:44 +0200
committerAndrey Lihatskiy <alihatskiy@productengine.com>2023-12-14 02:47:44 +0200
commit4b98ae6e8a4c54fa70246beb5d7ff28a5590e819 (patch)
tree11e49d0cb85d8420ac614f039b32e5ec16202de3 /indra/newview/llfloaterpreference.cpp
parent0db9bcf21fd4b7172e8a35cdb2805ccdc736e273 (diff)
parent07ace73c49918ffb70e99c2239849eaaabc1fe45 (diff)
Merge branch 'DRTVWR-587-maint-V' into DRTVWR-588-maint-W
# Conflicts: # indra/newview/llspatialpartition.cpp
Diffstat (limited to 'indra/newview/llfloaterpreference.cpp')
-rw-r--r--indra/newview/llfloaterpreference.cpp42
1 files changed, 40 insertions, 2 deletions
diff --git a/indra/newview/llfloaterpreference.cpp b/indra/newview/llfloaterpreference.cpp
index 9d8ecff0b3..b65d727948 100644
--- a/indra/newview/llfloaterpreference.cpp
+++ b/indra/newview/llfloaterpreference.cpp
@@ -251,11 +251,49 @@ void fractionFromDecimal(F32 decimal_val, S32& numerator, S32& denominator)
}
}
}
-// static
-std::string LLFloaterPreference::sSkin = "";
+
+// handle secondlife:///app/worldmap/{NAME}/{COORDS} URLs
+// Also see LLUrlEntryKeybinding, the value of this command type
+// is ability to show up to date value in chat
+class LLKeybindingHandler: public LLCommandHandler
+{
+public:
+ // requires trusted browser to trigger
+ LLKeybindingHandler(): LLCommandHandler("keybinding", UNTRUSTED_CLICK_ONLY)
+ {
+ }
+
+ bool handle(const LLSD& params, const LLSD& query_map,
+ const std::string& grid, LLMediaCtrl* web)
+ {
+ if (params.size() < 1) return false;
+
+ LLFloaterPreference* prefsfloater = dynamic_cast<LLFloaterPreference*>
+ (LLFloaterReg::showInstance("preferences"));
+
+ if (prefsfloater)
+ {
+ // find 'controls' panel and bring it the front
+ LLTabContainer* tabcontainer = prefsfloater->getChild<LLTabContainer>("pref core");
+ LLPanel* panel = prefsfloater->getChild<LLPanel>("controls");
+ if (tabcontainer && panel)
+ {
+ tabcontainer->selectTabPanel(panel);
+ }
+ }
+
+ return true;
+ }
+};
+LLKeybindingHandler gKeybindHandler;
+
+
//////////////////////////////////////////////
// LLFloaterPreference
+// static
+std::string LLFloaterPreference::sSkin = "";
+
LLFloaterPreference::LLFloaterPreference(const LLSD& key)
: LLFloater(key),
mGotPersonalInfo(false),