From 1ffa7fbc199b0122585894c11854976b43d0c946 Mon Sep 17 00:00:00 2001 From: natural-law Date: Fri, 8 Jul 2011 18:13:03 +0800 Subject: [PATCH 1/6] Add DirectorTest and BugsTest on android. --- tests/test.android/jni/tests/Android.mk | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/tests/test.android/jni/tests/Android.mk b/tests/test.android/jni/tests/Android.mk index c9731e5ff6..9b78e87d1a 100644 --- a/tests/test.android/jni/tests/Android.mk +++ b/tests/test.android/jni/tests/Android.mk @@ -11,6 +11,17 @@ LOCAL_SRC_FILES := main.cpp \ ../../../tests/Box2DTestBed/GLES-Render.cpp \ ../../../tests/Box2DTestBed/Test.cpp \ ../../../tests/Box2DTestBed/TestEntries.cpp \ +../../../tests/BugsTest/Bug-1159.cpp \ +../../../tests/BugsTest/Bug-1174.cpp \ +../../../tests/BugsTest/Bug-350.cpp \ +../../../tests/BugsTest/Bug-422.cpp \ +../../../tests/BugsTest/Bug-624.cpp \ +../../../tests/BugsTest/Bug-886.cpp \ +../../../tests/BugsTest/Bug-899.cpp \ +../../../tests/BugsTest/Bug-914.cpp \ +../../../tests/BugsTest/BugsTest.cpp \ +../../../tests/BugsTest/Bug-458/Bug-458.cpp \ +../../../tests/BugsTest/Bug-458/QuestionContainerSprite.cpp \ ../../../tests/ChipmunkTest/Bounce.cpp \ ../../../tests/ChipmunkTest/Joints.cpp \ ../../../tests/ChipmunkTest/LogoSmash.cpp \ @@ -36,6 +47,7 @@ LOCAL_SRC_FILES := main.cpp \ ../../../tests/CocosDenshionTest/CocosDenshionTest.cpp \ ../../../tests/CocosNodeTest/CocosNodeTest.cpp \ ../../../tests/CurlTest/CurlTest.cpp \ +../../../tests/DirectorTest/DirectorTest.cpp \ ../../../tests/DrawPrimitivesTest/DrawPrimitivesTest.cpp \ ../../../tests/EaseActionsTest/EaseActionsTest.cpp \ ../../../tests/EffectsAdvancedTest/EffectsAdvancedTest.cpp \ From 87adeb6f92e88a4e0c4dc9483a91d78a4ed3fb84 Mon Sep 17 00:00:00 2001 From: minggo Date: Fri, 8 Jul 2011 18:24:58 +0800 Subject: [PATCH 2/6] upgrade xcode3 template --- .../___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id | 2 +- .../___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id | 2 +- .../___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id | 2 +- .../___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id | 2 +- tests/test.ios/test.xcodeproj/project.pbxproj.REMOVED.git-id | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/template/xcode3/cocos2d-x_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id b/template/xcode3/cocos2d-x_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id index 0bf1928fdf..ac2c3c3ff9 100644 --- a/template/xcode3/cocos2d-x_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id +++ b/template/xcode3/cocos2d-x_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id @@ -1 +1 @@ -58728dc0be18955fcaabb9d6cd2ead3fdf389132 \ No newline at end of file +ef940d5753a60f54cba21c8c503248f75bd3ab98 \ No newline at end of file diff --git a/template/xcode3/cocos2d-x_box2d_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id b/template/xcode3/cocos2d-x_box2d_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id index ce4b99de99..8cc41a1857 100644 --- a/template/xcode3/cocos2d-x_box2d_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id +++ b/template/xcode3/cocos2d-x_box2d_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id @@ -1 +1 @@ -f04508231e03751a17872c963c91f97e4335132a \ No newline at end of file +55a23e272c4ae52bb22a27f5bd0f4309bcb4c683 \ No newline at end of file diff --git a/template/xcode3/cocos2d-x_chipmunk_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id b/template/xcode3/cocos2d-x_chipmunk_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id index 754a4eabba..3d600f7633 100644 --- a/template/xcode3/cocos2d-x_chipmunk_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id +++ b/template/xcode3/cocos2d-x_chipmunk_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id @@ -1 +1 @@ -62513e048519ce58a6a7b19d444f751b0e6ae9a4 \ No newline at end of file +e927644074613ed3644c897bdb0912660335380e \ No newline at end of file diff --git a/template/xcode3/cocos2d-x_lua_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id b/template/xcode3/cocos2d-x_lua_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id index de5d0bb0c7..dfdf378814 100644 --- a/template/xcode3/cocos2d-x_lua_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id +++ b/template/xcode3/cocos2d-x_lua_app/___PROJECTNAME___.xcodeproj/project.pbxproj.REMOVED.git-id @@ -1 +1 @@ -c8cbd6aa2f9f570eda299b591f7b2903a4c954c7 \ No newline at end of file +dec21d9705b1a93bf01aac9fb46e3e65996adfba \ No newline at end of file diff --git a/tests/test.ios/test.xcodeproj/project.pbxproj.REMOVED.git-id b/tests/test.ios/test.xcodeproj/project.pbxproj.REMOVED.git-id index 29ac90871b..0099622afa 100644 --- a/tests/test.ios/test.xcodeproj/project.pbxproj.REMOVED.git-id +++ b/tests/test.ios/test.xcodeproj/project.pbxproj.REMOVED.git-id @@ -1 +1 @@ -e7091c4916f64410b2c21e12c9943931c427ecdf \ No newline at end of file +ca6671a2edbcbfdddbb140f60d4a868feab7747f \ No newline at end of file From fd04420c9bdb65df5bb06c5121d78da25e195912 Mon Sep 17 00:00:00 2001 From: Max Aksenov Date: Sat, 9 Jul 2011 13:04:29 -0700 Subject: [PATCH 3/6] [airplay] fix - if you do not use this "MemFlags0 = USE_STACK_ALLOCATOR" then it solves the problems related to incorrect memory allocation ... I tested it on Marmalade Mac Simulator and IPad device. Not tested on Maramlade Windows Simulator.... --- HelloWorld/Resource/app.icf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/HelloWorld/Resource/app.icf b/HelloWorld/Resource/app.icf index db207a6c09..5cbbb8a49f 100644 --- a/HelloWorld/Resource/app.icf +++ b/HelloWorld/Resource/app.icf @@ -1,7 +1,7 @@ [S3E] MemSize=[s3e]SCREENSIZE + 50331648 -MemFlags0=USE_STACK_ALLOCATOR +#MemFlags0=USE_STACK_ALLOCATOR FixScreenOrientation = 1 From 7f07574630dcdb39a0eade120af5a141d0b3b98f Mon Sep 17 00:00:00 2001 From: Max Aksenov Date: Sat, 9 Jul 2011 13:05:22 -0700 Subject: [PATCH 4/6] [airplay] fix - if you do not use this "MemFlags0 = USE_STACK_ALLOCATOR" then it solves the problems related to incorrect memory allocation ... I tested it on Marmalade Mac Simulator and IPad device. Not tested on Maramlade Windows Simulator.... --- tests/Res/app.icf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/Res/app.icf b/tests/Res/app.icf index 74ed0ce9aa..589c89a583 100644 --- a/tests/Res/app.icf +++ b/tests/Res/app.icf @@ -1,7 +1,7 @@ [S3E] MemSize=[s3e]SCREENSIZE + 50331648 -MemFlags0=USE_STACK_ALLOCATOR +#MemFlags0=USE_STACK_ALLOCATOR FixScreenOrientation = 1 From 36474b2131cd424c476959d39355a0d278160d0c Mon Sep 17 00:00:00 2001 From: natural-law Date: Mon, 11 Jul 2011 10:11:40 +0800 Subject: [PATCH 5/6] Add DirectorTest and BugsTest on wophone. --- tests/test.wophone/Makefile.ARM | 48 +++++++++++ tests/test.wophone/test.wophone.vcproj | 108 +++++++++++++++++++++++++ 2 files changed, 156 insertions(+) diff --git a/tests/test.wophone/Makefile.ARM b/tests/test.wophone/Makefile.ARM index fe05a5e51f..b58a2514dd 100644 --- a/tests/test.wophone/Makefile.ARM +++ b/tests/test.wophone/Makefile.ARM @@ -50,6 +50,17 @@ OBJECTS = \ $(OBJECTS_DIR)/GLES-Render.o \ $(OBJECTS_DIR)/Test.o \ $(OBJECTS_DIR)/TestEntries.o \ + $(OBJECTS_DIR)/Bug-1159.o \ + $(OBJECTS_DIR)/Bug-1174.o \ + $(OBJECTS_DIR)/Bug-350.o \ + $(OBJECTS_DIR)/Bug-422.o \ + $(OBJECTS_DIR)/Bug-624.o \ + $(OBJECTS_DIR)/Bug-886.o \ + $(OBJECTS_DIR)/Bug-899.o \ + $(OBJECTS_DIR)/Bug-914.o \ + $(OBJECTS_DIR)/BugsTest.o \ + $(OBJECTS_DIR)/Bug-458.o \ + $(OBJECTS_DIR)/QuestionContainerSprite.o \ $(OBJECTS_DIR)/Bounce.o \ $(OBJECTS_DIR)/cocos2dChipmunkDemo.o \ $(OBJECTS_DIR)/drawSpace.o \ @@ -75,6 +86,7 @@ OBJECTS = \ $(OBJECTS_DIR)/CocosDenshionTest.o \ $(OBJECTS_DIR)/CocosNodeTest.o \ $(OBJECTS_DIR)/CurlTest.o \ + $(OBJECTS_DIR)/DirectorTest.o \ $(OBJECTS_DIR)/DrawPrimitivesTest.o \ $(OBJECTS_DIR)/EaseActionsTest.o \ $(OBJECTS_DIR)/EffectsAdvancedTest.o \ @@ -168,6 +180,39 @@ $(OBJECTS_DIR)/Test.o : ../tests/Box2DTestBed/Test.cpp $(OBJECTS_DIR)/TestEntries.o : ../tests/Box2DTestBed/TestEntries.cpp $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/TestEntries.o ../tests/Box2DTestBed/TestEntries.cpp +$(OBJECTS_DIR)/Bug-1159.o : ../tests/BugsTest/Bug-1159.cpp + $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/Bug-1159.o ../tests/BugsTest/Bug-1159.cpp + +$(OBJECTS_DIR)/Bug-1174.o : ../tests/BugsTest/Bug-1174.cpp + $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/Bug-1174.o ../tests/BugsTest/Bug-1174.cpp + +$(OBJECTS_DIR)/Bug-350.o : ../tests/BugsTest/Bug-350.cpp + $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/Bug-350.o ../tests/BugsTest/Bug-350.cpp + +$(OBJECTS_DIR)/Bug-422.o : ../tests/BugsTest/Bug-422.cpp + $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/Bug-422.o ../tests/BugsTest/Bug-422.cpp + +$(OBJECTS_DIR)/Bug-624.o : ../tests/BugsTest/Bug-624.cpp + $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/Bug-624.o ../tests/BugsTest/Bug-624.cpp + +$(OBJECTS_DIR)/Bug-886.o : ../tests/BugsTest/Bug-886.cpp + $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/Bug-886.o ../tests/BugsTest/Bug-886.cpp + +$(OBJECTS_DIR)/Bug-899.o : ../tests/BugsTest/Bug-899.cpp + $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/Bug-899.o ../tests/BugsTest/Bug-899.cpp + +$(OBJECTS_DIR)/Bug-914.o : ../tests/BugsTest/Bug-914.cpp + $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/Bug-914.o ../tests/BugsTest/Bug-914.cpp + +$(OBJECTS_DIR)/BugsTest.o : ../tests/BugsTest/BugsTest.cpp + $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/BugsTest.o ../tests/BugsTest/BugsTest.cpp + +$(OBJECTS_DIR)/Bug-458.o : ../tests/BugsTest/Bug-458/Bug-458.cpp + $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/Bug-458.o ../tests/BugsTest/Bug-458/Bug-458.cpp + +$(OBJECTS_DIR)/QuestionContainerSprite.o : ../tests/BugsTest/Bug-458/QuestionContainerSprite.cpp + $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/QuestionContainerSprite.o ../tests/BugsTest/Bug-458/QuestionContainerSprite.cpp + $(OBJECTS_DIR)/Bounce.o : ../tests/ChipmunkTest/Bounce.cpp $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/Bounce.o ../tests/ChipmunkTest/Bounce.cpp @@ -243,6 +288,9 @@ $(OBJECTS_DIR)/CocosNodeTest.o : ../tests/CocosNodeTest/CocosNodeTest.cpp $(OBJECTS_DIR)/CurlTest.o : ../tests/CurlTest/CurlTest.cpp $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/CurlTest.o ../tests/CurlTest/CurlTest.cpp +$(OBJECTS_DIR)/DirectorTest.o : ../tests/DirectorTest/DirectorTest.cpp + $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/DirectorTest.o ../tests/DirectorTest/DirectorTest.cpp + $(OBJECTS_DIR)/DrawPrimitivesTest.o : ../tests/DrawPrimitivesTest/DrawPrimitivesTest.cpp $(CXX) -c $(CXX_FLAGS) $(INCLUDE_PATH) $(LAST_INCLUDE_PATH) -o $(OBJECTS_DIR)/DrawPrimitivesTest.o ../tests/DrawPrimitivesTest/DrawPrimitivesTest.cpp diff --git a/tests/test.wophone/test.wophone.vcproj b/tests/test.wophone/test.wophone.vcproj index 3ac251b90a..231ece1337 100644 --- a/tests/test.wophone/test.wophone.vcproj +++ b/tests/test.wophone/test.wophone.vcproj @@ -970,6 +970,114 @@ > + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Date: Mon, 11 Jul 2011 10:12:29 +0800 Subject: [PATCH 6/6] fix the usage of sort() --- cocos2dx/touch_dispatcher/CCTouchDispatcher.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cocos2dx/touch_dispatcher/CCTouchDispatcher.cpp b/cocos2dx/touch_dispatcher/CCTouchDispatcher.cpp index 5586a90da8..9b48f529b6 100644 --- a/cocos2dx/touch_dispatcher/CCTouchDispatcher.cpp +++ b/cocos2dx/touch_dispatcher/CCTouchDispatcher.cpp @@ -264,7 +264,7 @@ CCTouchHandler* CCTouchDispatcher::findHandler(CCTouchDelegate *pDelegate) void CCTouchDispatcher::rearrangeHandlers(CCMutableArray *pArray) { - sort(pArray->begin(), pArray->end(), less); + std::sort(pArray->begin(), pArray->end(), less); } void CCTouchDispatcher::setPriority(int nPriority, CCTouchDelegate *pDelegate)