Bug 338678: For source compatibility fields "uint16 extra,spare" in JSFunctionSpec are replaced by singe "uint32 extra". In this way we do need to update the current sources that list just 5 fields to include the additional ",0" corresponding to "spare" field. To quell GCC warnings all sources that list less then 5 fields of JSFunctionSpec are updated to explicitly list all 5 fields. r=mrbkap, s=brendan
git-svn-id: svn://10.0.0.236/trunk@198222 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
01a66fb119
commit
642c0ea402
@ -271,14 +271,15 @@ netscape_security_invalidate(JSContext *cx, JSObject *obj, uintN argc,
|
||||
}
|
||||
|
||||
static JSFunctionSpec PrivilegeManager_static_methods[] = {
|
||||
{ "isPrivilegeEnabled", netscape_security_isPrivilegeEnabled, 1},
|
||||
{ "enablePrivilege", netscape_security_enablePrivilege, 1},
|
||||
{ "disablePrivilege", netscape_security_disablePrivilege, 1},
|
||||
{ "revertPrivilege", netscape_security_revertPrivilege, 1},
|
||||
{ "isPrivilegeEnabled", netscape_security_isPrivilegeEnabled, 1,0,0},
|
||||
{ "enablePrivilege", netscape_security_enablePrivilege, 1,0,0},
|
||||
{ "disablePrivilege", netscape_security_disablePrivilege, 1,0,0},
|
||||
{ "revertPrivilege", netscape_security_revertPrivilege, 1,0,0},
|
||||
//-- System Cert Functions
|
||||
{ "setCanEnablePrivilege", netscape_security_setCanEnablePrivilege, 2},
|
||||
{ "invalidate", netscape_security_invalidate, 1},
|
||||
{0}
|
||||
{ "setCanEnablePrivilege", netscape_security_setCanEnablePrivilege,
|
||||
2,0,0},
|
||||
{ "invalidate", netscape_security_invalidate, 1,0,0},
|
||||
{nsnull,nsnull,0,0,0}
|
||||
};
|
||||
|
||||
/*
|
||||
|
||||
@ -390,22 +390,22 @@ GetOutputStream(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rv
|
||||
// win.p = print, where win is rooted in some other global
|
||||
// object.
|
||||
static JSFunctionSpec global_functions[] = {
|
||||
{"print", Print, 1, JSFUN_BOUND_METHOD},
|
||||
{"dump", Print, 1, JSFUN_BOUND_METHOD},
|
||||
{"quit", Quit, 0, JSFUN_BOUND_METHOD},
|
||||
{"exit", Quit, 0, JSFUN_BOUND_METHOD},
|
||||
{"load", Load, 1, JSFUN_BOUND_METHOD},
|
||||
{"suspend", Suspend, 0, JSFUN_BOUND_METHOD},
|
||||
{"resume", Resume, 0, JSFUN_BOUND_METHOD},
|
||||
{"flushEventQueue", FlushEventQueue,0, JSFUN_BOUND_METHOD},
|
||||
{"addressOf", AddressOf, 1, 0},
|
||||
{"setProtocol", SetProtocol, 1, JSFUN_BOUND_METHOD},
|
||||
{"getProtocol", GetProtocol, 0, JSFUN_BOUND_METHOD},
|
||||
{"setContextObj", SetContextObj, 1, JSFUN_BOUND_METHOD},
|
||||
{"debugBreak", DebugBreak, 0, JSFUN_BOUND_METHOD},
|
||||
{"getInputStream", GetInputStream, 0, JSFUN_BOUND_METHOD},
|
||||
{"getOutputStream", GetOutputStream,0, JSFUN_BOUND_METHOD},
|
||||
{0}
|
||||
{"print", Print, 1, JSFUN_BOUND_METHOD, 0},
|
||||
{"dump", Print, 1, JSFUN_BOUND_METHOD, 0},
|
||||
{"quit", Quit, 0, JSFUN_BOUND_METHOD, 0},
|
||||
{"exit", Quit, 0, JSFUN_BOUND_METHOD, 0},
|
||||
{"load", Load, 1, JSFUN_BOUND_METHOD, 0},
|
||||
{"suspend", Suspend, 0, JSFUN_BOUND_METHOD, 0},
|
||||
{"resume", Resume, 0, JSFUN_BOUND_METHOD, 0},
|
||||
{"flushEventQueue", FlushEventQueue,0, JSFUN_BOUND_METHOD, 0},
|
||||
{"addressOf", AddressOf, 1, 0, 0},
|
||||
{"setProtocol", SetProtocol, 1, JSFUN_BOUND_METHOD, 0},
|
||||
{"getProtocol", GetProtocol, 0, JSFUN_BOUND_METHOD, 0},
|
||||
{"setContextObj", SetContextObj, 1, JSFUN_BOUND_METHOD, 0},
|
||||
{"debugBreak", DebugBreak, 0, JSFUN_BOUND_METHOD, 0},
|
||||
{"getInputStream", GetInputStream, 0, JSFUN_BOUND_METHOD, 0},
|
||||
{"getOutputStream", GetOutputStream,0, JSFUN_BOUND_METHOD, 0},
|
||||
{nsnull, nsnull, 0, 0, 0}
|
||||
};
|
||||
|
||||
|
||||
|
||||
@ -1190,7 +1190,7 @@ DumpScope(JSContext *cx, JSObject *obj, FILE *fp)
|
||||
for (sprop = SCOPE_LAST_PROP(scope); sprop; sprop = sprop->parent) {
|
||||
if (SCOPE_HAD_MIDDLE_DELETE(scope) && !SCOPE_HAS_PROPERTY(scope, sprop))
|
||||
continue;
|
||||
fprintf(fp, "%3u %p", i, sprop);
|
||||
fprintf(fp, "%3u %p", i, (void *)sprop);
|
||||
if (JSID_IS_INT(sprop->id)) {
|
||||
fprintf(fp, " [%ld]", (long)JSVAL_TO_INT(sprop->id));
|
||||
} else if (JSID_IS_ATOM(sprop->id)) {
|
||||
@ -1211,7 +1211,7 @@ DumpScope(JSContext *cx, JSObject *obj, FILE *fp)
|
||||
#undef DUMP_ATTR
|
||||
|
||||
fprintf(fp, " slot %lu flags %x shortid %d\n",
|
||||
sprop->slot, sprop->flags, sprop->shortid);
|
||||
(unsigned long)sprop->slot, sprop->flags, sprop->shortid);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1666,7 +1666,8 @@ static JSClass sandbox_class = {
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
sandbox_enumerate, (JSResolveOp)sandbox_resolve,
|
||||
JS_ConvertStub, JS_FinalizeStub
|
||||
JS_ConvertStub, JS_FinalizeStub,
|
||||
JSCLASS_NO_OPTIONAL_MEMBERS
|
||||
};
|
||||
|
||||
static JSBool
|
||||
@ -1730,44 +1731,44 @@ out:
|
||||
}
|
||||
|
||||
static JSFunctionSpec shell_functions[] = {
|
||||
{"version", Version, 0},
|
||||
{"options", Options, 0},
|
||||
{"load", Load, 1},
|
||||
{"readline", ReadLine, 0},
|
||||
{"print", Print, 0},
|
||||
{"help", Help, 0},
|
||||
{"quit", Quit, 0},
|
||||
{"gc", GC, 0},
|
||||
{"trap", Trap, 3},
|
||||
{"untrap", Untrap, 2},
|
||||
{"line2pc", LineToPC, 0},
|
||||
{"pc2line", PCToLine, 0},
|
||||
{"stringsAreUtf8", StringsAreUtf8, 0},
|
||||
{"testUtf8", TestUtf8, 1},
|
||||
{"throwError", ThrowError, 0},
|
||||
{"version", Version, 0,0,0},
|
||||
{"options", Options, 0,0,0},
|
||||
{"load", Load, 1,0,0},
|
||||
{"readline", ReadLine, 0,0,0},
|
||||
{"print", Print, 0,0,0},
|
||||
{"help", Help, 0,0,0},
|
||||
{"quit", Quit, 0,0,0},
|
||||
{"gc", GC, 0,0,0},
|
||||
{"trap", Trap, 3,0,0},
|
||||
{"untrap", Untrap, 2,0,0},
|
||||
{"line2pc", LineToPC, 0,0,0},
|
||||
{"pc2line", PCToLine, 0,0,0},
|
||||
{"stringsAreUtf8", StringsAreUtf8, 0,0,0},
|
||||
{"testUtf8", TestUtf8, 1,0,0},
|
||||
{"throwError", ThrowError, 0,0,0},
|
||||
#ifdef DEBUG
|
||||
{"dis", Disassemble, 1},
|
||||
{"dissrc", DisassWithSrc, 1},
|
||||
{"notes", Notes, 1},
|
||||
{"tracing", Tracing, 0},
|
||||
{"stats", DumpStats, 1},
|
||||
{"dis", Disassemble, 1,0,0},
|
||||
{"dissrc", DisassWithSrc, 1,0,0},
|
||||
{"notes", Notes, 1,0,0},
|
||||
{"tracing", Tracing, 0,0,0},
|
||||
{"stats", DumpStats, 1,0,0},
|
||||
#endif
|
||||
#ifdef TEST_EXPORT
|
||||
{"xport", DoExport, 2},
|
||||
{"xport", DoExport, 2,0,0},
|
||||
#endif
|
||||
#ifdef TEST_CVTARGS
|
||||
{"cvtargs", ConvertArgs, 0, 0, 12},
|
||||
{"cvtargs", ConvertArgs, 0,0,12},
|
||||
#endif
|
||||
{"build", BuildDate, 0},
|
||||
{"clear", Clear, 0},
|
||||
{"intern", Intern, 1},
|
||||
{"clone", Clone, 1},
|
||||
{"seal", Seal, 1, 0, 1},
|
||||
{"getpda", GetPDA, 1},
|
||||
{"getslx", GetSLX, 1},
|
||||
{"toint32", ToInt32, 1},
|
||||
{"evalcx", EvalInContext, 1},
|
||||
{0}
|
||||
{"build", BuildDate, 0,0,0},
|
||||
{"clear", Clear, 0,0,0},
|
||||
{"intern", Intern, 1,0,0},
|
||||
{"clone", Clone, 1,0,0},
|
||||
{"seal", Seal, 1,0,1},
|
||||
{"getpda", GetPDA, 1,0,0},
|
||||
{"getslx", GetSLX, 1,0,0},
|
||||
{"toint32", ToInt32, 1,0,0},
|
||||
{"evalcx", EvalInContext, 1,0,0},
|
||||
{NULL,NULL,0,0,0}
|
||||
};
|
||||
|
||||
/* NOTE: These must be kept in sync with the above. */
|
||||
@ -1891,13 +1892,13 @@ enum its_tinyid {
|
||||
};
|
||||
|
||||
static JSPropertySpec its_props[] = {
|
||||
{"color", ITS_COLOR, JSPROP_ENUMERATE},
|
||||
{"height", ITS_HEIGHT, JSPROP_ENUMERATE},
|
||||
{"width", ITS_WIDTH, JSPROP_ENUMERATE},
|
||||
{"funny", ITS_FUNNY, JSPROP_ENUMERATE},
|
||||
{"array", ITS_ARRAY, JSPROP_ENUMERATE},
|
||||
{"rdonly", ITS_RDONLY, JSPROP_READONLY},
|
||||
{0}
|
||||
{"color", ITS_COLOR, JSPROP_ENUMERATE, NULL, NULL},
|
||||
{"height", ITS_HEIGHT, JSPROP_ENUMERATE, NULL, NULL},
|
||||
{"width", ITS_WIDTH, JSPROP_ENUMERATE, NULL, NULL},
|
||||
{"funny", ITS_FUNNY, JSPROP_ENUMERATE, NULL, NULL},
|
||||
{"array", ITS_ARRAY, JSPROP_ENUMERATE, NULL, NULL},
|
||||
{"rdonly", ITS_RDONLY, JSPROP_READONLY, NULL, NULL},
|
||||
{NULL,0,0,NULL,NULL}
|
||||
};
|
||||
|
||||
static JSBool
|
||||
@ -1937,9 +1938,9 @@ its_bindMethod(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
|
||||
}
|
||||
|
||||
static JSFunctionSpec its_methods[] = {
|
||||
{"item", its_item, 0},
|
||||
{"bindMethod", its_bindMethod, 2},
|
||||
{0}
|
||||
{"item", its_item, 0,0,0},
|
||||
{"bindMethod", its_bindMethod, 2,0,0},
|
||||
{NULL,NULL,0,0,0}
|
||||
};
|
||||
|
||||
#ifdef JSD_LOWLEVEL_SOURCE
|
||||
@ -2073,12 +2074,13 @@ static JSClass its_class = {
|
||||
"It", JSCLASS_NEW_RESOLVE,
|
||||
its_addProperty, its_delProperty, its_getProperty, its_setProperty,
|
||||
its_enumerate, (JSResolveOp)its_resolve,
|
||||
its_convert, its_finalize
|
||||
its_convert, its_finalize,
|
||||
JSCLASS_NO_OPTIONAL_MEMBERS
|
||||
};
|
||||
|
||||
JSErrorFormatString jsShell_ErrorFormatString[JSErr_Limit] = {
|
||||
#define MSG_DEF(name, number, count, exception, format) \
|
||||
{ format, count } ,
|
||||
{ format, count, JSEXN_ERR } ,
|
||||
#include "jsshell.msg"
|
||||
#undef MSG_DEF
|
||||
};
|
||||
@ -2303,7 +2305,8 @@ JSClass global_class = {
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
global_enumerate, (JSResolveOp) global_resolve,
|
||||
JS_ConvertStub, JS_FinalizeStub
|
||||
JS_ConvertStub, JS_FinalizeStub,
|
||||
JSCLASS_NO_OPTIONAL_MEMBERS
|
||||
};
|
||||
|
||||
static JSBool
|
||||
@ -2417,7 +2420,8 @@ static JSClass env_class = {
|
||||
JS_PropertyStub, JS_PropertyStub,
|
||||
JS_PropertyStub, env_setProperty,
|
||||
env_enumerate, (JSResolveOp) env_resolve,
|
||||
JS_ConvertStub, JS_FinalizeStub
|
||||
JS_ConvertStub, JS_FinalizeStub,
|
||||
JSCLASS_NO_OPTIONAL_MEMBERS
|
||||
};
|
||||
|
||||
#ifdef NARCISSUS
|
||||
|
||||
@ -3653,6 +3653,9 @@ JS_DefineFunctions(JSContext *cx, JSObject *obj, JSFunctionSpec *fs)
|
||||
CHECK_REQUEST(cx);
|
||||
ctor = NULL;
|
||||
for (; fs->name; fs++) {
|
||||
|
||||
/* High bits of fs->extra are reserved. */
|
||||
JS_ASSERT((fs->extra & 0xFFFF0000) == 0);
|
||||
flags = fs->flags;
|
||||
|
||||
/*
|
||||
|
||||
@ -1118,8 +1118,10 @@ struct JSFunctionSpec {
|
||||
JSNative call;
|
||||
uint16 nargs;
|
||||
uint16 flags;
|
||||
uint16 extra; /* number of arg slots for local GC roots */
|
||||
uint16 spare;
|
||||
uint32 extra; /* extra & 0xFFFF:
|
||||
number of arg slots for local GC roots
|
||||
extra >> 16:
|
||||
reserved, must be zero */
|
||||
};
|
||||
|
||||
extern JS_PUBLIC_API(JSObject *)
|
||||
|
||||
@ -118,11 +118,11 @@ JSClass perlClass = {
|
||||
};
|
||||
|
||||
static JSFunctionSpec perlMethods[] = {
|
||||
{"toString", (JSNative)PerlToString, 0},
|
||||
{"eval", (JSNative)perl_eval, 0},
|
||||
{"call", (JSNative)perl_call, 0},
|
||||
{"use", (JSNative)perl_use, 0},
|
||||
{ NULL, NULL,0 }
|
||||
{"toString", (JSNative)PerlToString, 0,0,0},
|
||||
{"eval", (JSNative)perl_eval, 0,0,0},
|
||||
{"call", (JSNative)perl_call, 0,0,0},
|
||||
{"use", (JSNative)perl_use, 0,0,0},
|
||||
{NULL, NULL, 0,0,0}
|
||||
};
|
||||
|
||||
|
||||
@ -134,8 +134,8 @@ JSClass perlModuleClass = {
|
||||
};
|
||||
|
||||
JSFunctionSpec perlModuleMethods[] = {
|
||||
{"toString", (JSNative)PMToString, 0},
|
||||
{ NULL, NULL,0 }
|
||||
{"toString", (JSNative)PMToString, 0,0,0},
|
||||
{NULL, NULL, 0,0,0}
|
||||
};
|
||||
|
||||
|
||||
@ -147,8 +147,8 @@ JSClass perlValueClass = {
|
||||
};
|
||||
|
||||
JSFunctionSpec perlValueMethods[] = {
|
||||
{"toString", (JSNative)PVToString, 0},
|
||||
{ NULL, NULL, 0}
|
||||
{"toString", (JSNative)PVToString, 0,0,0},
|
||||
{NULL, NULL, 0,0,0}
|
||||
};
|
||||
|
||||
/*
|
||||
|
||||
@ -191,9 +191,9 @@ Debug(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
|
||||
}
|
||||
|
||||
static JSFunctionSpec gGlobalFun[] = {
|
||||
{"dump", Dump, 1 },
|
||||
{"debug", Debug, 1 },
|
||||
{0}
|
||||
{"dump", Dump, 1,0,0},
|
||||
{"debug", Debug, 1,0,0},
|
||||
{nsnull,nsnull,0,0,0}
|
||||
};
|
||||
|
||||
class JSCLContextHelper
|
||||
|
||||
@ -352,16 +352,16 @@ Clear(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
|
||||
}
|
||||
|
||||
static JSFunctionSpec glob_functions[] = {
|
||||
{"print", Print, 0},
|
||||
{"load", Load, 1},
|
||||
{"quit", Quit, 0},
|
||||
{"version", Version, 1},
|
||||
{"build", BuildDate, 0},
|
||||
{"dumpXPC", DumpXPC, 1},
|
||||
{"dump", Dump, 1},
|
||||
{"gc", GC, 0},
|
||||
{"clear", Clear, 1},
|
||||
{0}
|
||||
{"print", Print, 0,0,0},
|
||||
{"load", Load, 1,0,0},
|
||||
{"quit", Quit, 0,0,0},
|
||||
{"version", Version, 1,0,0},
|
||||
{"build", BuildDate, 0,0,0},
|
||||
{"dumpXPC", DumpXPC, 1,0,0},
|
||||
{"dump", Dump, 1,0,0},
|
||||
{"gc", GC, 0,0,0},
|
||||
{"clear", Clear, 1,0,0},
|
||||
{nsnull,nsnull,0,0,0}
|
||||
};
|
||||
|
||||
JSClass global_class = {
|
||||
|
||||
@ -2133,9 +2133,9 @@ static JSClass SandboxClass = {
|
||||
};
|
||||
|
||||
static JSFunctionSpec SandboxFunctions[] = {
|
||||
{"dump", SandboxDump, 1},
|
||||
{"debug", SandboxDebug, 1},
|
||||
{0}
|
||||
{"dump", SandboxDump, 1,0,0},
|
||||
{"debug", SandboxDebug, 1,0,0},
|
||||
{nsnull,nsnull,0,0,0}
|
||||
};
|
||||
|
||||
#endif /* !XPCONNECT_STANDALONE */
|
||||
|
||||
@ -116,9 +116,9 @@ Load(JSContext *cx, JSObject *obj, uintN argc, jsval *argv, jsval *rval)
|
||||
}
|
||||
|
||||
static JSFunctionSpec glob_functions[] = {
|
||||
{"print", Print, 0},
|
||||
{"load", Load, 1},
|
||||
{0}
|
||||
{"print", Print, 0,0,0},
|
||||
{"load", Load, 1,0,0},
|
||||
{nsnull,nsnull,0,0,0}
|
||||
};
|
||||
|
||||
static JSClass global_class = {
|
||||
|
||||
@ -1416,31 +1416,31 @@ InstallFileOpWinRegisterServer(JSContext *cx, JSObject *obj, uintN argc, jsval *
|
||||
//
|
||||
static JSFunctionSpec FileOpMethods[] =
|
||||
{
|
||||
{"dirCreate", InstallFileOpDirCreate, 1},
|
||||
{"dirGetParent", InstallFileOpDirGetParent, 1},
|
||||
{"dirRemove", InstallFileOpDirRemove, 2},
|
||||
{"dirRename", InstallFileOpDirRename, 2},
|
||||
{"copy", InstallFileOpFileCopy, 2},
|
||||
{"remove", InstallFileOpFileRemove, 1},
|
||||
{"exists", InstallFileOpFileExists, 1},
|
||||
{"execute", InstallFileOpFileExecute, 2},
|
||||
{"nativeVersion", InstallFileOpFileGetNativeVersion, 1},
|
||||
{"windowsVersion", InstallFileOpFileGetNativeVersion, 1},
|
||||
{"diskSpaceAvailable", InstallFileOpFileGetDiskSpaceAvailable,1},
|
||||
{"modDate", InstallFileOpFileGetModDate, 1},
|
||||
{"size", InstallFileOpFileGetSize, 1},
|
||||
{"isDirectory", InstallFileOpFileIsDirectory, 1},
|
||||
{"isWritable", InstallFileOpFileIsWritable, 1},
|
||||
{"isFile", InstallFileOpFileIsFile, 1},
|
||||
{"modDateChanged", InstallFileOpFileModDateChanged, 2},
|
||||
{"move", InstallFileOpFileMove, 2},
|
||||
{"rename", InstallFileOpFileRename, 2},
|
||||
{"windowsGetShortName", InstallFileOpFileWindowsGetShortName, 1},
|
||||
{"windowsShortcut", InstallFileOpFileWindowsShortcut, 7},
|
||||
{"macAlias", InstallFileOpFileMacAlias, 2},
|
||||
{"unixLink", InstallFileOpFileUnixLink, 2},
|
||||
{"windowsRegisterServer", InstallFileOpWinRegisterServer, 1},
|
||||
{0}
|
||||
{"dirCreate", InstallFileOpDirCreate, 1,0,0},
|
||||
{"dirGetParent", InstallFileOpDirGetParent, 1,0,0},
|
||||
{"dirRemove", InstallFileOpDirRemove, 2,0,0},
|
||||
{"dirRename", InstallFileOpDirRename, 2,0,0},
|
||||
{"copy", InstallFileOpFileCopy, 2,0,0},
|
||||
{"remove", InstallFileOpFileRemove, 1,0,0},
|
||||
{"exists", InstallFileOpFileExists, 1,0,0},
|
||||
{"execute", InstallFileOpFileExecute, 2,0,0},
|
||||
{"nativeVersion", InstallFileOpFileGetNativeVersion, 1,0,0},
|
||||
{"windowsVersion", InstallFileOpFileGetNativeVersion, 1,0,0},
|
||||
{"diskSpaceAvailable", InstallFileOpFileGetDiskSpaceAvailable,1,0,0},
|
||||
{"modDate", InstallFileOpFileGetModDate, 1,0,0},
|
||||
{"size", InstallFileOpFileGetSize, 1,0,0},
|
||||
{"isDirectory", InstallFileOpFileIsDirectory, 1,0,0},
|
||||
{"isWritable", InstallFileOpFileIsWritable, 1,0,0},
|
||||
{"isFile", InstallFileOpFileIsFile, 1,0,0},
|
||||
{"modDateChanged", InstallFileOpFileModDateChanged, 2,0,0},
|
||||
{"move", InstallFileOpFileMove, 2,0,0},
|
||||
{"rename", InstallFileOpFileRename, 2,0,0},
|
||||
{"windowsGetShortName", InstallFileOpFileWindowsGetShortName, 1,0,0},
|
||||
{"windowsShortcut", InstallFileOpFileWindowsShortcut, 7,0,0},
|
||||
{"macAlias", InstallFileOpFileMacAlias, 2,0,0},
|
||||
{"unixLink", InstallFileOpFileUnixLink, 2,0,0},
|
||||
{"windowsRegisterServer", InstallFileOpWinRegisterServer, 1,0,0},
|
||||
{nsnull,nsnull,0,0,0}
|
||||
};
|
||||
|
||||
|
||||
|
||||
@ -139,9 +139,9 @@ static void PR_CALLBACK FileSpecObjectCleanup(JSContext *cx, JSObject *obj)
|
||||
//
|
||||
static JSFunctionSpec fileSpecObjMethods[] =
|
||||
{
|
||||
{"appendPath", fso_AppendPath, 1},
|
||||
{"toString", fso_ToString, 0},
|
||||
{0}
|
||||
{"appendPath", fso_AppendPath, 1,0,0},
|
||||
{"toString", fso_ToString, 0,0,0},
|
||||
{nsnull,nsnull,0,0,0}
|
||||
};
|
||||
|
||||
|
||||
|
||||
@ -1867,64 +1867,64 @@ static JSConstDoubleSpec install_constants[] =
|
||||
static JSFunctionSpec InstallMethods[] =
|
||||
{
|
||||
/*START HACK FOR DEBUGGING UNTIL ALERTS WORK*/
|
||||
{"TRACE", InstallTRACE, 1},
|
||||
{"TRACE", InstallTRACE, 1,0,0},
|
||||
/*END HACK FOR DEBUGGING UNTIL ALERTS WORK*/
|
||||
// -- new forms that match prevailing javascript style --
|
||||
{"addDirectory", InstallAddDirectory, 6},
|
||||
{"addFile", InstallAddSubcomponent, 6},
|
||||
{"alert", InstallAlert, 1},
|
||||
{"cancelInstall", InstallAbortInstall, 1},
|
||||
{"confirm", InstallConfirm, 8},
|
||||
{"execute", InstallExecute, 2},
|
||||
{"gestalt", InstallGestalt, 1},
|
||||
{"getComponentFolder", InstallGetComponentFolder, 2},
|
||||
{"getFolder", InstallGetFolder, 2},
|
||||
{"getLastError", InstallGetLastError, 0},
|
||||
{"getWinProfile", InstallGetWinProfile, 2},
|
||||
{"getWinRegistry", InstallGetWinRegistry, 0},
|
||||
{"initInstall", InstallStartInstall, 4},
|
||||
{"loadResources", InstallLoadResources, 1},
|
||||
{"logComment", InstallLogComment, 1},
|
||||
{"patch", InstallPatch, 5},
|
||||
{"performInstall", InstallFinalizeInstall, 0},
|
||||
{"registerChrome", InstallRegisterChrome, 2},
|
||||
{"refreshPlugins", InstallRefreshPlugins, 1},
|
||||
{"resetError", InstallResetError, 1},
|
||||
// {"selectChrome", InstallSelectChrome, 2},
|
||||
{"setPackageFolder", InstallSetPackageFolder, 1},
|
||||
{"uninstall", InstallUninstall, 1},
|
||||
{"addDirectory", InstallAddDirectory, 6,0,0},
|
||||
{"addFile", InstallAddSubcomponent, 6,0,0},
|
||||
{"alert", InstallAlert, 1,0,0},
|
||||
{"cancelInstall", InstallAbortInstall, 1,0,0},
|
||||
{"confirm", InstallConfirm, 8,0,0},
|
||||
{"execute", InstallExecute, 2,0,0},
|
||||
{"gestalt", InstallGestalt, 1,0,0},
|
||||
{"getComponentFolder", InstallGetComponentFolder, 2,0,0},
|
||||
{"getFolder", InstallGetFolder, 2,0,0},
|
||||
{"getLastError", InstallGetLastError, 0,0,0},
|
||||
{"getWinProfile", InstallGetWinProfile, 2,0,0},
|
||||
{"getWinRegistry", InstallGetWinRegistry, 0,0,0},
|
||||
{"initInstall", InstallStartInstall, 4,0,0},
|
||||
{"loadResources", InstallLoadResources, 1,0,0},
|
||||
{"logComment", InstallLogComment, 1,0,0},
|
||||
{"patch", InstallPatch, 5,0,0},
|
||||
{"performInstall", InstallFinalizeInstall, 0,0,0},
|
||||
{"registerChrome", InstallRegisterChrome, 2,0,0},
|
||||
{"refreshPlugins", InstallRefreshPlugins, 1,0,0},
|
||||
{"resetError", InstallResetError, 1,0,0},
|
||||
// {"selectChrome", InstallSelectChrome, 2,0,0},
|
||||
{"setPackageFolder", InstallSetPackageFolder, 1,0,0},
|
||||
{"uninstall", InstallUninstall, 1,0,0},
|
||||
|
||||
// the raw file methods are deprecated, use the File object instead
|
||||
{"dirCreate", InstallFileOpDirCreate, 1},
|
||||
{"dirGetParent", InstallFileOpDirGetParent, 1},
|
||||
{"dirRemove", InstallFileOpDirRemove, 2},
|
||||
{"dirRename", InstallFileOpDirRename, 2},
|
||||
{"fileCopy", InstallFileOpFileCopy, 2},
|
||||
{"fileDelete", InstallFileOpFileRemove, 1},
|
||||
{"fileExists", InstallFileOpFileExists, 1},
|
||||
{"fileExecute", InstallFileOpFileExecute, 2},
|
||||
{"fileGetNativeVersion", InstallFileOpFileGetNativeVersion, 1},
|
||||
{"fileGetDiskSpaceAvailable", InstallFileOpFileGetDiskSpaceAvailable,1},
|
||||
{"fileGetModDate", InstallFileOpFileGetModDate, 1},
|
||||
{"fileGetSize", InstallFileOpFileGetSize, 1},
|
||||
{"fileIsDirectory", InstallFileOpFileIsDirectory, 1},
|
||||
{"fileIsWritable", InstallFileOpFileIsWritable, 1},
|
||||
{"fileIsFile", InstallFileOpFileIsFile, 1},
|
||||
{"fileModDateChanged", InstallFileOpFileModDateChanged, 2},
|
||||
{"fileMove", InstallFileOpFileMove, 2},
|
||||
{"fileRename", InstallFileOpFileRename, 2},
|
||||
{"fileWindowsShortcut", InstallFileOpFileWindowsShortcut, 7},
|
||||
{"fileMacAlias", InstallFileOpFileMacAlias, 2},
|
||||
{"fileUnixLink", InstallFileOpFileUnixLink, 2},
|
||||
{"dirCreate", InstallFileOpDirCreate, 1,0,0},
|
||||
{"dirGetParent", InstallFileOpDirGetParent, 1,0,0},
|
||||
{"dirRemove", InstallFileOpDirRemove, 2,0,0},
|
||||
{"dirRename", InstallFileOpDirRename, 2,0,0},
|
||||
{"fileCopy", InstallFileOpFileCopy, 2,0,0},
|
||||
{"fileDelete", InstallFileOpFileRemove, 1,0,0},
|
||||
{"fileExists", InstallFileOpFileExists, 1,0,0},
|
||||
{"fileExecute", InstallFileOpFileExecute, 2,0,0},
|
||||
{"fileGetNativeVersion", InstallFileOpFileGetNativeVersion, 1,0,0},
|
||||
{"fileGetDiskSpaceAvailable", InstallFileOpFileGetDiskSpaceAvailable,1,0,0},
|
||||
{"fileGetModDate", InstallFileOpFileGetModDate, 1,0,0},
|
||||
{"fileGetSize", InstallFileOpFileGetSize, 1,0,0},
|
||||
{"fileIsDirectory", InstallFileOpFileIsDirectory, 1,0,0},
|
||||
{"fileIsWritable", InstallFileOpFileIsWritable, 1,0,0},
|
||||
{"fileIsFile", InstallFileOpFileIsFile, 1,0,0},
|
||||
{"fileModDateChanged", InstallFileOpFileModDateChanged, 2,0,0},
|
||||
{"fileMove", InstallFileOpFileMove, 2,0,0},
|
||||
{"fileRename", InstallFileOpFileRename, 2,0,0},
|
||||
{"fileWindowsShortcut", InstallFileOpFileWindowsShortcut, 7,0,0},
|
||||
{"fileMacAlias", InstallFileOpFileMacAlias, 2,0,0},
|
||||
{"fileUnixLink", InstallFileOpFileUnixLink, 2,0,0},
|
||||
|
||||
// -- documented but never supported --
|
||||
{"deleteRegisteredFile", InstallDeleteComponent, 1},
|
||||
{"deleteRegisteredFile", InstallDeleteComponent, 1,0,0},
|
||||
|
||||
// -- obsolete forms for temporary compatibility --
|
||||
{"abortInstall", InstallAbortInstall, 1},
|
||||
{"finalizeInstall", InstallFinalizeInstall, 0},
|
||||
{"startInstall", InstallStartInstall, 4},
|
||||
{0}
|
||||
{"abortInstall", InstallAbortInstall, 1,0,0},
|
||||
{"finalizeInstall", InstallFinalizeInstall, 0,0,0},
|
||||
{"startInstall", InstallStartInstall, 4,0,0},
|
||||
{nsnull,nsnull,0,0,0}
|
||||
};
|
||||
|
||||
|
||||
|
||||
@ -741,19 +741,19 @@ InstallTriggerGlobalGetVersion(JSContext *cx, JSObject *obj, uintN argc, jsval *
|
||||
static JSFunctionSpec InstallTriggerGlobalMethods[] =
|
||||
{
|
||||
// -- obsolete forms, do not document. Kept for 4.x compatibility
|
||||
{"UpdateEnabled", InstallTriggerGlobalUpdateEnabled, 0},
|
||||
{"StartSoftwareUpdate", InstallTriggerGlobalStartSoftwareUpdate, 2},
|
||||
{"CompareVersion", InstallTriggerGlobalCompareVersion, 5},
|
||||
{"GetVersion", InstallTriggerGlobalGetVersion, 2},
|
||||
{"updateEnabled", InstallTriggerGlobalUpdateEnabled, 0},
|
||||
{"UpdateEnabled", InstallTriggerGlobalUpdateEnabled, 0,0,0},
|
||||
{"StartSoftwareUpdate", InstallTriggerGlobalStartSoftwareUpdate, 2,0,0},
|
||||
{"CompareVersion", InstallTriggerGlobalCompareVersion, 5,0,0},
|
||||
{"GetVersion", InstallTriggerGlobalGetVersion, 2,0,0},
|
||||
{"updateEnabled", InstallTriggerGlobalUpdateEnabled, 0,0,0},
|
||||
// -- new forms to match JS style --
|
||||
{"enabled", InstallTriggerGlobalUpdateEnabled, 0},
|
||||
{"install", InstallTriggerGlobalInstall, 2},
|
||||
{"installChrome", InstallTriggerGlobalInstallChrome, 2},
|
||||
{"startSoftwareUpdate", InstallTriggerGlobalStartSoftwareUpdate, 2},
|
||||
{"compareVersion", InstallTriggerGlobalCompareVersion, 5},
|
||||
{"getVersion", InstallTriggerGlobalGetVersion, 2},
|
||||
{0}
|
||||
{"enabled", InstallTriggerGlobalUpdateEnabled, 0,0,0},
|
||||
{"install", InstallTriggerGlobalInstall, 2,0,0},
|
||||
{"installChrome", InstallTriggerGlobalInstallChrome, 2,0,0},
|
||||
{"startSoftwareUpdate", InstallTriggerGlobalStartSoftwareUpdate, 2,0,0},
|
||||
{"compareVersion", InstallTriggerGlobalCompareVersion, 5,0,0},
|
||||
{"getVersion", InstallTriggerGlobalGetVersion, 2,0,0},
|
||||
{nsnull,nsnull,0,0,0}
|
||||
};
|
||||
|
||||
|
||||
@ -769,7 +769,7 @@ static JSConstDoubleSpec diff_constants[] =
|
||||
{ CHROME_LOCALE, "LOCALE" },
|
||||
{ CHROME_CONTENT, "CONTENT" },
|
||||
{ CHROME_ALL, "PACKAGE" },
|
||||
{0}
|
||||
{0,nsnull}
|
||||
};
|
||||
|
||||
|
||||
|
||||
@ -523,10 +523,10 @@ static JSPropertySpec InstallVersionProperties[] =
|
||||
//
|
||||
static JSFunctionSpec InstallVersionMethods[] =
|
||||
{
|
||||
{"init", InstallVersionInit, 1},
|
||||
{"toString", InstallVersionToString, 0},
|
||||
{"compareTo", InstallVersionCompareTo, 1},
|
||||
{0}
|
||||
{"init", InstallVersionInit, 1,0,0},
|
||||
{"toString", InstallVersionToString, 0,0,0},
|
||||
{"compareTo", InstallVersionCompareTo, 1,0,0},
|
||||
{nsnull,nsnull,0,0,0}
|
||||
};
|
||||
|
||||
static JSConstDoubleSpec version_constants[] =
|
||||
@ -540,7 +540,7 @@ static JSConstDoubleSpec version_constants[] =
|
||||
{ nsIDOMInstallVersion::MINOR_DIFF_MINUS, "MINOR_DIFF_MINUS" },
|
||||
{ nsIDOMInstallVersion::MAJOR_DIFF, "MAJOR_DIFF" },
|
||||
{ nsIDOMInstallVersion::MAJOR_DIFF_MINUS, "MAJOR_DIFF_MINUS" },
|
||||
{0}
|
||||
{0,nsnull}
|
||||
};
|
||||
|
||||
|
||||
|
||||
@ -185,9 +185,9 @@ static JSConstDoubleSpec winprofile_constants[] =
|
||||
//
|
||||
static JSFunctionSpec WinProfileMethods[] =
|
||||
{
|
||||
{"getString", WinProfileGetString, 2},
|
||||
{"writeString", WinProfileWriteString, 3},
|
||||
{0}
|
||||
{"getString", WinProfileGetString, 2,0,0},
|
||||
{"writeString", WinProfileWriteString, 3,0,0},
|
||||
{nsnull,nsnull,0,0,0}
|
||||
};
|
||||
|
||||
PRInt32
|
||||
|
||||
@ -703,22 +703,22 @@ static JSConstDoubleSpec winreg_constants[] =
|
||||
//
|
||||
static JSFunctionSpec WinRegMethods[] =
|
||||
{
|
||||
{"setRootKey", WinRegSetRootKey, 1},
|
||||
{"keyExists", WinRegKeyExists, 1},
|
||||
{"valueExists", WinRegValueExists, 2},
|
||||
{"isKeyWritable", WinRegIsKeyWritable, 1},
|
||||
{"createKey", WinRegCreateKey, 2},
|
||||
{"deleteKey", WinRegDeleteKey, 1},
|
||||
{"deleteValue", WinRegDeleteValue, 2},
|
||||
{"setValueString", WinRegSetValueString, 3},
|
||||
{"getValueString", WinRegGetValueString, 2},
|
||||
{"setValueNumber", WinRegSetValueNumber, 3},
|
||||
{"getValueNumber", WinRegGetValueNumber, 2},
|
||||
{"setValue", WinRegSetValue, 3},
|
||||
{"getValue", WinRegGetValue, 2},
|
||||
{"enumKeys", WinRegEnumKeys, 2},
|
||||
{"enumValueNames", WinRegEnumValueNames, 2},
|
||||
{0}
|
||||
{"setRootKey", WinRegSetRootKey, 1,0,0},
|
||||
{"keyExists", WinRegKeyExists, 1,0,0},
|
||||
{"valueExists", WinRegValueExists, 2,0,0},
|
||||
{"isKeyWritable", WinRegIsKeyWritable, 1,0,0},
|
||||
{"createKey", WinRegCreateKey, 2,0,0},
|
||||
{"deleteKey", WinRegDeleteKey, 1,0,0},
|
||||
{"deleteValue", WinRegDeleteValue, 2,0,0},
|
||||
{"setValueString", WinRegSetValueString, 3,0,0},
|
||||
{"getValueString", WinRegGetValueString, 2,0,0},
|
||||
{"setValueNumber", WinRegSetValueNumber, 3,0,0},
|
||||
{"getValueNumber", WinRegGetValueNumber, 2,0,0},
|
||||
{"setValue", WinRegSetValue, 3,0,0},
|
||||
{"getValue", WinRegGetValue, 2,0,0},
|
||||
{"enumKeys", WinRegEnumKeys, 2,0,0},
|
||||
{"enumValueNames", WinRegEnumValueNames, 2,0,0},
|
||||
{nsnull,nsnull,0,0,0}
|
||||
};
|
||||
|
||||
PRInt32
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user