Author: johnh
Date: Wed Jun 3 05:56:05 2009
New Revision: 781271
URL: http://svn.apache.org/viewvc?rev=781271&view=rev
Log:
Define isGadget to mean "isChild" for the purposes of rpc. This ensures that
to-container frame setup occurs properly, in particular fixing NIX (IE6/7).
Finally figured this out w/ improved test harness.
Modified:
incubator/shindig/trunk/features/src/main/javascript/features/rpc/rpc.js
Modified:
incubator/shindig/trunk/features/src/main/javascript/features/rpc/rpc.js
URL:
http://svn.apache.org/viewvc/incubator/shindig/trunk/features/src/main/javascript/features/rpc/rpc.js?rev=781271&r1=781270&r2=781271&view=diff
==============================================================================
--- incubator/shindig/trunk/features/src/main/javascript/features/rpc/rpc.js
(original)
+++ incubator/shindig/trunk/features/src/main/javascript/features/rpc/rpc.js
Wed Jun 3 05:56:05 2009
@@ -84,7 +84,9 @@
var params = {};
var receiverTx = {};
var earlyRpcQueue = {};
- var isGadget = false;
+
+ // isGadget =~ isChild for the purposes of rpc (used only in setup).
+ var isGadget = (window.top !== window.self);
var fallbackTransport = gadgets.rpctx.Ifpc;
// Load the authentication token for speaking to the container
@@ -400,10 +402,6 @@
// code to ignore rpc calls since they cannot work without a
// relay URL with host qualification.
relayUrl['..'] = parentParam + config.rpc.parentRelayUrl;
-
- // We assume that any rendering context where gadgets.config
- // is defined and a parent param is provided (gets here) is a gadget.
- isGadget = true;
}
}
var useLegacy = !!config.rpc.useLegacyProtocol;