|
Actually they are not custom, but please find below a way to trick Flex in order to specify custom values. When do you need this? When you have a slider on which the minimum and maximum are numbers not so close one to each other or if you just want your slider thumbs to snap to all the values defined as the slider dataProvider. Let’s share the code: layout="vertical" verticalAlign="middle" backgroundColor="white"> private var sliderArray:Array = new Array(3,10,15,18,49); private function formatFunction(item:Object):String { return sliderArray[item.toString()]; } ]]> thumbCount="2" dataTipPlacement="right" allowTrackClick="false" dataTipPrecision="2" values="{[0,sliderArray.length-1]}" minimum="0" maximum="{sliderArray.length-1}" tickInterval="1" labels="{sliderArray}" snapInterval="1" dataTipFormatFunction="formatFunction" /> text="{sliderArray[slider.values[0]]}" width="40" textAlign="right" id="maxVal" /> text="{sliderArray[slider.values[1]]}" width="40" textAlign="right" id="minVal" />
|