-
Notifications
You must be signed in to change notification settings - Fork 116
feature button states
Harbs edited this page Oct 22, 2017
·
1 revision
It's currently difficult to specify button states using CSS.
Ideally, it should be possible to specify something like this:
.myButton:hover{
background-image: url ('assets/button_hover.png');
background-repeat: no-repeat;
}
.myButton:active{
background-image: url ('assets/button_active.png');
background-repeat: no-repeat;
}
Or something like this as is possible in Flex:
Button.special
{
overSkin: Embed(source="assets/over/special.png");
upSkin: Embed(source="assets/up/special.png");
downSkin: Embed(source="assets/down/special.png");
disabledSkin: Embed(source="assets/disabled/special.png");
}
Part of the problem is that ImageButton
has no view and ImageButton
wraps <img>
in HTML. In Flash there is a view which has different Sprite
s for the different states. I'm not sure if there's a reason why the HTML component does not do the same.
Apache®, Apache Royale, Royale™, and the Royale logo are either registered trademarks or trademarks of the Apache Software Foundation in the United States and/or other countries.