我在 SkinnableDataContainer 的自定义外观中使用滚动器组件。我遇到了一个问题,即滚动条的拇指栏在大约 50% 处停止,但这实际上是可滚动区域的末端。实际上,拇指栏应该在滚动轨道的底部。这是滚动条的代码:
<s:SparkSkin xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/halo" bottom="150" >
<!-- Properties of the parent ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
<s:states>
<s:State name="normal" />
<s:State name="disabled" />
</s:states>
<!-- Metadata ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
<fx:Metadata>
[HostComponent("spark.components.SkinnableDataContainer")]
</fx:Metadata>
<!-- UI components ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
<s:Rect left="0" right="0"
bottom="0" top="0"
radiusX="4" radiusY="4" >
<s:fill>
<s:SolidColor id="fillColor" color="0xEFEFEF"/>
</s:fill>
</s:Rect>
<s:Group width="905" height="395" id="mainGroup">
<s:Scroller left="10" right="10" top="4" bottom="10" >
<s:DataGroup id="dataGroup" />
</s:Scroller>
<s:Rect left="0" right="0" top="0" bottom="0">
<s:stroke>
<s:SolidColorStroke weight="1" color="0xD8D8D8"/>
</s:stroke>
</s:Rect>
</s:Group>