diff options
author | Armin Weatherwax | 2010-02-07 18:07:20 +0100 |
---|---|---|
committer | Jacek Antonelli | 2010-02-18 20:15:06 -0600 |
commit | 6da743ff169bbe6d3d08421f9ce1e378ccead470 (patch) | |
tree | 9ae043dfdec836c599f7eb4888d078baf01774c4 /linden/indra/newview/lltoolpie.cpp | |
parent | Added missing "Set Default Permissions" menu entry. (#202) (diff) | |
download | meta-impy-6da743ff169bbe6d3d08421f9ce1e378ccead470.zip meta-impy-6da743ff169bbe6d3d08421f9ce1e378ccead470.tar.gz meta-impy-6da743ff169bbe6d3d08421f9ce1e378ccead470.tar.bz2 meta-impy-6da743ff169bbe6d3d08421f9ce1e378ccead470.tar.xz |
Fixed #155: Double clicking your avatar triggers a TP request.
Diffstat (limited to 'linden/indra/newview/lltoolpie.cpp')
-rw-r--r-- | linden/indra/newview/lltoolpie.cpp | 35 |
1 files changed, 30 insertions, 5 deletions
diff --git a/linden/indra/newview/lltoolpie.cpp b/linden/indra/newview/lltoolpie.cpp index 6bc36a5..626831f 100644 --- a/linden/indra/newview/lltoolpie.cpp +++ b/linden/indra/newview/lltoolpie.cpp | |||
@@ -694,9 +694,38 @@ BOOL LLToolPie::handleDoubleClick(S32 x, S32 y, MASK mask) | |||
694 | llinfos << "LLToolPie handleDoubleClick (becoming mouseDown)" << llendl; | 694 | llinfos << "LLToolPie handleDoubleClick (becoming mouseDown)" << llendl; |
695 | } | 695 | } |
696 | 696 | ||
697 | LLViewerObject *object = mPick.getObject(); | ||
698 | if(object) | ||
699 | { | ||
700 | //Zwagoth: No more teleport to HUD attachments. >:o | ||
701 | if (object->isHUDAttachment()) | ||
702 | { | ||
703 | LL_DEBUGS("DoubleClicks") << "Double clicked HUD" << LL_ENDL; | ||
704 | return FALSE; | ||
705 | } | ||
706 | |||
707 | //Armin: No more teleport to other attachments or Avatars including self ... | ||
708 | if (object->isAttachment()) | ||
709 | { | ||
710 | LL_DEBUGS("DoubleClicks") << "Double clicked attachment (not HUD)" << LL_ENDL; | ||
711 | return FALSE; | ||
712 | } | ||
713 | |||
714 | if (object->isAvatar()&& object == gAgent.getAvatarObject() ) | ||
715 | { | ||
716 | LL_DEBUGS("DoubleClicks") << "Double clicked self" << LL_ENDL; | ||
717 | return FALSE; | ||
718 | } | ||
719 | |||
720 | if (object->isAvatar()) | ||
721 | { | ||
722 | LL_DEBUGS("DoubleClicks") << "Double clicked other Avatar" << LL_ENDL; | ||
723 | return FALSE;// or what about open profile or IM session or ... | ||
724 | } | ||
725 | } | ||
726 | |||
697 | std::string action = gSavedSettings.getString("DoubleClickAction"); | 727 | std::string action = gSavedSettings.getString("DoubleClickAction"); |
698 | LLStringUtil::toLower(action); | 728 | LLStringUtil::toLower(action); |
699 | |||
700 | if (action == "none") | 729 | if (action == "none") |
701 | { | 730 | { |
702 | return FALSE; | 731 | return FALSE; |
@@ -712,10 +741,6 @@ BOOL LLToolPie::handleDoubleClick(S32 x, S32 y, MASK mask) | |||
712 | else if (mPick.mObjectID.notNull() | 741 | else if (mPick.mObjectID.notNull() |
713 | && !mPick.mPosGlobal.isExactlyZero()) | 742 | && !mPick.mPosGlobal.isExactlyZero()) |
714 | { | 743 | { |
715 | //Zwagoth: No more teleport to HUD attachments. >:o | ||
716 | if(mPick.getObject().notNull() && mPick.getObject()->isHUDAttachment()) | ||
717 | return FALSE; | ||
718 | |||
719 | handle_go_to_confirm(); | 744 | handle_go_to_confirm(); |
720 | return TRUE; | 745 | return TRUE; |
721 | } | 746 | } |