haxeui / haxeui-heaps

MIT License
31 stars 12 forks source link

Actuator error #4

Open hoseyjoe opened 4 years ago

hoseyjoe commented 4 years ago

HaxeUITest.zip

Click the top left "Click Me!" And get error

42.5> src/HLAdapter.hx:587: Failed to read @0x0:4
42.5> src/HLAdapter.hx:607: Failed to read @0x0:4

Can't cast i32 to enum<haxe.ui.styles.Value>
Called from haxe.ui.styles.animation.util.Actuator._initialize (haxe/ui/styles/animation/util/Actuator.hx line 158)
haxe/ui/styles/animation/util/Actuator.hx:158
Called from haxe.ui.styles.animation.util.Actuator.run (haxe/ui/styles/animation/util/Actuator.hx line 81)
haxe/ui/styles/animation/util/Actuator.hx:81
Called from haxe.ui.styles.animation.util.$Actuator.tween (haxe/ui/styles/animation/util/Actuator.hx line 24)
haxe/ui/styles/animation/util/Actuator.hx:24
Called from Main.reducExpandWidth (Main.hx line 120)
...
hoseyjoe commented 4 years ago

A workaround for this was to us .style.Value instead of numbers. use: Actuator.tween(main.bottomArea, {height: Value.VDimension(PERCENT(50)) }, .5, ao); instead of Actuator.tween(main.bottomArea, { height:50 }, .5, ao);

This was only needed for heaps target