summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaxim Nikolenko <maximnproductengine@lindenlab.com>2025-01-08 21:34:04 +0200
committerGitHub <noreply@github.com>2025-01-08 21:34:04 +0200
commit98473aa0c090447f0bd81630f40da7cb0ce9cf1a (patch)
treed3ecf7d30f8f6ab14efe5ecb1bcba3a7c6314c69
parent97b1ab3455fe0fa7980441ba8d5954a233bf51e9 (diff)
#3349 keep object selection after showing confirmation dialog
-rw-r--r--indra/newview/llviewermenu.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp
index 80c75ec919..d92faf4d1b 100644
--- a/indra/newview/llviewermenu.cpp
+++ b/indra/newview/llviewermenu.cpp
@@ -5199,15 +5199,16 @@ void handle_take(bool take_separate)
// MAINT-290
// Reason: Showing the confirmation dialog resets object selection, thus there is nothing to derez.
// Fix: pass selection to the confirm_take, so that selection doesn't "die" after confirmation dialog is opened
- params.functor.function([take_separate](const LLSD &notification, const LLSD &response)
+ LLObjectSelectionHandle obj_selection = LLSelectMgr::instance().getSelection();
+ params.functor.function([take_separate, obj_selection](const LLSD &notification, const LLSD &response)
{
if (take_separate)
{
- confirm_take_separate(notification, response, LLSelectMgr::instance().getSelection());
+ confirm_take_separate(notification, response, obj_selection);
}
else
{
- confirm_take(notification, response, LLSelectMgr::instance().getSelection());
+ confirm_take(notification, response, obj_selection);
}
});