1.21 gigawatts
1.21 gigawatts

Reputation: 17770

How do you set the scroll bar skin on a single List instance?

I've created a scrollbar skin that I'm able to apply to all List components using the following CSS:

<fx:Style>
    @namespace s "library://ns.adobe.com/flex/spark";

    s|List s|HScrollBar {
        skinClass: ClassReference("com.skins.myScroller.MyHorizontalScrollerSkin");
        fixedThumbSize:true;
    }

</fx:Style>

The design has changed and now I need to apply this skin to only one List instance. How do I do this (preferring CSS or inline if possible)?

Upvotes: 0

Views: 313

Answers (1)

RIAstar
RIAstar

Reputation: 11912

Just use a class selector for the specific List, like this:

.myList s|VScrollBar {
    skinClass: ClassReference("net.riastar.skin.VScrollBarSkin");
}

<s:List styleName="myList" />

Upvotes: 1

Related Questions