Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

improve layout basic code for 2d-tasks/issues/1639 #5074

Merged
merged 2 commits into from Aug 8, 2019

Conversation

@knoxHuang
Copy link
Contributor

@knoxHuang knoxHuang commented Aug 2, 2019

Re: cocos-creator/2d-tasks#1639

Changes:

  • 调整 Layout _doLayoutBasic 计算,修复 Layout scale 小于 1 的时候显示效果错误
@@ -817,23 +817,23 @@ var Layout = cc.Class({
}

if (allChildrenBoundingBox) {
var leftBottomInParentSpace = this.node.parent.convertToNodeSpaceAR(cc.v2(allChildrenBoundingBox.x, allChildrenBoundingBox.y));
var leftBottomInParentSpace = this.node.convertToNodeSpaceAR(cc.v2(allChildrenBoundingBox.x, allChildrenBoundingBox.y));
Copy link
Contributor

@2youyou2 2youyou2 Aug 7, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

修改了转换坐标的对象变量名不应该还叫 xxInParentSpace

@2youyou2 2youyou2 merged commit e26e75a into cocos-creator:v2.1.3 Aug 8, 2019
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants