/** * {@inheritDoc} */ @Override public void setParentScope(final Scriptable parent) { wrapped_.setParentScope(parent); }
/** * {@inheritDoc} */ @Override public void setParentScope(final Scriptable parent) { wrapped_.setParentScope(parent); }
/** * {@inheritDoc} */ @Override public Object call(final Context cx, final Scriptable scope, final Scriptable thisObj, final Object[] args) throws JavaScriptException { // the js object to which this event is attached has to be the scope final SimpleScriptable jsObj = node_.getScriptableObject(); // compile "just in time" if (realFunction_ == null) { realFunction_ = cx.compileFunction(jsObj, jsSnippet_, eventName_ + " event for " + node_ + " in " + node_.getPage().getUrl(), 0, null); realFunction_.setParentScope(jsObj); } return realFunction_.call(cx, scope, thisObj, args); }
/** * {@inheritDoc} */ @Override public Object call(final Context cx, final Scriptable scope, final Scriptable thisObj, final Object[] args) throws JavaScriptException { // the js object to which this event is attached has to be the scope final SimpleScriptable jsObj = node_.getScriptableObject(); // compile "just in time" if (realFunction_ == null) { realFunction_ = cx.compileFunction(jsObj, jsSnippet_, eventName_ + " event for " + node_ + " in " + node_.getPage().getUrl(), 0, null); realFunction_.setParentScope(jsObj); } return realFunction_.call(cx, scope, thisObj, args); }