https://github.com/marcoscgdev/FABScrollAnimations
[DISCONTINUED] A very simple library to animate the Support Library FAB when the user scrolls.
https://github.com/marcoscgdev/FABScrollAnimations
Last synced: about 1 year ago
JSON representation
[DISCONTINUED] A very simple library to animate the Support Library FAB when the user scrolls.
- Host: GitHub
- URL: https://github.com/marcoscgdev/FABScrollAnimations
- Owner: marcoscgdev
- License: mit
- Archived: true
- Created: 2016-03-27T15:02:40.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2018-09-21T10:07:34.000Z (almost 8 years ago)
- Last Synced: 2024-08-04T08:07:49.874Z (almost 2 years ago)
- Homepage:
- Size: 4.17 MB
- Stars: 46
- Watchers: 6
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# [DISCONTINUED] FAB Scroll Animations [](https://android-arsenal.com/api?level=14) [](http://android-arsenal.com/details/1/3367)
With this Android library, you can made this animations with your [Support Library Floating Action Button](http://developer.android.com/reference/android/support/design/widget/FloatingActionButton.html) when a NestedScrollView is beeing scrolled:
| DEFAULT | FADE | FLOAT |
|----------|:-------------:|------:|
|  |  |  |
---
## Demo:
You can download the **sample apk** [here](https://github.com/marcoscgdev/fabscrollanimations/blob/master/sample/sample.apk?raw=true).
---
## Requirements:
* The Android Support Library v7 AppCompat.
* The Android Support Design Library Floating Action Button.
* A CoordinatorLayout as the master layout.
* A NestedScrollView based scrolling content (Ex: RecyclerView).
---
## Usage:
#### Step: 1
Include the [fabscrollanimations.jar](https://github.com/marcoscgdev/FABScrollAnimations/blob/master/library/fabscrollanimations.jar?raw=true) file to your _libs_ folder.
#### Step: 2
Ensure that your layout starts with a _CoordinatorLayout_.
#### Step: 3
This library only works with _NestedScrollView based content_.
####Step: 4
An example layout structure can be:
```xml
```
You have to emphasize the last line of code of the FloatingActionButton.
```xml
app:layout_behavior="com.marcoscg.fabscrollanimations.Fade"
```
It tells to the FAB the animation that it have to do when user scrolls the content.
---
There are currently three animations:
* **DEFAULT:**
Use this layout_behavior:
```xml
app:layout_behavior="com.marcoscg.fabscrollanimations.Default"
```
* **FADE:**
Use this layout_behavior:
```xml
app:layout_behavior="com.marcoscg.fabscrollanimations.Fade"
```
* **FLOAT:**
Use this layout_behavior:
```xml
app:layout_behavior="com.marcoscg.fabscrollanimations.Float"
```
---
>See the [sample project](https://github.com/marcoscgdev/FABScrollAnimations/tree/master/sample) to clarify any queries you may have.