Feeds:
Posts
Comments

Posts Tagged ‘spark Button CSS Skins’

CSS Class selector
.DeleteSkin{
upSkin: Embed(source=’assets/swf/Assets.swf#delete’, scaleGridLeft=10, scaleGridRight=25, scaleGridTop=5, scaleGridBottom=8);
overSkin:Embed(source=’assets/swf/Assets.swf#delete’, scaleGridLeft=10, scaleGridRight=25, scaleGridTop=5, scaleGridBottom=8);
downSkin:Embed(source=’assets/swf/Assets.swf#delete’, scaleGridLeft=10, scaleGridRight=25, scaleGridTop=5, scaleGridBottom=8);
skinClass: ClassReference(“assets.skins.ButtonSkin”);
}
ButtonSkin.mxml
<?xml version=”1.0″ encoding=”utf-8″?>
<s:SparkSkin xmlns:fx=”http://ns.adobe.com/mxml/2009&#8243;
xmlns:s=”library://ns.adobe.com/flex/spark”
minWidth=”14″ minHeight=”14″
alpha.disabled=”0.5″>
<!– states –>
<s:states>
<s:State name=”up” />
<s:State name=”over” />
<s:State name=”down” />
<s:State name=”disabled” />
</s:states>
<!– host component –>
<fx:Metadata> <![CDATA[ [HostComponent(“spark.components.Button”)]]]></fx:Metadata>
<s:HGroup horizontalCenter=”0″ verticalCenter=”0″ verticalAlign=”middle” horizontalAlign=”center” left=”0″ right=”0″ top=”0″ bottom=”0″>
<s:BitmapImage
source.up=”{hostComponent.getStyle(‘upSkin’)}”
source.over=”{hostComponent.getStyle(‘overSkin’)}”
source.down=”{hostComponent.getStyle(‘downSkin’)}” width=”100%” height=”100%”/>
</s:HGroup>
</s:SparkSkin>
Advertisements

Read Full Post »