All Projects → luckybilly → Smartswipe

luckybilly / Smartswipe

Licence: apache-2.0
An android library to make swipe more easier and more powerful. Android各种侧滑,有这一个就够了

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to Smartswipe

Cupertino Pane
🎉📱Multi-functional panes and boards for next generation progressive applications
Stars: ✭ 267 (-86.03%)
Mutual labels:  swipe, drawer
Bgaswipebacklayout Android
Android Activity 滑动返回。支持微信滑动返回样式、横屏滑动返回、全屏滑动返回
Stars: ✭ 2,251 (+17.79%)
Mutual labels:  swipeback, swipebacklayout
React Swipe Card
Tinder style swipe cards
Stars: ✭ 120 (-93.72%)
Mutual labels:  swipe
React Native Drawer Menu
A drawer component for React Native Application.
Stars: ✭ 140 (-92.67%)
Mutual labels:  drawer
Boxedverticalseekbar
A vertical seekbar for Android
Stars: ✭ 133 (-93.04%)
Mutual labels:  swipe
React Native Web Swiper
Swiper-Slider for React-Native and React-Native-Web
Stars: ✭ 125 (-93.46%)
Mutual labels:  swipe
Swipeablecards
Stars: ✭ 136 (-92.88%)
Mutual labels:  swipe
Androiduigesturerecognizer
AndroidGestureRecognizer is an Android implementation of the Apple's UIGestureRecognizer framework
Stars: ✭ 119 (-93.77%)
Mutual labels:  swipe
Materialdrawer
The flexible, easy to use, all in one drawer library for your Android project. Now brand new with material 2 design.
Stars: ✭ 11,498 (+501.67%)
Mutual labels:  drawer
Widgetlayout
自定义ViewGroup的集合(有 kotlin 实现分支):提高编写效率和 UI 绘制性能,少嵌套,易用易扩展。
Stars: ✭ 130 (-93.2%)
Mutual labels:  refreshlayout
React Native Mjrefresh
基于ios MJRefresh https://github.com/CoderMJLee/MJRefresh 开发的插件,可提供自定义的弹性刷新
Stars: ✭ 140 (-92.67%)
Mutual labels:  refreshlayout
Googlenewsstandanimation Android
Navigation pattern like in Google News Stand app with transitions
Stars: ✭ 130 (-93.2%)
Mutual labels:  swipe
Xrefreshlayout
【已过时,不再更新,请使用更强大的SmartRefreshLayout!】A refresh layout(无侵入下拉刷新和加载布局), can refresh RecyclerView for all LayoutManager, NestedScrollView。
Stars: ✭ 127 (-93.35%)
Mutual labels:  refreshlayout
Zimlx
Open Source and free launcher for Android
Stars: ✭ 137 (-92.83%)
Mutual labels:  drawer
Mp canvas drawer
🚀 微信小程序上canvas绘制图片助手,一个json就制作分享朋友圈图片
Stars: ✭ 1,611 (-15.7%)
Mutual labels:  drawer
Kf drawer
Flutter drawer (dynamic ready side menu)
Stars: ✭ 144 (-92.46%)
Mutual labels:  drawer
Swipemenulayout
🔥一个零耦合的侧滑菜单,支持RecyclerView、ListView、GridView等不同条目布局,支持菜单在左或在右,可选滑动阻塞,是否禁用等功能
Stars: ✭ 120 (-93.72%)
Mutual labels:  swipe
React Responsive Carousel
React.js Responsive Carousel (with Swipe)
Stars: ✭ 1,962 (+2.67%)
Mutual labels:  swipe
Hyperion Android
App Debugging & Inspection Tool for Android
Stars: ✭ 1,778 (-6.96%)
Mutual labels:  drawer
Swipelayout
A library what allows you to execute a swipe for the android platform
Stars: ✭ 150 (-92.15%)
Mutual labels:  swipe

SmartSwipe

library smart-swipe smart-swipe-support smart-swipe-x
latest version Download Download Download

中文文档,更详尽

A smart swipe android library helps you make View (and Activity) swipes easier.

In addition, to facilitate the use, SmartSwipe encapsulates the following tool classes:

  • SmartSwipeBack:
    All Activities slide back in an easy way via a single line code.
    without any super activity class; without translucent theme; without any code into BaseActivity; without any code into xml layout files;
  • SmartSwipeRefresh:
    With a single line code to achieve swipe refresh and load more. Compatible with vertical and horizontal
  • SwipeConsumerExclusiveGroup:
    Manages a set of exclusive SwipeConsumers, can only open one at a time.

Demo

download demo.apk

Stretch
StretchConsumer
Space
SpaceConsumer
Translucent Sliding
TranslucentSlidingConsumer
Drawer above
DrawerConsumer
Drawer behind
(factor is settable)
SlidingConsumer
Doors Open
DoorConsumer
Shutters Open
ShuttersConsumer

Create a cover

Doors open Shutters Open Drawer Open

Activity sliding back

All Activities slide back in an easy way via a single line code.

  • without any super activity class;
  • without translucent theme;
  • without any code into BaseActivity;
  • without any code into xml layout files;
Back via release velocity
StayConsumer
Translucent Sliding Back
ActivitySlidingBackConsumer
Back with bezier
BezierBackConsumer
Like doors open
ActivityDoorBackConsumer
Like shutters open
ActivityShuttersBackConsumer
Global Usage
SmartSwipeBack

Usage

First add SmartSwipe to your project

implementation 'com.billy.android:smart-swipe:latestVersion'

Nested scrolling only compatible after android api above 21(android 5.0) with core library(smart-swipe)

Add extension library to compat for android support library or androidX like below:

implementation 'com.billy.android:smart-swipe:latestVersion'
//compat for android support library
implementation 'com.billy.android:smart-swipe-support:latestVersion'

or

implementation 'com.billy.android:smart-swipe:latestVersion'
//compat for android x
implementation 'com.billy.android:smart-swipe-x:latestVersion'

SmartSwipe can be used by chain programming within a single line code. The usage of API looks like follow:

SmartSwipe.wrap(...) 		//view or Activity
	.addConsumer(...) 		//add a SwipeConsumer
	.enableDirection(...) 	//Specifies which side of the slide the SwipeConsumer will consumes
	.setXxx(...) 			//[optional] some other Settings
	.addListener(...); 		//[optional] add listener(s) to the SwipeConsumer

Sample code:

//	When view cannot scroll vertically (or scrolling to the top/bottom), 
//	if continue to drag, the UI will show elastic stretching effect, 
//	and smooth recovery after release
SmartSwipe.wrap(view)
	.addConsumer(new StretchConsumer())
	.enableVertical();

Add more than one 'SwipeConsumer' to the same View. Such as:

SmartSwipe.wrap(view)
	.addConsumer(new StretchConsumer())
	.enableVertical() 					//Stretch effect at directions: top and bottom
	.addConsumer(new SpaceConsumer())
	.enableHorizontal() 				//Space effect at directions: left and right
	;

Click here for more details about SwipeConsumers

Activity slides back with a single line of code globally

SmartSwipeBack.activityBezierBack(application, null);	//bezier shows while swiping
SmartSwipeBack.activityStayBack(application, null);		//Back via release velocity
SmartSwipeBack.activitySlidingBack(application, null);	//sliding with pre-activity relative moves
SmartSwipeBack.activityDoorBack(application, null);		//finish activity like doors open
SmartSwipeBack.activityShuttersBack(application, null);	//finish activity like shutters open

Click here For more Details

Add swipe refresh to a View via a single line code

//the second parameter within xxxMode:
// false: works vertically(swipe down to refresh and swipe up to load more)
// true: works horizontally(swipe right to refresh and swipe right to load more) 
SmartSwipeRefresh.drawerMode(view, false).setDataLoader(loader);
SmartSwipeRefresh.behindMode(view, false).setDataLoader(loader);
SmartSwipeRefresh.scaleMode(view, false).setDataLoader(loader);
SmartSwipeRefresh.translateMode(view, false).setDataLoader(loader);

You can use default headers and footers, and you can also customize your own.

The refresh extension library(smart-swipe-refresh-ext: Download) will include some fancy third-party headers and footers.

here is the first one(Based on Ifxcyr/ArrowDrawable):

refresh arrow

Click here For more Details

SmartSwipe features:

  • support for 4 directions swipe( left/top/right/bottom)
  • supports adding multiple SwipeConsumers to the same View(/Activity)
  • supports nested usage
  • support to use for list items in ListView and RecyclerView and the list itself
  • compat for NestedScroll (android support library and androidX)
  • A dozen of built-in SwipeConsumers effects

Thanks

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].