diff --git a/cocos/2d/CCNode.cpp b/cocos/2d/CCNode.cpp index 456517391a..3410c2d399 100644 --- a/cocos/2d/CCNode.cpp +++ b/cocos/2d/CCNode.cpp @@ -491,21 +491,6 @@ void Node::setPositionZ(float positionZ) setGlobalZOrder(positionZ); } -void Node::setNormalizedPosition(const cocos2d::Point &position) -{ - _normalizedPosition = position; - Size s = Director::getInstance()->getVisibleSize(); - Point p; - p.x = s.width * position.x; - p.y = s.height * position.y; - setPosition(p); -} - -const Point& Node::getNormalizedPosition() const -{ - return _normalizedPosition; -} - ssize_t Node::getChildrenCount() const { return _children.size(); diff --git a/cocos/2d/CCNode.h b/cocos/2d/CCNode.h index bd88ec0b2f..fbb506d371 100644 --- a/cocos/2d/CCNode.h +++ b/cocos/2d/CCNode.h @@ -386,15 +386,6 @@ public: virtual float getPositionZ() const; CC_DEPRECATED_ATTRIBUTE virtual float getVertexZ() const { return getPositionZ(); } - /** Sets the position using normalized coordinates. - - (0,0) means bottom,left corner - - (1,1) means top,right corner - - (0.5,0.5) means center - */ - virtual void setNormalizedPosition(const Point& position); - /** returns the normalized position */ - const Point& getNormalizedPosition() const; - /** * Changes the X skew angle of the node in degrees. * @@ -1499,7 +1490,6 @@ protected: Point _position; ///< position of the node float _positionZ; ///< OpenGL real Z position - Point _normalizedPosition; ///< position in normalized coordinates float _skewX; ///< skew angle on x-axis float _skewY; ///< skew angle on y-axis