Hi,
I have an HBox with a borderSkin property set to a Class I found that draws
dashed borders.
var imageContainer:HBox = new HBox();
imageContainer.setStyle('borderSkin',com.skins.DashedBorder);
When you click on/off the skin I want to toggle the borderSkin property, i.e.
remove the dashed lines and make it look selected/unselected, i.e.
if(container.name != _selectedImage.name){
container.setStyle('borderStyle',null);
container.setStyle('borderThickness',null);
container.setStyle('borderSkin',null);
}else{
_selectedImage.setStyle('borderStyle','solid');
_selectedImage.setStyle('borderThickness', '2');
_selectedImage.setStyle('borderSkin', com.skins.DashedBorder);
}
That doesn't work. It draws the borderSkin just fine when I first instantiate
the HBox, but when I start toggling it's gone.
However, it works fine if I'm just using a borderColor and not a skin, a la:
if(container.name != _selectedImage.name){
container.setStyle('borderStyle',null);
container.setStyle('borderThickness',null);
container.setStyle('borderColor',null);
}else{
_selectedImage.setStyle('borderStyle','solid');
_selectedImage.setStyle('borderThickness', '2');
_selectedImage.setStyle('borderColor', 'green');
}
So....I guess you can't toggle borderSkin property...is that right?
Thanks for any tips.