Fix radar popping up on right click focus if not announce when closed.
This commit is contained in:
@@ -315,7 +315,7 @@ namespace
|
|||||||
{
|
{
|
||||||
bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata)
|
bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata)
|
||||||
{
|
{
|
||||||
LLFloaterAvatarList::instance().setFocusAvatar(get_focused_list_id_selected());
|
LLFloaterAvatarList::setFocusAvatar(get_focused_list_id_selected());
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
@@ -1149,9 +1149,16 @@ void LLFloaterAvatarList::removeFocusFromAll()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// static
|
||||||
void LLFloaterAvatarList::setFocusAvatar(const LLUUID& id)
|
void LLFloaterAvatarList::setFocusAvatar(const LLUUID& id)
|
||||||
{
|
{
|
||||||
if (!gAgentCamera.lookAtObject(id, false) && !lookAtAvatar(id)) return;
|
if (!gAgentCamera.lookAtObject(id, false) && !lookAtAvatar(id)) return;
|
||||||
|
if (auto inst = getIfExists())
|
||||||
|
inst->setFocusAvatarInternal(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
void LLFloaterAvatarList::setFocusAvatarInternal(const LLUUID& id)
|
||||||
|
{
|
||||||
av_list_t::iterator iter = std::find_if(mAvatars.begin(),mAvatars.end(),LLAvatarListEntry::uuidMatch(id));
|
av_list_t::iterator iter = std::find_if(mAvatars.begin(),mAvatars.end(),LLAvatarListEntry::uuidMatch(id));
|
||||||
if (iter == mAvatars.end()) return;
|
if (iter == mAvatars.end()) return;
|
||||||
removeFocusFromAll();
|
removeFocusFromAll();
|
||||||
|
|||||||
@@ -264,7 +264,7 @@ public:
|
|||||||
/**
|
/**
|
||||||
* @brief Focus camera on specified avatar
|
* @brief Focus camera on specified avatar
|
||||||
*/
|
*/
|
||||||
void setFocusAvatar(const LLUUID& id);
|
static void setFocusAvatar(const LLUUID& id);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Focus camera on previous avatar
|
* @brief Focus camera on previous avatar
|
||||||
@@ -332,6 +332,8 @@ public:
|
|||||||
void updateAvatarSorting();
|
void updateAvatarSorting();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
void setFocusAvatarInternal(const LLUUID& id);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Pointer to the avatar scroll list
|
* @brief Pointer to the avatar scroll list
|
||||||
*/
|
*/
|
||||||
|
|||||||
Reference in New Issue
Block a user