AwesomeToggle
jineshfrancs
11
Visit GitHub RepoCheckboxes

AwesomeToggle

Android Arsenal GitHub issues GitHub forks GitHub stars

A customized toggle button

ScreenShot:

Output sample

In your xml file add this tag to get AwesomeToggle

<test.jinesh.awesometoggleproject.AwesomeToggle
       android:layout_width="100dp"
       android:layout_height="wrap_content"
       android:id="@+id/sample"
       app:inactive_background_color="@color/colorPrimary"
       app:active_background_color="@color/colorAccent"
       app:font_color="@color/white"
       app:inner_toggle_color="@color/white"
       />

You can apply checked change listner in java code to monitor the toggle state changes

  awesomeToggle= (AwesomeToggle) findViewById(R.id.sample);
  awesomeToggle.setOnCheckedChangeListner(new AwesomeToggle.OnCheckedChangeListner() {
            @Override
            public void onChecked(boolean isChecked) {
                
            }
  });
Become a better Android Developer
Millions of developers are learning at MindOrks

Online Training Program

Featured Blogs

Our Team

MindOrks is Certainly one of the best online blog to stay on top of all the Android development news, coding and design patterns. Finally a blog I can count on to keep myself updated with latest and greatest things happening in Android world.

Vipul Shah
Android Developer
Microsoft

Become Pro in Android by watching videos

OUR LEARNERS WORK AT