To get a copy of the mm_jsapi.h file, extract it from the sample ZIP or SIT file (see
DLL implementation" on page
mm_jsapi.h:
#ifndef _MM_JSAPI_H_
#define _MM_JSAPI_H_
/
************************************************************************
*****
* Public data types
************************************************************************
****/
typedef struct JSContext JSContext;
typedef struct JSObject JSObject;
typedef long jsval;
#ifndef JSBool
typedef long JSBool;
#endif
typedef JSBool (*JSNative)(JSContext *cx, JSObject *obj, unsigned int argc,
jsval *argv, jsval *rval);
/* Possible values for JSBool */
#define JS_TRUE 1
#define JS_FALSE 0
/
************************************************************************
*****
* Public functions
************************************************************************
****/
/* JSBool JS_DefineFunction(unsigned short *name, JSNative call, unsigned
int nargs) */
#define JS_DefineFunction(n, c, a) \
(mmEnv.defineFunction ? (*(mmEnv.defineFunction))(mmEnv.libObj, n, c,
a) \
/* unsigned short *JS_ValueToString(JSContext *cx, jsval v, unsigned int
*pLength) */
#define JS_ValueToString(c, v, l) \
540), or copy the following code into a file that you name
: JS_FALSE)
"Sample
Integrating C functions
535
Need help?
Do you have a question about the FLASH 8-EXTENDING FLASH and is the answer not in the manual?
Questions and answers