a cute day night switch for android
Clone or download
Latest commit 61a2213 Jul 22, 2017
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.idea Version 1 Jul 16, 2017
demo minor changes Jul 22, 2017
gradle/wrapper Version 1 Jul 16, 2017
lib minor changes Jul 22, 2017
.gitignore Version 1 Jul 16, 2017
README.md Optimization Jul 17, 2017
build.gradle Version 1 Jul 16, 2017
demo.gif README.md changes Jul 16, 2017
gradle.properties minor changes Jul 16, 2017
gradlew Version 1 Jul 16, 2017
gradlew.bat Version 1 Jul 16, 2017
settings.gradle Version 1 Jul 16, 2017

README.md

DayNightSwitch

A cute day night switch for android

Inspired from this gif : https://www.uplabs.com/posts/on-off-switch-7af29fd7-131a-4aac-b142-63579710f52f

How to install

Add jitpack in your root build.gradle at the end of repositories:

	allprojects {
		repositories {
			...
			maven { url 'https://jitpack.io' }
		}
	}

Step 2. Add the dependency

	dependencies {
	        compile 'com.github.Mahfa:DayNightSwitch:1.2'
	}

Usage

just add it to your xml layout file

    <com.mahfa.dnswitch.DayNightSwitch
        android:id="@+id/day_night_switch"
        android:layout_width="76dp"
        android:layout_height="40dp"
        android:layout_gravity="center"/>