当前位置: 首页>>代码示例>>C++>>正文


C++ LLFloaterIMPanel::getSpeakerManager方法代码示例

本文整理汇总了C++中LLFloaterIMPanel::getSpeakerManager方法的典型用法代码示例。如果您正苦于以下问题:C++ LLFloaterIMPanel::getSpeakerManager方法的具体用法?C++ LLFloaterIMPanel::getSpeakerManager怎么用?C++ LLFloaterIMPanel::getSpeakerManager使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在LLFloaterIMPanel的用法示例。


在下文中一共展示了LLFloaterIMPanel::getSpeakerManager方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1:

	/*virtual*/ void httpSuccess(void)
	{
		if ( gIMMgr)
		{
			LLFloaterIMPanel* floater = gIMMgr->findFloaterBySession(mSessionID);
			LLIMSpeakerMgr* speaker_mgr = floater ? floater->getSpeakerManager() : NULL;
			if (speaker_mgr)
			{
				//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.
				speaker_mgr->setSpeakers(mContent);

				//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
				speaker_mgr->updateSpeakers(gIMMgr->getPendingAgentListUpdates(mSessionID));
			}

			if (LLIMMgr::INVITATION_TYPE_VOICE == mInvitiationType)
			{
				gIMMgr->startCall(mSessionID, LLVoiceChannel::INCOMING_CALL);
			}

			if ((mInvitiationType == LLIMMgr::INVITATION_TYPE_VOICE
				|| mInvitiationType == LLIMMgr::INVITATION_TYPE_IMMEDIATE)
				&& floater)
			{
				// always open IM window when connecting to voice
				if (floater->getParent() == gFloaterView)
					floater->open();
				else
					LLFloaterChatterBox::showInstance(TRUE);
			}

			gIMMgr->clearPendingAgentListUpdates(mSessionID);
			gIMMgr->clearPendingInvitation(mSessionID);
		}
	}
开发者ID:CmdrCupcake,项目名称:SingularityViewer,代码行数:49,代码来源:llimview.cpp

示例2: endCall

bool LLIMMgr::endCall(const LLUUID& session_id)
{
	// Singu TODO: LLIMModel
	LLFloaterIMPanel* floater = gIMMgr->findFloaterBySession(session_id);
	if (!floater) return false;

	LLVoiceChannel* voice_channel = floater->getVoiceChannel();
	if (!voice_channel) return false;

	voice_channel->deactivate();
	/*LLIMModel::LLIMSession* im_session = LLIMModel::getInstance()->findIMSession(session_id);
	if (im_session)*/
	{
		// need to update speakers' state
		floater->getSpeakerManager()->update(FALSE);
	}
	return true;
}
开发者ID:CmdrCupcake,项目名称:SingularityViewer,代码行数:18,代码来源:llimview.cpp


注:本文中的LLFloaterIMPanel::getSpeakerManager方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。