本文整理汇总了C++中LLFloaterIMPanel::updateSpeakersList方法的典型用法代码示例。如果您正苦于以下问题:C++ LLFloaterIMPanel::updateSpeakersList方法的具体用法?C++ LLFloaterIMPanel::updateSpeakersList怎么用?C++ LLFloaterIMPanel::updateSpeakersList使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类LLFloaterIMPanel
的用法示例。
在下文中一共展示了LLFloaterIMPanel::updateSpeakersList方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: result
void result(const LLSD& content)
{
if ( gIMMgr)
{
LLFloaterIMPanel* floaterp =
gIMMgr->findFloaterBySession(mSessionID);
if (floaterp)
{
//we've accepted our invitation
//and received a list of agents that were
//currently in the session when the reply was sent
//to us. Now, it is possible that there were some agents
//to slip in/out between when that message was sent to us
//and now.
//the agent list updates we've received have been
//accurate from the time we were added to the session
//but unfortunately, our base that we are receiving here
//may not be the most up to date. It was accurate at
//some point in time though.
floaterp->setSpeakers(content);
//we now have our base of users in the session
//that was accurate at some point, but maybe not now
//so now we apply all of the udpates we've received
//in case of race conditions
floaterp->updateSpeakersList(
gIMMgr->getPendingAgentListUpdates(mSessionID));
if ( mInvitiationType == LLIMMgr::INVITATION_TYPE_VOICE )
{
floaterp->requestAutoConnect();
LLFloaterIMPanel::onClickStartCall(floaterp);
// always open IM window when connecting to voice
LLFloaterChatterBox::showInstance(TRUE);
}
else if ( mInvitiationType == LLIMMgr::INVITATION_TYPE_IMMEDIATE )
{
LLFloaterChatterBox::showInstance(TRUE);
}
}
gIMMgr->clearPendingAgentListUpdates(mSessionID);
gIMMgr->clearPendingInvitation(mSessionID);
}
}
示例2: post
virtual void post(
ResponsePtr responder,
const LLSD& context,
const LLSD& input) const
{
LLFloaterIMPanel* floaterp = gIMMgr->findFloaterBySession(input["body"]["session_id"].asUUID());
if (floaterp)
{
floaterp->updateSpeakersList(
input["body"]);
}
else
{
//we don't have a floater yet..something went wrong
//we are probably receiving an update here before
//a start or an acceptance of an invitation. Race condition.
gIMMgr->addPendingAgentListUpdates(
input["body"]["session_id"].asUUID(),
input["body"]);
}
}