Skip to content
🔥Replace typical onLongClickListener with this library!
Branch: master
Clone or download
Latest commit 343c226 May 21, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
app Renamed FromLeftToRightFillingDirection to LeftToRightFillingDirection May 14, 2019
fillingbutton Make code simpler and readable May 21, 2019
gradle/wrapper Initial commit Mar 28, 2019
.gitignore Initial commit Mar 28, 2019
LICENSE Create LICENSE Mar 29, 2019
README.md Update README.md May 21, 2019
build.gradle Added jitpack Mar 28, 2019
gradle.properties Initial commit Mar 28, 2019
gradlew Initial commit Mar 28, 2019
gradlew.bat Initial commit Mar 28, 2019
settings.gradle Initial commit Mar 28, 2019

README.md

FillingButton

Android Arsenal jitpack badge badge android platform API 16+ GitHub license

Build with love

Replace typical onLongClickListener with that library! It's the new way to handle onLongClickListener on buttons.

Sample

20190328_105032

Added new type of button InternetSensableFillingButton

20190427_124552

Added directions of filling, here is first and the third button has RightToLeftDirection:

20190516_105414

First FillingButton has TopToBottomFillingDirection and second FilligButton has BottomToTopFillingDirection

20190521_105157

Usage a simple FillingButton

 <com.github.devit951.fillingbutton.FillingButton
        android:id="@+id/fb_first"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:text="BUTTON"
        android:background="@color/colorAccent"
        app:fillColor="@color/colorPrimaryDark"
        app:fillDuration="500"/>

Usage a simple InternetSensableFillingButton

 <com.github.devit951.fillingbutton.InternetSensableFillingButton
        android:id="@+id/fb_first"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:text="BUTTON"
        android:background="@color/colorAccent"
        app:fillColor="@color/colorPrimaryDark"
        app:fillDuration="500"/>

Using FillingButton fill directions

You can change these directions in runtime.

fillingButton.direction = RightToLeftFillingDirection();
fillingButton.direction = LeftToRightFillingDirection();
fillingButton.direction = TopToBottomFillingDirection();
fillingButton.direction = BottomToTopFillingDirection();

List of xml attributes:

app:fillColor=(color) -> Changes foreground color of filling
app:fillAlpha=(integer) -> Changes alpha of foreground color filling
app:fillDuration=(integer) -> Changes fill animation duration

Setup

allprojects {
  repositories { 
    maven { url 'https://jitpack.io' } 
  }
}
  
dependencies {  
  implementation 'com.github.Devit951:FillingButton:1.2'
}
You can’t perform that action at this time.