Explorar o código

fixed domkit visible default=true

Nicolas Cannasse %!s(int64=5) %!d(string=hai) anos
pai
achega
5e9bdd034a
Modificáronse 1 ficheiros con 4 adicións e 0 borrados
  1. 4 0
      h2d/domkit/BaseComponents.hx

+ 4 - 0
h2d/domkit/BaseComponents.hx

@@ -275,6 +275,10 @@ class ObjectComp implements h2d.domkit.Object implements domkit.Component.Compon
 		o.rotation = v * Math.PI / 180;
 		o.rotation = v * Math.PI / 180;
 	}
 	}
 
 
+	static function set_visible(o:h2d.Object, ?v = true) {
+		o.visible = v;
+	}
+
 	static function set_scale(o:h2d.Object,v) {
 	static function set_scale(o:h2d.Object,v) {
 		if(v != null) {
 		if(v != null) {
 			o.scaleX = v.x;
 			o.scaleX = v.x;