Skip to content

Latest commit

 

History

History
63 lines (36 loc) · 3.67 KB

README.md

File metadata and controls

63 lines (36 loc) · 3.67 KB

#DropViewNotification

In-app notification library to control custom notification view to display inside the layout with animated transition.

Objective

This library is made to act as a boilerplate code to allow in-app notification to display in the content area.

Overview

DropViewNotification consists of two main classes, DropViewActivity and DropViewController. DropViewActivity extends ActionBarSherlock's SherlockFragmentActivity by default to utilize Nineoldandroids library to enable Animator support on pre-ICS devices. DropViewActivity handle view wrapping for both content and view to be used as DropView.

DropViewController controls the transition for both content and the DropView if desired.

Usage

To use DropViewNotification you must do all of the following: Your Activity needs to extends DropViewActivity: public class DefaultSampleActivity extends DropViewActivity Set DropView to display on top of the screen setTopView(my_drop_view); DropView can be shown or dismissed via DropViewController getDropViewController().show(DropViewController.Position.TOP); getDropViewController().dismiss(DropViewController.Position.TOP);

Example

Default DropView showing transition. The content move down as DropView transitioning into the view.

Default showing transition effect

Default DropView dismissing transition. The content move up just after DropView transitioning out of the view. AnticipateInterpolator is added to the content to add closing effect.

Default dismissing transition effect

DropView is essentially a View object so you can put anything as long as it's a child of View.

ProgressBar as DropView

You can add your own animations as well using DropViewConfigurator and OnDropViewAction interface

Custom animation out for DropView

DropViewConfigurator Allow different animation sequence via Order method. You can choose to synchronize the animation by using Order.SYNCHRONOUS or using other options provided. Order.SEQUENTIAL_DROPVIEW_FIRST

DropView first order

Order.SEQUENTIAL_DROPVIEW_LAST

DropView last order

License

Developed By