Commit Graph

289 Commits

Author SHA1 Message Date
Dhilan007 6217641105 add miss bind 2013-11-18 18:00:42 +08:00
Dhilan007 8b14575d7e bind gui and studio. 2013-11-18 16:54:52 +08:00
samuele3 80f3a7d57a Merge branch 'develop' of https://github.com/cocos2d/cocos2d-x into developAssetsManager
Conflicts:
	build/cocos2d_samples.xcodeproj/project.pbxproj
	cocos/scripting/lua/bindings/LuaScriptHandlerMgr.h
	cocos/scripting/lua/script/Cocos2dConstants.lua
2013-11-01 17:17:21 +08:00
James Chen daf4e22819 [Bindings] Skip Label::getLettersInfo 2013-11-01 15:34:08 +08:00
samuelhu 7c45ddafe2 Merge branch 'develop' of https://github.com/cocos2d/cocos2d-x into developAssetsManager
Conflicts:
	build/cocos2d_libs.xcodeproj/project.pbxproj
2013-10-31 17:22:14 +08:00
Dhilan007 3305dd1de3 issues #2905:add miss file 2013-10-23 17:05:27 +08:00
samuelhu 5f769b2313 Merge branch 'develop' of https://github.com/cocos2d/cocos2d-x into developAssetsManager 2013-10-22 16:52:44 +08:00
samuelhu be1f17ca0f issue #3037:Add assetsmananger lua binding and a releated test sample 2013-10-22 16:14:49 +08:00
Dhilan007 f11dba586a issue #2905:modification vs-project for folder structure change 2013-10-21 22:09:21 +08:00
James Chen 6fba0dd5db issue #2905: [iOS Mac] TestJavascript works now. 2013-10-16 15:43:59 +08:00
minggo 7b7aabf2de include correct path in cocos2dx.ini to generate audio binding 2013-10-10 16:54:05 +08:00
Dhilan007 20971b0ad2 issues #2895:Synchronize JSB from master to developer 2013-10-08 15:57:34 +08:00
minggo b91b350f2b Merge pull request #3666 from Dhilan007/develop
android platform:fix EditBox not show input box and crash.
2013-09-17 18:33:43 -07:00
boyu0 a454e373c7 issue #2771: move include chipmunk and box2d to cpp 2013-09-17 17:39:08 +08:00
boyu0 b5b6406976 issue #2771: edit compile setting. 2013-09-17 17:09:07 +08:00
Dhilan007 5d8ea9f1e5 JSB:manually bind SpriteBatchNode::getDescendants in "cocos2d_specifics.cpp". 2013-09-17 17:03:45 +08:00
boyu0 89ec5edf78 issue #2771: edit compile setting. 2013-09-17 16:42:24 +08:00
James Chen dd7bfd7b60 Merge branch 'develop' of git://github.com/cocos2d/cocos2d-x into new-event-dispatcher-rebase
Conflicts:
	cocos2dx/CCDirector.h
	cocos2dx/keyboard_dispatcher/CCKeyboardDispatcher.h
	cocos2dx/keypad_dispatcher/CCKeypadDelegate.h
	cocos2dx/keypad_dispatcher/CCKeypadDispatcher.h
	cocos2dx/layers_scenes_transitions_nodes/CCLayer.h
	cocos2dx/menu_nodes/CCMenu.h
	cocos2dx/platform/CCAccelerometerDelegate.h
	cocos2dx/platform/android/CCAccelerometer.h
	cocos2dx/platform/ios/CCAccelerometer.h
	cocos2dx/platform/mac/CCAccelerometer.h
	cocos2dx/platform/win32/CCAccelerometer.h
	cocos2dx/script_support/CCScriptSupport.h
	cocos2dx/touch_dispatcher/CCTouchDelegateProtocol.h
	cocos2dx/touch_dispatcher/CCTouchDispatcher.h
	cocos2dx/touch_dispatcher/CCTouchHandler.h
	extensions/CocoStudio/Components/CCInputDelegate.h
2013-09-13 19:06:09 +08:00
samuele3hu a34ec99014 issue #2784:Add js-binding and lua-binding document 2013-09-13 11:41:20 +08:00
James Chen ce52997fc2 [Dispatcher] Updating tools/tojs/.ini 2013-09-12 15:34:14 +08:00
성낙호 bf4eaa7e7c merged 2013-09-09 18:20:16 +09:00
James Chen f9872e396c closed #2747: Don't skip cc.Sprite.getDisplayFrame. 2013-08-28 18:17:52 +08:00
James Chen c2099f5d3e issue #2732: Moving 'scripting/javascript/bindings/generated' to 'scripting/auto-generated'. 2013-08-27 14:50:53 +08:00
James Chen 7d3edde8f1 issue #2521: Updating tojs/cocos2dx_extension.ini, bind more CCControls. 2013-08-12 11:23:16 +08:00
성낙호 eda9846e6f DelegateProtocol is weak-referenced again 2013-08-08 18:36:56 +09:00
성낙호 1c91e73a8c added jsb support for AssetsMAnager 2013-08-07 14:07:01 +09:00
James Chen 4f740809dd The target needs to be set to 'spidermonkey' when generating jsbindings since we has added 'lua' target yet. 2013-08-07 10:08:00 +08:00
James Chen e08b319726 issue #2170: [JSB] Label is abstract class now. 2013-08-05 12:49:57 +08:00
성낙호 0883723c71 added cc.RemoveSelf 2013-08-02 10:59:16 +09:00
James Chen bb3ee262b8 Updating README.mdown for the reason of bindings-generator doesn't support windows. 2013-07-29 08:33:10 +08:00
James Chen d4dcf44380 [Win32] Removing bindings-generator support, since the clang3.3 of windows can't work with c++11 well, I don't know why, so disable win32 support temporary. 2013-07-29 08:27:59 +08:00
James Chen 7c7d21dd03 issue #2407: more best practices fixes, more getter and const.. 2013-07-19 14:57:54 +08:00
James Chen 6ffac07a81 More getter functions: e.g. MenuItemFont::fontSize --> MenuItemFont::getFontSize 2013-07-19 11:08:47 +08:00
James Chen a9eea0a887 issue #2407: Updating jsb_deprecated.js and cocos2dx.ini. 2013-07-17 17:38:03 +08:00
James Chen 7e4e34d992 [ci skip]Update cocos2dx.ini, don't genergate bindings for DrawNode::listenBackToForeground. 2013-07-17 14:36:10 +08:00
samuele3hu 596eb9df3e issue #2377:Modify tojs/cocos2dx.ini and a function name 2013-07-16 16:45:57 +08:00
samuele3hu 1761669832 issue #2377:Merge branch 'develop' of https://github.com/cocos2d/cocos2d-x into ScriptHandlerMgr 2013-07-16 12:47:40 +08:00
James Chen ebf382b02f issue #2405: Removing deprecated methods in 'skip' section in cocos2dx.ini since bindings-generator will not bind deprecated methods now. 2013-07-16 10:03:25 +08:00
samuele3hu c955a559bf issue #2377:Del register/unregister function in .cpp and .h files 2013-07-16 09:55:06 +08:00
James Chen 759831c1d8 issue #2397: Application::sharedApplication --> Application::getInstance. 2013-07-15 16:24:42 +08:00
James Chen dda40ce9ab Updating cocos2dx.ini, ignore "FileUtils::purgeFileUtils" for JSB. 2013-07-12 16:49:13 +08:00
James Chen 33c37f5f9d issue #2397: CCTextureCache:sharedTextureCache --> CCTextureCache:getInstance. 2013-07-12 14:44:24 +08:00
James Chen 6038d69183 issue #2397: sharedSpriteFrameCache --> getInstance, purgeSharedSpriteFrameCache --> destroyInstance. 2013-07-12 14:12:58 +08:00
James Chen 41957f06c9 issue #2397: sharedAnimationCache --> getInstance. 2013-07-12 13:54:56 +08:00
James Chen 853a503d2f issue #2397: Updating bindings configuration. [Lua and JS]. 2013-07-12 13:48:31 +08:00
James Chen 74339b6d0e issue #2397: Updating cocos2d.ini and CCFIleUtils.pkg. 2013-07-12 12:53:20 +08:00
James Chen c07eda8894 issue #2129: Updating cocos2dx.ini. 2013-07-08 15:19:46 +08:00
James Chen e03091f934 Updating tojs/cocos2dx.ini, visit needs to be exposed to JS since it's used for RenderTexture. 2013-07-05 15:18:04 +08:00
James Chen d446f90016 close #2285: Updating tools/tojs/cocos2d-x.ini. 2013-07-02 17:48:06 +08:00
James Chen 34871d47af close #2347: Updating tools/tojs/cocos2dx.ini. 2013-07-01 22:34:57 +08:00
James Chen 14208cfda9 Only skip ^visit$ 2013-06-26 16:35:41 +08:00
James Chen e1b1eee46d issue #2313: Ignores `visit` and exposes ClippingNode to JS. [Not finished] 2013-06-26 16:29:45 +08:00
James Chen e96c807087 clang+llvm-3.1 --> clang+llvm-3.3 2013-06-21 21:49:23 +08:00
James Chen 992ea78f53 Using llvm 3.3 and android cxx-stl 4.7. 2013-06-21 21:27:45 +08:00
James Chen 14b07af56c issue #2129: CC_Reader --> _Reader. 2013-06-20 15:08:22 +08:00
James Chen da6af26cd8 issue #2129: Updating cocos2dx.ini. 2013-06-20 14:58:01 +08:00
James Chen c7456af00e issue #2129: Updating tojs/cocos2d.ini and tojs/cocos2dx_extension.ini. 2013-06-20 14:24:36 +08:00
James Chen 504a9e714e issue #2300: copy --> clone for luabinding. 2013-06-19 12:08:26 +08:00
James Chen 5d5a5be71c Don't generate js binding glue code for CCMenuItem.*::initWithCallback. 2013-06-06 16:21:27 +08:00
James Chen cda02af1e7 Using CC_DEPRECATED_ATTRIBUTE to mark functions as deprecated. Don't bind CCMenuItem::setCallback automatically. 2013-06-05 17:35:19 +08:00
James Chen e4a8cad3c2 Updating cocos2dx_extension.ini 2013-06-05 14:56:06 +08:00
James Chen de6a531115 Update cocos2dx.ini, don't genergate bindings for CCCallFunc::initWithFunction 2013-06-04 10:13:27 +08:00
Ricardo Quesada fb566426b9 enable C++11 in tojs 2013-06-03 13:09:49 -07:00
James Chen 86af06c909 fixed #2244: cc.Camera.getEyeXYZ, cc.Camera.getCenterXYZ, cc.Camera.getUpXYZ return bad values. 2013-06-03 15:32:07 +08:00
Jaroslaw Lewandowski 3f7c506638 Ability to save/retrieve CCData into/from CCUserDefault 2013-05-29 01:06:41 +01:00
samuele3hu 26267aee56 issue #2103 modify some skip function name to tools/tojs/cocos2dx_extension.ini 2013-05-24 16:27:03 +08:00
samuele3hu a1ef0db7b7 issue #2103 add some skip function name to tools/tojs/cocos2dx_extension.ini 2013-05-24 15:40:02 +08:00
James Chen ff616a1d29 Updating cocos2dx.ini. CCTMXLayer::positionAt --> getPositionAt 2013-05-21 18:20:49 +08:00
James Chen 361004d4d3 Update cocos2dx.ini, don't generate binding for CCSet::acceptVisitor. 2013-05-21 14:52:54 +08:00
carlo morgantini 315999edad new "manual" conversion for ccFontDefinition in JS and also updated LabelTest.js using this new way of passing parameters to CCLabelTTF through ccFontDefinition 2013-05-15 16:37:08 -07:00
carlo morgantini ef1a123b42 no more bingins for ccTextDefinition 2013-05-15 16:37:08 -07:00
carlo morgantini 934c8f5115 bindings for CCTextDefinition 2013-05-15 16:35:24 -07:00
James Chen a9f3ae0e33 Updating tools/tojs/cocos2dx.ini, adding CCReuseGrid and CCStopGrid bindings. 2013-04-25 14:32:52 +08:00
James Chen dee0f37983 issue #2071: Updating cocos2dx.ini, skipping auto-generating cc.TMXLayer.getTiles(), it needs be bound manually . 2013-04-19 17:23:39 +08:00
James Chen 5f478e1e0a issue #2064: Updating tools/tojs/cocos2dx.ini. 2013-04-18 13:53:43 +08:00
James Chen a2c71f8e89 Exposing CCApplication to js. 2013-04-09 14:42:12 +08:00
James Chen 0d5d2e54fd cxx-generator ~> bindings-generator. 2013-04-09 13:47:12 +08:00
James Chen d29ff33df1 Updating genbindings.sh, cxx-generator ~> bindings-generator. 2013-04-09 11:03:39 +08:00
Rohan Kuruvilla f945f4efd6 Adding the generator config file. Includes CCGLProgram, CCShaderCache classes 2013-03-27 23:59:30 -07:00
James Chen 4a9e426d2d Renaming function: initWithFile ~> init for CCSprite, CCSpriteBatchNode. 2013-03-20 18:34:28 +08:00
Rohan Kuruvilla f53b3633be Updating generator for CCBAnimationManager bindings 2013-03-18 16:06:48 -07:00
James Chen f57a751a48 fixed #1837: Refactoring schedule binding codes.
* 1) We need bind cc.Node.scheduleUpdate and cc.Scheduler.scheduleUpdate manually since `schedules` need to be associated with _schedFunc_target_ht and _schedObj_target_ht
* 2) Bind cc.Scheduler.unscheduleCallbackForTarget.
2013-03-18 15:29:53 +08:00
James Chen 3ffd531648 Fixing bugs of genbindings-win32.bat on windows xp. 2013-03-17 14:48:00 +08:00
James Chen 77469346cf fixed #1642: Renaming `extra_flag` to `extra_flags`. 2013-03-17 14:11:15 +08:00
James Chen 5c30675455 fixed #1642: Updating genbindings.sh, adding empty variable `extra_flags`. 2013-03-17 14:10:20 +08:00
James Chen 6bc5c3b0a8 fixed #1642: Cxx-generator now works ok on windows, it uses the same config file as unix. For details, please refer to README file. 2013-03-17 14:07:41 +08:00
James Chen 92d0e1c983 Uncommenting jsb_CCEditBox_prototype, updating the submodule of cxx-generator to the latest one. 2013-03-15 11:53:56 +08:00
James Chen 3e33868a63 fixed #1824: Exposed cc.EditBox to js. 2013-03-14 18:14:16 +08:00
James Chen 29aa62d923 fixed #1830: Using JS::CompileOptions::setUTF8(true) to compile script. 2013-03-13 18:10:54 +08:00
James Chen 3aaf5cabdb Updating cocos2dx.ini(adding CCScheduler to 'abstract_class' section) and adding ScriptingCore::getGlobalObject method. 2013-03-12 22:03:37 +08:00
James Chen 69b2b13325 fixed #1748: Generating jsb_cocos2dx_extension_auto.hpp/.cpp. It was separated from original `cocos2dx.hpp/cpp`.
Developer could remove redundant jsbinding codes now.
2013-03-11 16:39:28 +08:00
James Chen fc5f7547a3 fixed #1808: Adding config section 'script_control_cpp' and set it to 'no'. 2013-03-10 14:00:30 +08:00
James Chen 1a42e85219 fixed #1808: Updated the submodule of cxx-generator and fixed some compilation errors after that. 2013-03-10 13:55:29 +08:00
James Chen e4b5ee97b0 Updated cocos2dx.ini. 2013-03-01 10:58:16 +08:00
James Chen 501a2612cb tab ~> 4 spaces . 2013-03-01 10:45:07 +08:00
James Chen 7093807f3f CCNodeRGA isn't a pure abstract class anymore. Updated tools/tojs/cocos2d.ini. 2013-03-01 10:41:06 +08:00
James Chen cf33a4538d fixed #1730: Binds CCScrollView and CCTableView to js. 2013-02-21 10:06:22 +08:00
James Chen 2694cb150b CCFileUtils::s|gSearchPath -> CCFileUtils::s\gSearchPaths. 2013-01-29 09:56:38 +08:00
James Chen 119115502d issue #1683: Making some api of CCFileUtils more c++ friendly by using std::vector rather than CCArray. 2013-01-26 22:31:57 +08:00
James Chen 0a42829428 issue #1667: Adding file name lookup support for iOS and Android, TBD: Other platform supports. 2013-01-18 18:05:32 +08:00
James Chen 8a4d7cfe12 fixed #1653: Updated the configuration files of jsbinding. 2013-01-15 10:17:01 +08:00
James Chen bf0cc23336 Update tools/tojs/README.mdown 2013-01-06 18:31:35 +08:00
James Chen b712a9349a fixed #1642: Updated tools/tojs/README.mdown. 2013-01-06 18:24:02 +08:00
James Chen b5b1df6a07 Added tools/tojs/README.mdown. 2013-01-06 18:10:43 +08:00
James Chen be1be2771b fixed #1642: Adding tools for generating jsbinding codes on windows. 2013-01-06 18:01:44 +08:00
James Chen df5c6aae04 Binded more actions to js. 2012-12-27 13:38:48 +08:00
James Chen e301b9af1e Updated cocos2dx.ini. Only skip CCNode::setPosition and CCSprite::setPosition. 2012-12-25 09:52:30 +08:00
James Chen 15d02e4db8 Merge branch 'iss1581-fix-jsbinding-bugs' of https://github.com/dumganhar/cocos2d-x into iss1583-js-tests
Conflicts:
	scripting/javascript/bindings/cocos2d_specifics.cpp
2012-11-30 21:43:44 +08:00
James Chen 344fc5ca6f issue #1583: Updated tools/tojs/cocos2dx.ini. 2012-11-30 21:16:34 +08:00
James Chen a814066601 issue #1581: JSBinding bug fixes.
Some fixes of JSBinding codes:
[1] Check whether the proxy was already added in JS_NEW_PROXY
[2] In struct schedFunc_proxy_t, JSScheduleWrapper* --> CCArray*
Reason: One js function may correspond to many targets. To debug this, you could refer to JSScheduleWrapper::dump function. It will prove that i'm right. :)
[3] In ScriptingCore::cleanupSchedulesAndActions function, we must invoke unschedule for all targets and remove the proxy both in _schedFunc_target_ht and _schedTarget_native_ht, otherwise the hash tables will grow bigger and bigger, so I added a new function JSScheduleWrapper::removeAllTargetsForNatiaveNode to make this things easier.
[4] To easily find out the bugs of binding codes, I add JS_SetGCZeal in ScriptingCore::createGlobalContext, it only works in DEBUG mode.
[5] In js_cocos2dx_CCNode_getChildren, we should add the generated array to root to avoid gc happen when invoking JS_SetElement.
[6] The JSCallFuncWrapper isn't needed since an action will be run by a cc.Node and it will be released at the CCNode::cleanup.
[7] Some improvements of JSScheduleWrapper class.
[8] Added a new function JSScheduleWrapper::setTarget, it's for js_CCNode_unschedule to find out which target need to be unscheduled.
[9] Commented JS_SetReservedSlot in js_CCNode_scheduleOnce and js_CCNode_schedule.
Reason:
For js_CCNode_scheduleOnce: Don't add the callback function to the reserved slot of this js object.Since the class of js object may be inherited from cocos class(e.g. cc.Sprite). The subclass will not contain reserved slots. It will crash if invoking this.
For js_CCNode_schedule: Don't add js callback function to the reserved slot of scheduler js object. Since the scheduler is an object always rooted.
So the callback function might not be released when gc comes.I looked inside the implementation of cc.Node.schedule, and it doesn't use JS_SetReservedSlot there.
2012-11-28 22:04:55 +08:00
James Chen a1ebfd9ed8 Don't add CCNode::removeChild to skip field. 2012-11-23 15:12:42 +08:00
Rohan Kuruvilla 36bbd80b68 Adding changes to CCBreader 2012-11-23 15:08:55 +08:00
James Chen f701248e58 issue #1564: Updated tools/tojs/cocos2dx.ini. 2012-11-22 17:19:15 +08:00
James Chen 1a3891970f Updated tools/tojs/cocos2dx.ini. 2012-11-22 15:35:42 +08:00
folecr f111602adf Don't generate JS bindings for CCTimer::getSelector 2012-11-19 15:56:11 -08:00
James Chen b95ff53747 Updated cocos2dx.ini. 2012-11-16 16:00:25 +08:00
James Chen 682faa5870 issue #1530: Don't export CCUserDefault to js since it has a private constructor. Do it in the future. 2012-11-16 15:58:21 +08:00
James Chen bb6df91749 issue #1530: Exported CCUserDefault to js. 2012-11-16 15:58:18 +08:00
Rohan Kuruvilla 39a4e6a19e Fixing bindings bug for CCScheduler. Also adding custom bindings for TMXLayer. Also updating ini 2012-11-16 15:56:27 +08:00
James Chen 26af535521 issue #1549: Updated cocos2dx.ini. Renamed some functions. 2012-11-06 14:19:27 +08:00
James Chen 4a6d922ea4 issue #1549: Updated tools/tojs/cocos2dx.ini. 2012-11-05 18:45:39 +08:00
James Chen f88aa5058d Merge branch 'gles20' of https://github.com/rohankuruvilla/cocos2d-x into rohan-ccb
Conflicts:
	scripting/javascript/bindings/cocos2d_specifics.cpp
	scripting/javascript/bindings/cocos2d_specifics.hpp
	tools/tojs/cocos2dx.ini
2012-11-02 18:15:25 +08:00
James Chen 05b1b7c2c3 Updated cocos2dx.ini. Renamed some methods exported to js. 2012-11-02 15:13:12 +08:00
Rohan Kuruvilla ea92936c1f Adding bindings for CCBReader and other improvements.
1. Added additional CCBReader bindings, including callback support for animationCompleted
2. Improved design for JS CallbackWrappers
3. Added bindings for pDistance
4. Updating cocos2dx.ini
2012-11-01 00:08:01 -07:00
Rohan Kuruvilla 2fbb748b7c Adding sections for CCBReader bindings generation as well as renaming other bindings 2012-11-01 00:06:24 -07:00
Rohan Kuruvilla e7ac758b9f Updating bindings to match cocos2d-html5 2012-10-11 18:45:22 -07:00
James Chen bb135e49d1 issue #1469: Ignored 'getBlendFunc' and 'setBlendFunc' for CCSpriteBatchNode,CCMotionStreak,CCAtlasNode,CCParticleBatchNode,CCLayerColor,CCParticleSystem. 2012-10-10 15:23:13 +08:00
Rohan Kuruvilla 12292afee6 Adding CCSchedule bindings. Also adding CCOrbitCamera bindings and modifying cocos2dx.ini 2012-10-09 15:03:14 -07:00
folecr d57842bec5 Generate bindings for CocosDenshion's SimpleAudioEngine
* Bindings configured to rename SimpleAudioEngine to AudioEngine
2012-09-27 13:39:49 -07:00
folecr d01b6093d8 gendbings.sh generates userconf.ini
* ... and reads userconf.ini from current working directory
 * ... also specify that this script is run by /bin/bash
2012-09-24 21:48:12 -07:00
folecr 1a6581383c Spidermonkey headers are not used for generation 2012-09-24 21:48:11 -07:00
folecr 5ff4d73688 Use new directives for renaming functions and classes 2012-09-21 11:41:08 -07:00
folecr 901146e2ee Synchronize cocos2dx.ini 2012-09-21 11:41:08 -07:00
Rohan Kuruvilla bc35e73179 Updating cocos2dx.ini including,
1. Adding key "rename_classes"
2. Renaming key "rename" to "rename_functions"
3. Adding CCParticleSystemQuad specific stuff
2012-09-20 18:02:17 -07:00
Rohan Kuruvilla 9e1e64509b Copying changes previously made into cxx-generator/targets/spidermonkey/common
1. Fixed memory leak while removing proxy objects
2. Fixed JS Context restart
3. Added JS conversion for CCArray
4. Updated generated bindings with some more classes
2012-09-20 18:02:17 -07:00
folecr 92ce4d4783 Update cocos2dx.ini so that the generated bindings and the TestJavascript app compile. 2012-09-19 13:21:26 -07:00
folecr 2c1c58eeb9 Update path calculation. 2012-09-18 17:02:21 -07:00
folecr 4c1fad1c6c chmod u+x genbindings.sh 2012-09-18 17:02:21 -07:00
folecr 8a688ef424 Script and config file for generating bindings 2012-09-18 17:02:21 -07:00