浏览代码

don't take twice the padding into account when we have a background

ncannasse 9 年之前
父节点
当前提交
a8556cbc24
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      h2d/Flow.hx

+ 1 - 1
h2d/Flow.hx

@@ -230,7 +230,7 @@ class Flow extends Sprite {
 			if( !isInline ) {
 				super.getBoundsRec(relativeTo, out, false);
 				// TODO : use proper addBounds instead
-				if( relativeTo == parent ) {
+				if( relativeTo == parent && background == null ) {
 					out.xMax += paddingRight + borderWidth;
 					out.yMax += paddingBottom + borderHeight;
 				}