chengstory
669de88e73
1. remove any unused functions.
2013-09-10 11:02:50 +08:00
Ricardo Quesada
1393fb356a
SpriteBatchNode: follows C++ best practices
...
removes hungarian notation
uses `int` instead of `unsigned int`
Add more asserts
2013-08-31 10:38:10 -07:00
Ricardo Quesada
f4101d8b25
receives a `const &` instead of `const *`
...
If is more accurate since a `NULL` AffineTransform is not allowed.
Signed-off-by: Ricardo Quesada <ricardoquesada@gmail.com>
2013-08-28 18:30:00 -07:00
Ricardo Quesada
57ce406bdb
More reliable profiling.
...
clock is the first instruction to execute on `EndTimingBlock`
Signed-off-by: Ricardo Quesada <ricardoquesada@gmail.com>
2013-08-28 18:29:09 -07:00
Ricardo Quesada
62c578667b
API compliant with cocos2d-x best practices
...
Uses `int` instead of `unsigned int` as described in the cocos2d-x best practices
Signed-off-by: Ricardo Quesada <ricardoquesada@gmail.com>
2013-08-26 18:07:40 -07:00
Ricardo Quesada
38bfadf7f3
Adds 2 new performance tests
...
Invocation with `for_each()` and using `arrayMakeObjectsPerformSelector`
Signed-off-by: Ricardo Quesada <ricardoquesada@gmail.com>
2013-08-22 18:21:52 -07:00
Ricardo Quesada
2e221ee6cc
Array & Dictionary fixes
...
In many places `Dictionary` and `Array` are not being initialized. In fact `Dictionary` doesn't have the `init()` method creating potential leaks.
Also in objects like `Armature` and the new `LabelTTF`, the `Array` object is not being used a pointer. So it doesn't use the 2 phase initialization, creating potential leaks.
This patch fixes all those issues.
Signed-off-by: Ricardo Quesada <ricardoquesada@gmail.com>
2013-08-21 20:12:09 -07:00
Ricardo Quesada
f9df7cf4e5
Uses high resolution clock for Profiling
...
and adds another average time.
Signed-off-by: Ricardo Quesada <ricardoquesada@gmail.com>
2013-08-20 16:06:34 -07:00
Ricardo Quesada
4c99492589
Profiling: more useful information
...
Prints min,max, #calls
Signed-off-by: Ricardo Quesada <ricardoquesada@gmail.com>
2013-08-20 14:18:06 -07:00
James Chen
c215a1d5a2
Merge pull request #3285 from gkosciolek/fix_for_CCNotificationCenter
...
closed 2611: Fixing the bug that observers with the same target and selector but different sender are the same observer in NotificationCenter.
2013-08-19 23:23:18 -07:00
Timothy Qiu
5ad5cfed7a
Yet another documentation fix.
...
Modified mismatching parameters doc caused by refactoring.
Added the missing doc of some parameters.
Removed Hungarian notation from parts of the code.
2013-08-01 21:40:13 +08:00
Timothy Qiu
5ed8deb9a6
Fixed more documentation errors.
...
Modified mismatching parameters doc caused by refactoring.
Added the missing doc of some parameters.
Fixed incorrect use of doxygen tags.
Removed Hungarian notation from parts of the code.
Replaced 1 tab character with 4 spaces.
2013-08-01 20:55:43 +08:00
Timothy Qiu
bc10c2a01f
Change some doc due to the change of source code.
...
Fixed some incorrect use of doxygen command.
2013-08-01 17:47:37 +08:00
Timothy Qiu
978fc634be
Use C++ code in C++ comments.
...
Removed Hungarian notation from parts of the code.
2013-08-01 16:40:56 +08:00
boyu0
cecfc13bc4
Merge branch 'develop' of https://github.com/cocos2d/cocos2d-x into 2345
2013-07-27 22:06:30 +08:00
Grzegorz Kościółek
2083ab0454
Fix for #2892 .
...
3. Fixed registerScriptObserver method.
2013-07-26 22:42:00 +02:00
Grzegorz Kościółek
3a1d4e7e28
Fix for #2892 .
...
1. Updatet the API documentation and parameter name from "object" to "sender" to reflect it's true purpose.
2. Fixed addObserver and observerExisted because it didn't allowed to add observers to notifications that only differs by sender
2013-07-26 22:20:19 +02:00
Ricardo Quesada
058935aa8d
Removes Hungarian notation
...
Removes Hungarian notation from the code.
2013-07-25 15:53:24 -07:00
boyu0
a2b611d8c3
Refactor Image and Texture2D, combine TexturePVR to Image and Texture2D, and delete TexturePVR
2013-07-25 21:35:00 +08:00
Ricardo Quesada
1f37d4d00a
More best practices fixes and other bug fixes
...
- Adds `CC_REQUIRES_NULL_TERMINATION` to methods that require a NULL at the end
- Removes more Hungarian notations in samples
- s/sprite/scene: fix from previous commit
- `CCLog` -> `log`
- `getLayerNamed` -> `getLayer`
- `getPropertyNamed` -> `getProperty`
- and other small fixes
2013-07-23 15:20:22 -07:00
James Chen
ab7d57feb7
Merge branch 'develop' of https://github.com/cocos2d/cocos2d-x into iss2378-remove-CC_PROPERTY
2013-07-23 20:47:39 +08:00
James Chen
a1c4c73c1c
issue #2378 : More setter/Getter, removing CC_PROPERTY_XXX macros.
2013-07-23 18:26:26 +08:00
minggo
8af95adbdf
Merge pull request #3220 from minggo/develop
...
closed #2393:fix a bug caused by marking functions as deprecated
2013-07-22 23:17:03 -07:00
minggo
b416511e6b
closed #2393:fix a bug caused by marking functions as deprecated
2013-07-23 14:13:44 +08:00
minggo
f6cfe3007f
issue #2412:fix merging conflict
2013-07-23 10:41:11 +08:00
James Chen
1db847ad7c
issue #2344 : ScriptEngineManager::sharedManager --> ScriptEngineManager::getInstance, ScriptEngineManager::purgeSharedManager --> ScriptEngineManager::destroyInstance
2013-07-22 17:24:54 +08:00
James Chen
2228614748
issue #2344 : JSB also uses 'ScriptEngineManager::sharedManager()->getScriptEngine()->sendEvent(XXX);' now.
2013-07-22 17:12:53 +08:00
Ricardo Quesada
89d210bdb3
CCAssert -> CCASSERT
...
and other best pracitces like:
capacity and "index" are ints and not unsigned int (google's recomendation).
It is easier to detect underflow bugs like this
plus other minor improvements
2013-07-19 22:01:27 -07:00
minggo
7704ab9161
issue #2412:remove platform.cpp/.h
2013-07-19 13:42:45 +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
minggo
eada29ee40
issue #2404:created CCDprecated.h and move all global functions and variables into it
2013-07-15 16:14:26 +08:00
samuele3hu
80a6811f9f
Merge branch 'develop' of https://github.com/cocos2d/cocos2d-x into ScriptHandler
2013-07-15 10:39:08 +08:00
minggo
6abe6fce78
closed #2393 : fix conflicts
2013-07-12 18:04:32 +08:00
James Chen
72f35aa14e
issue #2397 : Updating CCUserDefaultAndroid.cpp.
2013-07-12 15:32:37 +08:00
James Chen
f7b9c54cd1
issue #2397 : Updating CCUserDefaultAndroid.cpp.
2013-07-12 15:21:21 +08:00
James Chen
4a7e884de8
issue #2397 : UserDefault::sharedUserDefault() --> UserDefault::getInstance(), UserDefault::purgeSharedUserDefault() --> UserDefault::destroyInstance();
2013-07-12 14:34:57 +08:00
minggo
15096b0716
issue #2393:mark CCPointMake CCSizeMake CCRectMake as deprecated
2013-07-12 14:30:26 +08:00
Ricardo Quesada
cf262c28e2
getInstance() / destroyInstance() are used...
...
... instead of sharedXXX / purgeXXX.
They are more C++ friendly, and also easier to remember.
common files + Mac files + iOS files + tests/samples files were updated.
The old methods are deprecated now.
2013-07-11 15:24:23 -07:00
minggo
c37af8fa77
issue #2393:mark functions in CCPointExtensions deprecated
2013-07-11 16:38:58 +08:00
samuele3hu
9007b9feee
issue #2377:Replace the CallFunc script Handler and repair Testlua Bug
2013-07-11 13:38:25 +08:00
samuele3hu
31d0e492c2
Merge branch 'develop' of https://github.com/cocos2d/cocos2d-x into ScriptHandler
2013-07-10 15:05:02 +08:00
samuele3hu
cf1cbe1bd6
issue #2377:add scriptHandlerMgr and modify ActionManager.lua
2013-07-10 15:04:00 +08:00
James Chen
596c4c3cf2
issue #2387 : Using static_cast instead of C style cast while iterating CCDictionary.
2013-07-09 14:40:43 +08:00
James Chen
9b9fe67d25
issue #2387 : Using static_cast instead of C style cast in iteration of CCArray.
2013-07-09 14:29:51 +08:00
James Chen
1eacab0278
Merge branch 'iss2129-remove_prefix' of https://github.com/minggo/cocos2d-x into minggo-iss2129-remove_prefix
2013-07-08 10:51:07 +08:00
Ricardo Quesada
c65b6f1417
Adds const to more getters
...
adds `const` to more getters.
2013-07-06 22:01:21 -07:00
minggo
04465622b7
issue #2129:remove prefix of types in ccTypes.h
2013-07-05 16:49:22 +08:00
samuele3hu
570f2663f4
issue #2244:Modify ScriptData struct and functions related with sendEvent
2013-07-04 15:44:42 +08:00
samuele3hu
9b08cee01f
issue #22434:make some execute funs into one funs in ScriptEngineProtocol
2013-07-02 15:23:51 +08:00
minggo
8938268183
issue #2329 : remove unneeded codes
2013-06-26 16:42:11 +08:00