Author: johnh
Date: Tue Apr 12 23:39:38 2011
New Revision: 1091602

URL: http://svn.apache.org/viewvc?rev=1091602&view=rev
Log:
Get rid of colons in channel names.


Modified:
    shindig/trunk/content/xpc.swf
    shindig/trunk/features/src/main/flex/Main.as

Modified: shindig/trunk/content/xpc.swf
URL: 
http://svn.apache.org/viewvc/shindig/trunk/content/xpc.swf?rev=1091602&r1=1091601&r2=1091602&view=diff
==============================================================================
Files shindig/trunk/content/xpc.swf (original) and 
shindig/trunk/content/xpc.swf Tue Apr 12 23:39:38 2011 differ

Modified: shindig/trunk/features/src/main/flex/Main.as
URL: 
http://svn.apache.org/viewvc/shindig/trunk/features/src/main/flex/Main.as?rev=1091602&r1=1091601&r2=1091602&view=diff
==============================================================================
--- shindig/trunk/features/src/main/flex/Main.as (original)
+++ shindig/trunk/features/src/main/flex/Main.as Tue Apr 12 23:39:38 2011
@@ -56,6 +56,7 @@ class Main {
 
   public static function main(swfRoot:MovieClip):Void {
     var escFn:Function = esc;
+    var replaceFn:Function = replace;
     
     if (SINGLETON) return;
     SINGLETON = true;
@@ -85,6 +86,7 @@ class Main {
         other_role = "OUTER";
       } else {
         other_role = "INNER";
+        role = "OUTER";
       }
 
       var receiving_lc:LocalConnection = new LocalConnection();
@@ -100,10 +102,13 @@ class Main {
       ExternalInterface.addCallback("sendMessage_" + channel_id + "_" + 
rpc_key + "_" + role,
             { }, function(message:String, to_origin:String) {
         if (!to_origin) to_origin = "*";
-        sending_lc.send("channel_" + channel_id + "_" + rpc_key + "_" + 
other_role,
+        var sendId:String =
+            replaceFn("channel_" + channel_id + "_" + rpc_key + "_" + 
other_role, ":", "");
+        sending_lc.send(sendId,
             "receiveMessage", to_origin, my_origin, rpc_key, message);
       });
-      receiving_lc.connect("channel_" + channel_id + "_" + rpc_key + "_" + 
role);
+      var recvId:String = replaceFn("channel_" + channel_id + "_" + rpc_key + 
"_" + role, ":", "");
+      receiving_lc.connect(recvId);
     });
     ExternalInterface.call("gadgets.rpctx.flash._ready");
   }


Reply via email to