Permalink
Browse files

FLUID-2881: Stopgap fix forking "deferredCall" to "deferredInvokeCall…

…" since the latter has some subtle impact on environmental resolution - it appears if used in the environment of component expansion the connection to the "that stack" is broken. For now, different views in CSpace will use different versions although in theory there should be only one of these. We do need to look into the general performance implications of always using "fluid.invoke" though.

svn path=/fluid/infusion/trunk/; revision=10022
  • Loading branch information...
amb26 committed Sep 2, 2010
1 parent 13c9b2f commit 02fbd67ee7e801e0da59d6ec92f6a05b5cf3d61a
Showing with 9 additions and 2 deletions.
  1. +9 −2 src/webapp/framework/core/js/FluidIoC.js
@@ -651,12 +651,19 @@ var fluid_1_2 = fluid_1_2 || {};
fluid.expander.deferredCall = function(target, source) {
var expander = source.expander;
var args = (!expander.args || fluid.isArrayable(expander.args))? expander.args : $.makeArray(expander.args);
- //return fluid.invokeGlobalFunction(expander.func, args);
- return fluid.invoke(expander.func, args);
+ return fluid.invokeGlobalFunction(expander.func, args);
};
fluid.deferredCall = fluid.expander.deferredCall; // put in top namespace for convenience
+ // TODO: The case of an "invoke" call as part of the course of resolving some component options
+ // proved problematic here and interrupted the ability to resolve contextualised values inside the invoker.
+ fluid.deferredInvokeCall = function(target, source) {
+ var expander = source.expander;
+ var args = (!expander.args || fluid.isArrayable(expander.args))? expander.args : $.makeArray(expander.args);
+ return fluid.invoke(expander.func, args);
+ };
+
// The "noexpand" expander which simply unwraps one level of expansion and ceases.
fluid.expander.noexpand = function(target, source) {
return $.extend(target, source.expander.tree);

0 comments on commit 02fbd67

Please sign in to comment.