Merge pull request #5523 from ricardoquesada/remove_setnormalized

Removes setNormalizedPosition
This commit is contained in:
Ricardo Quesada 2014-03-03 16:39:27 -08:00
commit 0cfb5169a4
2 changed files with 0 additions and 25 deletions

View File

@ -491,21 +491,6 @@ void Node::setPositionZ(float positionZ)
setGlobalZOrder(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 ssize_t Node::getChildrenCount() const
{ {
return _children.size(); return _children.size();

View File

@ -386,15 +386,6 @@ public:
virtual float getPositionZ() const; virtual float getPositionZ() const;
CC_DEPRECATED_ATTRIBUTE virtual float getVertexZ() const { return getPositionZ(); } 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. * Changes the X skew angle of the node in degrees.
* *
@ -1499,7 +1490,6 @@ protected:
Point _position; ///< position of the node Point _position; ///< position of the node
float _positionZ; ///< OpenGL real Z position float _positionZ; ///< OpenGL real Z position
Point _normalizedPosition; ///< position in normalized coordinates
float _skewX; ///< skew angle on x-axis float _skewX; ///< skew angle on x-axis
float _skewY; ///< skew angle on y-axis float _skewY; ///< skew angle on y-axis