Hi Michael,
Sorry for the delayed reply. I tested the scenario you mentioned. If the chat is entirely private and if
sessionDependent="true"
is set to true for the SimpleChatModel, then we can achieve the use case you mentioned. [Try running the app as Owner first to set the sessionDependent to true. ]
Code
<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx" minWidth="955" minHeight="600"
xmlns:pods="com.adobe.rtc.pods.*" xmlns:collab="com.adobe.rtc.collaboration.*" xmlns:session="com.adobe.rtc.session.*" xmlns:authentication="com.adobe.rtc.authentication.*">
<fx:Declarations>
<!-- Place non-visual elements (e.g., services, value objects) here -->
<authentication:AdobeHSAuthenticator
id="auth"
userName="Guest"
/>
</fx:Declarations>
<fx:Script>
<![CDATA[
import com.adobe.rtc.events.ChatEvent;
import mx.events.FlexEvent;
protected function sChat_creationCompleteHandler(event:FlexEvent):void
{
// TODO Auto-generated method stub
sChat.model.addEventListener(ChatEvent.HISTORY_CHANGE,onChatChange);
}
protected function onChatChange(p_evt:ChatEvent):void
{
trace("HistChange recieved");
}
]]>
</fx:Script>
<session:ConnectSessionContainer roomURL="room URL" id="cSession" authenticator="{auth}" width="100%" height="100%">
<pods:SimpleChat id="sChat" width="40%" height="100%" sessionDependent="true" creationComplete="sChat_creationCompleteHandler(event)"/>
<!-- <s:Button click="{sChat.model.clear()}" label="clear" /> -->
</session:ConnectSessionContainer>
</s:Application>
Thanks
Arun