mirror of https://github.com/axmolengine/axmol.git
make CCRect accept width<0 and height<0
This commit is contained in:
parent
db61976a71
commit
fbcb33eefd
|
@ -119,8 +119,8 @@ CCRect& CCRect::operator= (const CCRect& other)
|
|||
|
||||
void CCRect::setRect(float x, float y, float width, float height)
|
||||
{
|
||||
// Only support that, the width and height > 0
|
||||
CCAssert(width >= 0.0f && height >= 0.0f, "width and height of Rect must not less than 0.");
|
||||
// CGRect can support width<0 or height<0
|
||||
// CCAssert(width >= 0.0f && height >= 0.0f, "width and height of Rect must not less than 0.");
|
||||
|
||||
origin.x = x;
|
||||
origin.y = y;
|
||||
|
|
Loading…
Reference in New Issue