项目作者: gmazzo

项目描述 :
A SeekBarPreference that stores its value in a percentual relation (0 to 1) on max and min values
高级语言: Java
项目地址: git://github.com/gmazzo/android-seekbar-preference.git
创建时间: 2017-02-13T16:58:19Z
项目社区:https://github.com/gmazzo/android-seekbar-preference

开源协议:GNU General Public License v3.0

下载


seekbar-preference

A SeekBarPreference that stores its value in a percentual relation (0 to 1) on max and min values

Import

On your build.gradle add:

  1. repositories {
  2. maven { url 'https://dl.bintray.com/gmazzo/maven' }
  3. }
  4. dependencies {
  5. compile 'com.github.gmazzo:seekbar-preference:0.2'
  6. }

Usage with native android.preference.Preference

In your preferences.xml add:

  1. <gs.preference.PercentSeekBarPreference
  2. android:key="someKey"
  3. android:title="Percent value"
  4. android:defaultValue="0.7"></gs.preference.PercentSeekBarPreference>

Usage with compat android.support.v7.preference.Preference

In your preferences.xml add:

  1. <gs.preference.PercentSeekBarPreferenceCompat
  2. android:key="someKey"
  3. android:title="Percent value"
  4. android:defaultValue="0.7"></gs.preference.PercentSeekBarPreferenceCompat>

Screenshots

Native
Compat