Posted inAndroid
Android Development Tips/Tricks
[prezi id='http://prezi.com/oqmxs_vqhcpx/android-development-tiptricks/']
Step 1: Create 2 images for ON and OFF state of toggle button, place these 2 images inside the Drawable folder. FYI, i have used 9-patch tool to create images for the states.
Step 2: Now, create a selector file for your toggle button, which is used to get state of button and define drawable accordingly.