diff --git a/cocos2dx/layers_scenes_transitions_nodes/CCLayer.cpp b/cocos2dx/layers_scenes_transitions_nodes/CCLayer.cpp index 36dbf153f2..b85a3e20d0 100644 --- a/cocos2dx/layers_scenes_transitions_nodes/CCLayer.cpp +++ b/cocos2dx/layers_scenes_transitions_nodes/CCLayer.cpp @@ -175,7 +175,6 @@ void CCLayer::setTouchEnabled(bool enabled) } } - void CCLayer::setTouchMode(ccTouchesMode mode) { if(m_eTouchMode != mode) diff --git a/cocos2dx/menu_nodes/CCMenu.cpp b/cocos2dx/menu_nodes/CCMenu.cpp index 147c61b4b0..70d3d93427 100644 --- a/cocos2dx/menu_nodes/CCMenu.cpp +++ b/cocos2dx/menu_nodes/CCMenu.cpp @@ -137,6 +137,8 @@ bool CCMenu::initWithArray(CCArray* pArrayOfItems) if (CCLayer::init()) { setTouchPriority(kCCMenuHandlerPriority); + setTouchMode(kCCTouchesOneByOne); + setTouchEnabled(true); m_bEnabled = true; // menu in the center of the screen diff --git a/cocos2dx/proj.mac/cocos2dx.xcodeproj/project.pbxproj.REMOVED.git-id b/cocos2dx/proj.mac/cocos2dx.xcodeproj/project.pbxproj.REMOVED.git-id index e784f3a3ce..c35a5892c4 100644 --- a/cocos2dx/proj.mac/cocos2dx.xcodeproj/project.pbxproj.REMOVED.git-id +++ b/cocos2dx/proj.mac/cocos2dx.xcodeproj/project.pbxproj.REMOVED.git-id @@ -1 +1 @@ -48a295775479bd5b7fc89114495885a002502849 \ No newline at end of file +25ba4a303b7a9a46a800ee741da634603e2a55d8 \ No newline at end of file diff --git a/extensions/GUI/CCControlExtension/CCControlSwitch.cpp b/extensions/GUI/CCControlExtension/CCControlSwitch.cpp index 33a4f74f1d..f324a51a59 100644 --- a/extensions/GUI/CCControlExtension/CCControlSwitch.cpp +++ b/extensions/GUI/CCControlExtension/CCControlSwitch.cpp @@ -159,7 +159,7 @@ void CCControlSwitchSprite::draw() ccGLEnableVertexAttribs(kCCVertexAttribFlag_PosColorTex); ccGLBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); - getShaderProgram()->setUniformForModelViewProjectionMatrix(); + getShaderProgram()->setUniformsForBuiltins(); glActiveTexture(GL_TEXTURE0); glBindTexture( GL_TEXTURE_2D, getTexture()->getName()); diff --git a/samples/TestCpp/Classes/Box2DTestBed/GLES-Render.cpp b/samples/TestCpp/Classes/Box2DTestBed/GLES-Render.cpp index 097136f665..9f15c5c82e 100644 --- a/samples/TestCpp/Classes/Box2DTestBed/GLES-Render.cpp +++ b/samples/TestCpp/Classes/Box2DTestBed/GLES-Render.cpp @@ -48,7 +48,7 @@ void GLESDebugDraw::initShader( void ) void GLESDebugDraw::DrawPolygon(const b2Vec2* old_vertices, int vertexCount, const b2Color& color) { mShaderProgram->use(); - mShaderProgram->setUniformForModelViewProjectionMatrix(); + mShaderProgram->setUniformsForBuiltins(); b2Vec2* vertices = new b2Vec2[vertexCount]; for( int i=0;iuse(); - mShaderProgram->setUniformForModelViewProjectionMatrix(); + mShaderProgram->setUniformsForBuiltins(); b2Vec2* vertices = new b2Vec2[vertexCount]; for( int i=0;iuse(); - mShaderProgram->setUniformForModelViewProjectionMatrix(); + mShaderProgram->setUniformsForBuiltins(); const float32 k_segments = 16.0f; int vertexCount=16; @@ -130,7 +130,7 @@ void GLESDebugDraw::DrawCircle(const b2Vec2& center, float32 radius, const b2Col void GLESDebugDraw::DrawSolidCircle(const b2Vec2& center, float32 radius, const b2Vec2& axis, const b2Color& color) { mShaderProgram->use(); - mShaderProgram->setUniformForModelViewProjectionMatrix(); + mShaderProgram->setUniformsForBuiltins(); const float32 k_segments = 16.0f; int vertexCount=16; @@ -167,7 +167,7 @@ void GLESDebugDraw::DrawSolidCircle(const b2Vec2& center, float32 radius, const void GLESDebugDraw::DrawSegment(const b2Vec2& p1, const b2Vec2& p2, const b2Color& color) { mShaderProgram->use(); - mShaderProgram->setUniformForModelViewProjectionMatrix(); + mShaderProgram->setUniformsForBuiltins(); mShaderProgram->setUniformLocationWith4f(mColorLocation, color.r, color.g, color.b, 1); @@ -199,7 +199,7 @@ void GLESDebugDraw::DrawTransform(const b2Transform& xf) void GLESDebugDraw::DrawPoint(const b2Vec2& p, float32 size, const b2Color& color) { mShaderProgram->use(); - mShaderProgram->setUniformForModelViewProjectionMatrix(); + mShaderProgram->setUniformsForBuiltins(); mShaderProgram->setUniformLocationWith4f(mColorLocation, color.r, color.g, color.b, 1); @@ -229,7 +229,7 @@ void GLESDebugDraw::DrawString(int x, int y, const char *string, ...) void GLESDebugDraw::DrawAABB(b2AABB* aabb, const b2Color& color) { mShaderProgram->use(); - mShaderProgram->setUniformForModelViewProjectionMatrix(); + mShaderProgram->setUniformsForBuiltins(); mShaderProgram->setUniformLocationWith4f(mColorLocation, color.r, color.g, color.b, 1);