[Xmpp4js-commit] SF.net SVN: xmpp4js:[746] trunk/src/site/xdoc/code-samples.xml
Status: Beta
Brought to you by:
h-iverson
From: <h-i...@us...> - 2008-07-25 03:18:06
|
Revision: 746 http://xmpp4js.svn.sourceforge.net/xmpp4js/?rev=746&view=rev Author: h-iverson Date: 2008-07-25 03:18:15 +0000 (Fri, 25 Jul 2008) Log Message: ----------- fixed typos and syntax errors Modified Paths: -------------- trunk/src/site/xdoc/code-samples.xml Modified: trunk/src/site/xdoc/code-samples.xml =================================================================== --- trunk/src/site/xdoc/code-samples.xml 2008-07-25 03:15:00 UTC (rev 745) +++ trunk/src/site/xdoc/code-samples.xml 2008-07-25 03:18:15 UTC (rev 746) @@ -59,23 +59,23 @@ <pre name="code" class="javascript"><![CDATA[ var cm = Xmpp4Js.Chat.ChatManager.getInstanceFor( con ); -cm.chatManager.setOptions({ +cm.setOptions({ ignoreThread: true, // useful for legacy networks (AIM) ignoreResource: true }); -cm.chatManager.on({ +cm.on({ scope : this, chatStarted : onChatStarted, messageReceived : onChatMessageReceived }); function onChatStarted(chat) { - alert( "Chat with "+chat.getParticipant()+" started." + alert( "Chat with "+chat.getParticipant()+" started." ); } function onChatMessageReceived(chat, messagePacket) { - alert( "New message from "+messagePacket.getFrom()+": "+messagePacket.getBody(); + alert( "New message from "+messagePacket.getFrom()+": "+messagePacket.getBody() ); } function sendMessage(to, message) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |