Skip to content

To create an android widget so that it will swipe in both way . Swipe right to accept ( CONFIRM ). Swipe left to reject ( REJECT ).

License

Notifications You must be signed in to change notification settings

debmalya/BothWaySwipeButton

Repository files navigation

BothWaySwipeButton

To create an android widget so that it will swipe to mark CONFIRMATION to prevent accidental button press. Right swipe to accept ( CONFIRM ). Swipe left to reject ( REJECT ).

Behaviour

Initial Screen Right Swipe Left Swipe

How to use it.

<org.deb.widget.controller.SwipeButtonController
        android:id="@+id/sb_swipe"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_alignParentStart="true"
        android:layout_alignParentLeft="true"
        android:layout_centerVertical="true"
        android:layout_marginTop="100dp"
        android:layout_marginBottom="298dp"
        android:clickable="false"
        android:max="100"
        android:maxHeight="35dp"
        android:minHeight="35dp"
        android:progressDrawable="@android:color/transparent"
        android:splitTrack="false"
        android:thumb="@drawable/sb_thumb_bg"
        android:thumbOffset="20dp"
        app:layout_constraintBottom_toTopOf="@+id/textView"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toTopOf="parent"
        tools:ignore="UnusedAttribute"
        />

Reference

Got the idea form gratusik/AGIKSwipeButton

About

To create an android widget so that it will swipe in both way . Swipe right to accept ( CONFIRM ). Swipe left to reject ( REJECT ).

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages