Ver Fonte

report interactive size in getSize

ncannasse há 8 anos atrás
pai
commit
da0e72354d
1 ficheiros alterados com 1 adições e 1 exclusões
  1. 1 1
      h2d/Interactive.hx

+ 1 - 1
h2d/Interactive.hx

@@ -40,7 +40,7 @@ class Interactive extends Drawable implements hxd.SceneEvents.Interactive {
 
 	override function getBoundsRec( relativeTo, out, forSize ) {
 		super.getBoundsRec(relativeTo, out, forSize);
-		if( backgroundColor != null ) addBounds(relativeTo, out, 0, 0, Std.int(width), Std.int(height));
+		if( backgroundColor != null || forSize ) addBounds(relativeTo, out, 0, 0, Std.int(width), Std.int(height));
 	}
 
 	override function onParentChanged() {