<commit_before>SwipeActionAdapter - The Mailbox-like Swipe gesture library
===========================================================

![Maven Central](https://img.shields.io/maven-central/v/com.wdullaer/swipeactionadapter.svg)

SwipeActionAdapter is a library that provides a simple API to create Mailbox-like action when swiping in a ListView.
The idea is to make it simple enough to implement while still providing sufficient options to allow you to
integrate it with the design of your application.

Support for Android 4.0 and up. It might work on lower API versions, but I haven't tested it and I don't intend to
make any effort in that direction.

Feel free to fork or issue pull requests on github. Issues can be reported on the github issue tracker.

![Normal Swipe Gesture](https://raw.github.com/wdullaer/SwipeActionAdapter/gh-pages/images/swipe_1.png)

![Far Swipe Gesture](https://raw.github.com/wdullaer/SwipeActionAdapter/gh-pages/images/swipe_2.png)

Setup
=====
There are multiple options to add SwipeActionAdapter to your project:

* **Grade**  
Add it as a dependency to your `build.gradle`
```java
dependencies {
    compile 'com.wdullaer:swipeactionadapter:1.3.2'
}
```

* **Jar File**  
[Download the jar file](https://github.com/wdullaer/SwipeActionAdapter/releases) and add it to your project

* **Build from source**  
If you would like to get the most recent code in a jar, clone the project and run ```./gradlew jar``` from
the root folder. This will build a `swipeactionadapter.jar` in ```library/build/libs/```.

You may also add the library as an Android Library to your project. All the library files live in ```library```.

Creating your ListView with swipe actions
-----------------------------------------

If you'd rather just start with a working example, clone the project and take a look.

For a basic implementation, you'll need to

1. Wrap the Adapter of your ListView with a SwipeActionAdapter
2. Create a background layout for each swipe direction you wish to act upon.
3. Implement the SwipeActionAdapter

### Wrap the adapter of you ListView

The majority of this libraries functionality is provided through an adapter which wraps around the content ```Adapter```
of your ```ListView```. You will need to set the SwipeActionAdapter to your ListView and because<commit_msg>Fix tiny spelling mistake in README<commit_after>SwipeActionAdapter - The Mailbox-like Swipe gesture library
===========================================================

![Maven Central](https://img.shields.io/maven-central/v/com.wdullaer/swipeactionadapter.svg)

SwipeActionAdapter is a library that provides a simple API to create Mailbox-like action when swiping in a ListView.
The idea is to make it simple enough to implement while still providing sufficient options to allow you to
integrate it with the design of your application.

Support for Android 4.0 and up. It might work on lower API versions, but I haven't tested it and I don't intend to
make any effort in that direction.

Feel free to fork or issue pull requests on github. Issues can be reported on the github issue tracker.

![Normal Swipe Gesture](https://raw.github.com/wdullaer/SwipeActionAdapter/gh-pages/images/swipe_1.png)

![Far Swipe Gesture](https://raw.github.com/wdullaer/SwipeActionAdapter/gh-pages/images/swipe_2.png)

Setup
=====
There are multiple options to add SwipeActionAdapter to your project:

* **Grade**  
Add it as a dependency to your `build.gradle`
```java
dependencies {
    compile 'com.wdullaer:swipeactionadapter:1.3.2'
}
```

* **Jar File**  
[Download the jar file](https://github.com/wdullaer/SwipeActionAdapter/releases) and add it to your project

* **Build from source**  
If you would like to get the most recent code in a jar, clone the project and run ```./gradlew jar``` from
the root folder. This will build a `swipeactionadapter.jar` in ```library/build/libs/```.

You may also add the library as an Android Library to your project. All the library files live in ```library```.

Creating your ListView with swipe actions
-----------------------------------------

If you'd rather just start with a working example, clone the project and take a look.

For a basic implementation, you'll need to

1. Wrap the Adapter of your ListView with a SwipeActionAdapter
2. Create a background layout for each swipe direction you wish to act upon.
3. Implement the SwipeActionAdapter

### Wrap the adapter of your ListView

The majority of this libraries functionality is provided through an adapter which wraps around the content ```Adapter```
of your ```ListView```. You will need to set the SwipeActionAdapter to your ListView and because
{'fraction_non_alphanumeric': 0.11724286021043591, 'fraction_numerical': 0.004294610264118532, 'mean_word_length': 4.269230769230769, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 8, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7668913', 'n_tokens_mistral': 1292, 'n_tokens_neox': 1230, 'n_words': 588}