format code

This commit is contained in:
yangxiao 2014-08-14 14:14:25 +08:00
parent 42e7e3bbe8
commit 561945d6cd
1 changed files with 12 additions and 12 deletions

View File

@ -565,9 +565,9 @@ void ScrollView::onAfterDraw()
void ScrollView::visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags)
{
// quick return if not visible
if (!isVisible())
if (!isVisible())
{
return;
return;
}
uint32_t flags = processParentFlags(parentTransform, parentFlags);
@ -583,23 +583,23 @@ void ScrollView::visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t
this->beforeDraw();
bool visibleByCamera = isVisitableByVisitingCamera();
if (!_children.empty())
if (!_children.empty())
{
int i=0;
int i=0;
// draw children zOrder < 0
for( ; i < _children.size(); i++ )
for( ; i < _children.size(); i++ )
{
Node *child = _children.at(i);
if ( child->getLocalZOrder() < 0 )
Node *child = _children.at(i);
if ( child->getLocalZOrder() < 0 )
{
child->visit(renderer, _modelViewTransform, flags);
}
child->visit(renderer, _modelViewTransform, flags);
}
else
{
break;
break;
}
}
}
// this draw
if (visibleByCamera)
@ -619,7 +619,7 @@ void ScrollView::visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t
this->afterDraw();
director->popMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW);
director->popMatrix(MATRIX_STACK_TYPE::MATRIX_STACK_MODELVIEW);
}
bool ScrollView::onTouchBegan(Touch* touch, Event* event)