mirror of https://github.com/axmolengine/axmol.git
format code
This commit is contained in:
parent
42e7e3bbe8
commit
561945d6cd
|
@ -565,9 +565,9 @@ void ScrollView::onAfterDraw()
|
||||||
void ScrollView::visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags)
|
void ScrollView::visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t parentFlags)
|
||||||
{
|
{
|
||||||
// quick return if not visible
|
// quick return if not visible
|
||||||
if (!isVisible())
|
if (!isVisible())
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
uint32_t flags = processParentFlags(parentTransform, parentFlags);
|
uint32_t flags = processParentFlags(parentTransform, parentFlags);
|
||||||
|
@ -583,23 +583,23 @@ void ScrollView::visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t
|
||||||
this->beforeDraw();
|
this->beforeDraw();
|
||||||
bool visibleByCamera = isVisitableByVisitingCamera();
|
bool visibleByCamera = isVisitableByVisitingCamera();
|
||||||
|
|
||||||
if (!_children.empty())
|
if (!_children.empty())
|
||||||
{
|
{
|
||||||
int i=0;
|
int i=0;
|
||||||
|
|
||||||
// draw children zOrder < 0
|
// draw children zOrder < 0
|
||||||
for( ; i < _children.size(); i++ )
|
for( ; i < _children.size(); i++ )
|
||||||
{
|
{
|
||||||
Node *child = _children.at(i);
|
Node *child = _children.at(i);
|
||||||
if ( child->getLocalZOrder() < 0 )
|
if ( child->getLocalZOrder() < 0 )
|
||||||
{
|
{
|
||||||
child->visit(renderer, _modelViewTransform, flags);
|
child->visit(renderer, _modelViewTransform, flags);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// this draw
|
// this draw
|
||||||
if (visibleByCamera)
|
if (visibleByCamera)
|
||||||
|
@ -619,7 +619,7 @@ void ScrollView::visit(Renderer *renderer, const Mat4 &parentTransform, uint32_t
|
||||||
|
|
||||||
this->afterDraw();
|
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)
|
bool ScrollView::onTouchBegan(Touch* touch, Event* event)
|
||||||
|
|
Loading…
Reference in New Issue