Ver código fonte

Proper size computation for video.

clenhof 3 anos atrás
pai
commit
b15ffe546e
1 arquivos alterados com 5 adições e 0 exclusões
  1. 5 0
      h2d/Video.hx

+ 5 - 0
h2d/Video.hx

@@ -448,4 +448,9 @@ class Video extends Drawable {
 		});
 		});
 	}
 	}
 	#end
 	#end
+
+    override function getBoundsRec( relativeTo : Object, out : h2d.col.Bounds, forSize : Bool ) {
+        super.getBoundsRec(relativeTo, out, forSize);
+        if( tile != null ) addBounds(relativeTo, out, tile.dx, tile.dy, tile.width, tile.height);
+    }
 }
 }