issue #1640: Added some files to iOS Project.

This commit is contained in:
James Chen 2013-01-05 17:41:19 +08:00
parent 421cf31b34
commit 8a21f4fa3c
7 changed files with 77 additions and 1273 deletions

View File

@ -7,6 +7,7 @@
#include "cocos2d_specifics.hpp"
#include "js_bindings_chipmunk_registration.h"
#include "js_bindings_ccbreader.h"
#include "js_bindings_system_registration.h"
USING_NS_CC;
using namespace CocosDenshion;
@ -65,6 +66,7 @@ bool AppDelegate::applicationDidFinishLaunching()
sc->addRegisterCallback(register_cocos2dx_js_extensions);
sc->addRegisterCallback(register_CCBuilderReader);
sc->addRegisterCallback(jsb_register_chipmunk);
sc->addRegisterCallback(jsb_register_system);
sc->start();

View File

@ -1 +1 @@
dbc21f560a549efc0a6927f266e6c22f326f4e17
8c25f4e08196498edb3752dc9672b14525454fd7

View File

@ -7,6 +7,8 @@
#include "cocos2d_specifics.hpp"
#include "js_bindings_chipmunk_registration.h"
#include "js_bindings_ccbreader.h"
#include "js_bindings_system_registration.h"
USING_NS_CC;
using namespace CocosDenshion;
@ -40,6 +42,7 @@ bool AppDelegate::applicationDidFinishLaunching()
sc->addRegisterCallback(register_cocos2dx_js_extensions);
sc->addRegisterCallback(register_CCBuilderReader);
sc->addRegisterCallback(jsb_register_chipmunk);
sc->addRegisterCallback(jsb_register_system);
sc->start();
CCScriptEngineProtocol *pEngine = ScriptingCore::getInstance();

View File

@ -0,0 +1 @@
9d5b1248e92a3f45928c60181236b6a3c3e7617f

View File

@ -104,16 +104,27 @@
15A3D77D1682F407002FB0C5 /* CCPhysicsDebugNode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15A3D73F1682F407002FB0C5 /* CCPhysicsDebugNode.cpp */; };
15A3D77E1682F407002FB0C5 /* CCPhysicsSprite.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 15A3D7411682F407002FB0C5 /* CCPhysicsSprite.cpp */; };
15A3D7881682F456002FB0C5 /* res in Resources */ = {isa = PBXBuildFile; fileRef = 15A3D7871682F456002FB0C5 /* res */; };
15A3D7931682F49A002FB0C5 /* jsb_constants.js in Resources */ = {isa = PBXBuildFile; fileRef = 15A3D5871682F3BC002FB0C5 /* jsb_constants.js */; };
15A3D7941682F49A002FB0C5 /* jsb_constants_chipmunk.js in Resources */ = {isa = PBXBuildFile; fileRef = 15A3D5881682F3BC002FB0C5 /* jsb_constants_chipmunk.js */; };
15A3D7951682F49A002FB0C5 /* jsb_constants_cocos2d.js in Resources */ = {isa = PBXBuildFile; fileRef = 15A3D5891682F3BC002FB0C5 /* jsb_constants_cocos2d.js */; };
15A3D7961682F49A002FB0C5 /* jsb_constants_cocosbuilder.js in Resources */ = {isa = PBXBuildFile; fileRef = 15A3D58A1682F3BC002FB0C5 /* jsb_constants_cocosbuilder.js */; };
15A3D7971682F49A002FB0C5 /* jsb_constants_gl.js in Resources */ = {isa = PBXBuildFile; fileRef = 15A3D58B1682F3BC002FB0C5 /* jsb_constants_gl.js */; };
15A3D7981682F4A3002FB0C5 /* boot-jsb.js in Resources */ = {isa = PBXBuildFile; fileRef = 15A3D7891682F470002FB0C5 /* boot-jsb.js */; };
15A3D7991682F4A3002FB0C5 /* levels.js in Resources */ = {isa = PBXBuildFile; fileRef = 15A3D78A1682F470002FB0C5 /* levels.js */; };
15A3D79A1682F4A3002FB0C5 /* main.js in Resources */ = {isa = PBXBuildFile; fileRef = 15A3D78B1682F470002FB0C5 /* main.js */; };
15A3D79B1682F4A3002FB0C5 /* resources-jsb.js in Resources */ = {isa = PBXBuildFile; fileRef = 15A3D78C1682F470002FB0C5 /* resources-jsb.js */; };
15A3D79C1682F4A3002FB0C5 /* watermelon_with_me.js in Resources */ = {isa = PBXBuildFile; fileRef = 15A3D78D1682F470002FB0C5 /* watermelon_with_me.js */; };
1AAF0C02169829E200C5F611 /* jsb_chipmunk.js in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF0BFB169829E200C5F611 /* jsb_chipmunk.js */; };
1AAF0C03169829E200C5F611 /* jsb_cocos2d.js in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF0BFC169829E200C5F611 /* jsb_cocos2d.js */; };
1AAF0C04169829E200C5F611 /* jsb_cocosbuilder.js in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF0BFD169829E200C5F611 /* jsb_cocosbuilder.js */; };
1AAF0C05169829E200C5F611 /* jsb_debugger.js in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF0BFE169829E200C5F611 /* jsb_debugger.js */; };
1AAF0C06169829E200C5F611 /* jsb_opengl.js in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF0BFF169829E200C5F611 /* jsb_opengl.js */; };
1AAF0C07169829E200C5F611 /* jsb_sys.js in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF0C00169829E200C5F611 /* jsb_sys.js */; };
1AAF0C08169829E200C5F611 /* jsb.js in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF0C01169829E200C5F611 /* jsb.js */; };
1AAF0C09169829F200C5F611 /* jsb_chipmunk.js in Resources */ = {isa = PBXBuildFile; fileRef = 1AAF0BFB169829E200C5F611 /* jsb_chipmunk.js */; };
1AAF0C0A169829F200C5F611 /* jsb_cocos2d.js in Resources */ = {isa = PBXBuildFile; fileRef = 1AAF0BFC169829E200C5F611 /* jsb_cocos2d.js */; };
1AAF0C0B169829F200C5F611 /* jsb_cocosbuilder.js in Resources */ = {isa = PBXBuildFile; fileRef = 1AAF0BFD169829E200C5F611 /* jsb_cocosbuilder.js */; };
1AAF0C0C169829F200C5F611 /* jsb_debugger.js in Resources */ = {isa = PBXBuildFile; fileRef = 1AAF0BFE169829E200C5F611 /* jsb_debugger.js */; };
1AAF0C0D169829F200C5F611 /* jsb_opengl.js in Resources */ = {isa = PBXBuildFile; fileRef = 1AAF0BFF169829E200C5F611 /* jsb_opengl.js */; };
1AAF0C0E169829F200C5F611 /* jsb_sys.js in Resources */ = {isa = PBXBuildFile; fileRef = 1AAF0C00169829E200C5F611 /* jsb_sys.js */; };
1AAF0C0F169829F200C5F611 /* jsb.js in Resources */ = {isa = PBXBuildFile; fileRef = 1AAF0C01169829E200C5F611 /* jsb.js */; };
1AAF0C1516982A0000C5F611 /* js_bindings_system_functions.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF0C1116982A0000C5F611 /* js_bindings_system_functions.cpp */; };
1AAF0C1616982A0000C5F611 /* js_bindings_system_registration.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF0C1316982A0000C5F611 /* js_bindings_system_registration.cpp */; };
A92275421517C094001B78AA /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A92275411517C094001B78AA /* QuartzCore.framework */; };
A92275441517C094001B78AA /* OpenGLES.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A92275431517C094001B78AA /* OpenGLES.framework */; };
A92275461517C094001B78AA /* OpenAL.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = A92275451517C094001B78AA /* OpenAL.framework */; };
@ -164,11 +175,6 @@
15A3D5831682F3BC002FB0C5 /* cocos2dx.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = cocos2dx.hpp; sourceTree = "<group>"; };
15A3D5841682F3BC002FB0C5 /* cocos2dxapi.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = cocos2dxapi.js; sourceTree = "<group>"; };
15A3D5851682F3BC002FB0C5 /* README */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = README; sourceTree = "<group>"; };
15A3D5871682F3BC002FB0C5 /* jsb_constants.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = jsb_constants.js; sourceTree = "<group>"; };
15A3D5881682F3BC002FB0C5 /* jsb_constants_chipmunk.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = jsb_constants_chipmunk.js; sourceTree = "<group>"; };
15A3D5891682F3BC002FB0C5 /* jsb_constants_cocos2d.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = jsb_constants_cocos2d.js; sourceTree = "<group>"; };
15A3D58A1682F3BC002FB0C5 /* jsb_constants_cocosbuilder.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = jsb_constants_cocosbuilder.js; sourceTree = "<group>"; };
15A3D58B1682F3BC002FB0C5 /* jsb_constants_gl.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = jsb_constants_gl.js; sourceTree = "<group>"; };
15A3D58C1682F3BC002FB0C5 /* js_bindings_ccbreader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = js_bindings_ccbreader.cpp; sourceTree = "<group>"; };
15A3D58D1682F3BC002FB0C5 /* js_bindings_ccbreader.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = js_bindings_ccbreader.h; sourceTree = "<group>"; };
15A3D58E1682F3BC002FB0C5 /* js_bindings_chipmunk_auto_classes.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = js_bindings_chipmunk_auto_classes.cpp; sourceTree = "<group>"; };
@ -360,6 +366,18 @@
15A3D78B1682F470002FB0C5 /* main.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; name = main.js; path = ../../Shared/games/WatermelonWithMe/main.js; sourceTree = "<group>"; };
15A3D78C1682F470002FB0C5 /* resources-jsb.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; name = "resources-jsb.js"; path = "../../Shared/games/WatermelonWithMe/resources-jsb.js"; sourceTree = "<group>"; };
15A3D78D1682F470002FB0C5 /* watermelon_with_me.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; name = watermelon_with_me.js; path = ../../Shared/games/WatermelonWithMe/watermelon_with_me.js; sourceTree = "<group>"; };
1AAF0BFB169829E200C5F611 /* jsb_chipmunk.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = jsb_chipmunk.js; sourceTree = "<group>"; };
1AAF0BFC169829E200C5F611 /* jsb_cocos2d.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = jsb_cocos2d.js; sourceTree = "<group>"; };
1AAF0BFD169829E200C5F611 /* jsb_cocosbuilder.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = jsb_cocosbuilder.js; sourceTree = "<group>"; };
1AAF0BFE169829E200C5F611 /* jsb_debugger.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = jsb_debugger.js; sourceTree = "<group>"; };
1AAF0BFF169829E200C5F611 /* jsb_opengl.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = jsb_opengl.js; sourceTree = "<group>"; };
1AAF0C00169829E200C5F611 /* jsb_sys.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = jsb_sys.js; sourceTree = "<group>"; };
1AAF0C01169829E200C5F611 /* jsb.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = jsb.js; sourceTree = "<group>"; };
1AAF0C1016982A0000C5F611 /* js_bindings_system_functions_registration.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = js_bindings_system_functions_registration.h; sourceTree = "<group>"; };
1AAF0C1116982A0000C5F611 /* js_bindings_system_functions.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = js_bindings_system_functions.cpp; sourceTree = "<group>"; };
1AAF0C1216982A0000C5F611 /* js_bindings_system_functions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = js_bindings_system_functions.h; sourceTree = "<group>"; };
1AAF0C1316982A0000C5F611 /* js_bindings_system_registration.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = js_bindings_system_registration.cpp; sourceTree = "<group>"; };
1AAF0C1416982A0000C5F611 /* js_bindings_system_registration.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = js_bindings_system_registration.h; sourceTree = "<group>"; };
A922753D1517C094001B78AA /* WatermelonWithMe.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = WatermelonWithMe.app; sourceTree = BUILT_PRODUCTS_DIR; };
A92275411517C094001B78AA /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; };
A92275431517C094001B78AA /* OpenGLES.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenGLES.framework; path = System/Library/Frameworks/OpenGLES.framework; sourceTree = SDKROOT; };
@ -439,32 +457,37 @@
isa = PBXGroup;
children = (
15A3D57D1682F3BC002FB0C5 /* cocos2d_specifics.cpp */,
15A3D57E1682F3BC002FB0C5 /* cocos2d_specifics.hpp */,
15A3D57F1682F3BC002FB0C5 /* cocosjs_manual_conversions.cpp */,
15A3D5801682F3BC002FB0C5 /* cocosjs_manual_conversions.h */,
15A3D5811682F3BC002FB0C5 /* generated */,
15A3D5861682F3BC002FB0C5 /* js */,
15A3D58C1682F3BC002FB0C5 /* js_bindings_ccbreader.cpp */,
15A3D58D1682F3BC002FB0C5 /* js_bindings_ccbreader.h */,
15A3D58E1682F3BC002FB0C5 /* js_bindings_chipmunk_auto_classes.cpp */,
15A3D5911682F3BC002FB0C5 /* js_bindings_chipmunk_functions.cpp */,
15A3D5941682F3BC002FB0C5 /* js_bindings_chipmunk_manual.cpp */,
15A3D5961682F3BC002FB0C5 /* js_bindings_chipmunk_registration.cpp */,
15A3D5991682F3BC002FB0C5 /* js_bindings_core.cpp */,
1AAF0C1116982A0000C5F611 /* js_bindings_system_functions.cpp */,
1AAF0C1316982A0000C5F611 /* js_bindings_system_registration.cpp */,
15A3D59B1682F3BC002FB0C5 /* js_manual_conversions.cpp */,
15A3D59D1682F3BC002FB0C5 /* ScriptingCore.cpp */,
15A3D5801682F3BC002FB0C5 /* cocosjs_manual_conversions.h */,
15A3D58D1682F3BC002FB0C5 /* js_bindings_ccbreader.h */,
15A3D58F1682F3BC002FB0C5 /* js_bindings_chipmunk_auto_classes.h */,
15A3D5901682F3BC002FB0C5 /* js_bindings_chipmunk_auto_classes_registration.h */,
15A3D5911682F3BC002FB0C5 /* js_bindings_chipmunk_functions.cpp */,
15A3D5921682F3BC002FB0C5 /* js_bindings_chipmunk_functions.h */,
15A3D5931682F3BC002FB0C5 /* js_bindings_chipmunk_functions_registration.h */,
15A3D5941682F3BC002FB0C5 /* js_bindings_chipmunk_manual.cpp */,
15A3D5951682F3BC002FB0C5 /* js_bindings_chipmunk_manual.h */,
15A3D5961682F3BC002FB0C5 /* js_bindings_chipmunk_registration.cpp */,
15A3D5971682F3BC002FB0C5 /* js_bindings_chipmunk_registration.h */,
15A3D5981682F3BC002FB0C5 /* js_bindings_config.h */,
15A3D5991682F3BC002FB0C5 /* js_bindings_core.cpp */,
15A3D59A1682F3BC002FB0C5 /* js_bindings_core.h */,
15A3D59B1682F3BC002FB0C5 /* js_manual_conversions.cpp */,
1AAF0C1216982A0000C5F611 /* js_bindings_system_functions.h */,
1AAF0C1016982A0000C5F611 /* js_bindings_system_functions_registration.h */,
1AAF0C1416982A0000C5F611 /* js_bindings_system_registration.h */,
15A3D59C1682F3BC002FB0C5 /* js_manual_conversions.h */,
15A3D59D1682F3BC002FB0C5 /* ScriptingCore.cpp */,
15A3D59E1682F3BC002FB0C5 /* ScriptingCore.h */,
15A3D59F1682F3BC002FB0C5 /* spidermonkey_specifics.h */,
15A3D5A01682F3BC002FB0C5 /* uthash.h */,
15A3D57E1682F3BC002FB0C5 /* cocos2d_specifics.hpp */,
15A3D5811682F3BC002FB0C5 /* generated */,
15A3D5861682F3BC002FB0C5 /* js */,
);
name = bindings;
path = ../../../../scripting/javascript/bindings;
@ -484,11 +507,13 @@
15A3D5861682F3BC002FB0C5 /* js */ = {
isa = PBXGroup;
children = (
15A3D5871682F3BC002FB0C5 /* jsb_constants.js */,
15A3D5881682F3BC002FB0C5 /* jsb_constants_chipmunk.js */,
15A3D5891682F3BC002FB0C5 /* jsb_constants_cocos2d.js */,
15A3D58A1682F3BC002FB0C5 /* jsb_constants_cocosbuilder.js */,
15A3D58B1682F3BC002FB0C5 /* jsb_constants_gl.js */,
1AAF0BFB169829E200C5F611 /* jsb_chipmunk.js */,
1AAF0BFC169829E200C5F611 /* jsb_cocos2d.js */,
1AAF0BFD169829E200C5F611 /* jsb_cocosbuilder.js */,
1AAF0BFE169829E200C5F611 /* jsb_debugger.js */,
1AAF0BFF169829E200C5F611 /* jsb_opengl.js */,
1AAF0C00169829E200C5F611 /* jsb_sys.js */,
1AAF0C01169829E200C5F611 /* jsb.js */,
);
path = js;
sourceTree = "<group>";
@ -917,16 +942,18 @@
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
1AAF0C09169829F200C5F611 /* jsb_chipmunk.js in Resources */,
1AAF0C0A169829F200C5F611 /* jsb_cocos2d.js in Resources */,
1AAF0C0B169829F200C5F611 /* jsb_cocosbuilder.js in Resources */,
1AAF0C0C169829F200C5F611 /* jsb_debugger.js in Resources */,
1AAF0C0D169829F200C5F611 /* jsb_opengl.js in Resources */,
1AAF0C0E169829F200C5F611 /* jsb_sys.js in Resources */,
1AAF0C0F169829F200C5F611 /* jsb.js in Resources */,
15A3D7981682F4A3002FB0C5 /* boot-jsb.js in Resources */,
15A3D7991682F4A3002FB0C5 /* levels.js in Resources */,
15A3D79A1682F4A3002FB0C5 /* main.js in Resources */,
15A3D79B1682F4A3002FB0C5 /* resources-jsb.js in Resources */,
15A3D79C1682F4A3002FB0C5 /* watermelon_with_me.js in Resources */,
15A3D7931682F49A002FB0C5 /* jsb_constants.js in Resources */,
15A3D7941682F49A002FB0C5 /* jsb_constants_chipmunk.js in Resources */,
15A3D7951682F49A002FB0C5 /* jsb_constants_cocos2d.js in Resources */,
15A3D7961682F49A002FB0C5 /* jsb_constants_cocosbuilder.js in Resources */,
15A3D7971682F49A002FB0C5 /* jsb_constants_gl.js in Resources */,
D446FDA316102D7D000ADA7B /* Default.png in Resources */,
D446FDA516102D82000ADA7B /* Default@2x.png in Resources */,
D446FDA716102D86000ADA7B /* Default-568h@2x.png in Resources */,
@ -1040,6 +1067,15 @@
15A3D77B1682F407002FB0C5 /* CCTableViewCell.cpp in Sources */,
15A3D77D1682F407002FB0C5 /* CCPhysicsDebugNode.cpp in Sources */,
15A3D77E1682F407002FB0C5 /* CCPhysicsSprite.cpp in Sources */,
1AAF0C02169829E200C5F611 /* jsb_chipmunk.js in Sources */,
1AAF0C03169829E200C5F611 /* jsb_cocos2d.js in Sources */,
1AAF0C04169829E200C5F611 /* jsb_cocosbuilder.js in Sources */,
1AAF0C05169829E200C5F611 /* jsb_debugger.js in Sources */,
1AAF0C06169829E200C5F611 /* jsb_opengl.js in Sources */,
1AAF0C07169829E200C5F611 /* jsb_sys.js in Sources */,
1AAF0C08169829E200C5F611 /* jsb.js in Sources */,
1AAF0C1516982A0000C5F611 /* js_bindings_system_functions.cpp in Sources */,
1AAF0C1616982A0000C5F611 /* js_bindings_system_registration.cpp in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};

View File

@ -178,7 +178,7 @@ void js_log(const char *format, ...) {
JSBool JSBCore_platform(JSContext *cx, uint32_t argc, jsval *vp)
{
if (argc==0)
if (argc!=0)
{
JS_ReportError(cx, "Invalid number of arguments in __getPlatform");
return JS_FALSE;
@ -203,7 +203,7 @@ JSBool JSBCore_platform(JSContext *cx, uint32_t argc, jsval *vp)
JSBool JSBCore_version(JSContext *cx, uint32_t argc, jsval *vp)
{
if (argc==0)
if (argc!=0)
{
JS_ReportError(cx, "Invalid number of arguments in __getVersion");
return JS_FALSE;
@ -221,7 +221,7 @@ JSBool JSBCore_version(JSContext *cx, uint32_t argc, jsval *vp)
JSBool JSBCore_os(JSContext *cx, uint32_t argc, jsval *vp)
{
if (argc==0)
if (argc!=0)
{
JS_ReportError(cx, "Invalid number of arguments in __getOS");
return JS_FALSE;