2011-02-12 74 views

回答

3

使用相结合的简单ToggleButtonStateListDrawable设定为背景。

ToggleButton的样本被发现here

基本上,您可以为按钮的选中和未选中状态创建图像。在StateListDrawable中设置适当的图像,并将StateListDrawable设置为ToggleButtos的背景。

+0

谢谢,我已经成功地使用StateListDrawable自定义切换按钮。 – Faren 2011-02-13 15:02:13