FB::JSObjectPtr FB::BrowserHost::getDelayedInvokeDelegate() { if (getDOMWindow()) { if (call_delegate.empty()) { initJS(this); } if (!call_delegate.empty()) { return getDOMWindow()->getProperty<FB::JSObjectPtr>(call_delegate); } } return FB::JSObjectPtr(); }
FB::JSObjectPtr FB::BrowserHost::getDelayedInvokeDelegate() { if (call_delegate.empty()) { // initJS wasn't called (yet?)! assert(false); } FB::JSObjectPtr delegate(getDOMWindow()->getProperty<FB::JSObjectPtr>(call_delegate)); if (!delegate) { initJS(this); delegate = getDOMWindow()->getProperty<FB::JSObjectPtr>(call_delegate); assert(delegate); } return delegate; }