Entry: JS_SetGlobalObject (Function)
Summary: Specifies the global object for an executable script context.
Syntax:
void JS_SetGlobalObject(JSContext *cx, JSObject *obj);
Argument Type Description
cx JSContext * Pointer to the executable script context for which to set the global object.
obj JSObject * Pointer to the JS object to set as the global object.
Description:
JS_SetGlobalObject sets the global object to obj for a specified executable script context, cx. Ordinarily you set a context's global object when you call JS_InitStandardClasses to set up the general JS function and object classes for use by scripts.
See also:
|
|
|