summaryrefslogtreecommitdiff
path: root/indra/newview/lltoolselect.cpp
diff options
context:
space:
mode:
authorMerov Linden <merov@lindenlab.com>2014-09-28 21:40:32 -0700
committerMerov Linden <merov@lindenlab.com>2014-09-28 21:40:32 -0700
commit4b80a5ed059d91bc37558db8ed664365e39d21d6 (patch)
tree55cfddc381448a72b54c03347deabada9687f629 /indra/newview/lltoolselect.cpp
parent896f48229e577b1bcf94f2cb80d73a6bf1a9330c (diff)
parent499f5aa9a4b46d61ee94b26d5c86bc032766af70 (diff)
Pull merge from lindenlab/viewer-release
Diffstat (limited to 'indra/newview/lltoolselect.cpp')
-rwxr-xr-xindra/newview/lltoolselect.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/indra/newview/lltoolselect.cpp b/indra/newview/lltoolselect.cpp
index 0a9153eecb..812abe9dbd 100755
--- a/indra/newview/lltoolselect.cpp
+++ b/indra/newview/lltoolselect.cpp
@@ -36,6 +36,7 @@
#include "llmanip.h"
#include "llmenugl.h"
#include "llselectmgr.h"
+#include "llviewermediafocus.h"
#include "lltoolmgr.h"
#include "llfloaterscriptdebug.h"
#include "llviewercamera.h"
@@ -110,6 +111,21 @@ LLObjectSelectionHandle LLToolSelect::handleObjectSelection(const LLPickInfo& pi
{
BOOL already_selected = object->isSelected();
+ if (already_selected &&
+ object->getNumTEs() > 0 &&
+ !LLSelectMgr::getInstance()->getSelection()->contains(object,SELECT_ALL_TES))
+ {
+ const LLTextureEntry* tep = object->getTE(pick.mObjectFace);
+ if (tep && !tep->isSelected() && !LLViewerMediaFocus::getInstance()->getFocusedObjectID().isNull())
+ {
+ // we were interacting with media and clicked on non selected face, drop media focus
+ LLViewerMediaFocus::getInstance()->clearFocus();
+ // selection was removed and zoom preserved by clearFocus(), continue with regular selection
+ already_selected = false;
+ extend_select = true;
+ }
+ }
+
if ( extend_select )
{
if ( already_selected )