![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
com.marshalchen:ultimaterecyclerview.library
Advanced tools
A RecyclerView(advanced and flexible version of ListView) with refreshing,loading more,animation and many other features.
###Version:0.3.0
###Description
UltimateRecyclerView is a RecyclerView(advanced and flexible version of ListView) with pulling to refresh, loading more, swiping to dismiss, draging and drop, animations ,show or hide toolbar and FAB when scrolling and many other features.You can use it just like RecyclerView
.
Notice that UltimateRecyclerView is a project under development.
###Features:
###Changes in 0.3.0:
swipe to refresh
###Upcoming features:
Upcoming changes in UltiamteRecyclerview 0.4.0:
If you have some good idea, please tell us.My email is cymcsg # gmail.com.And it is a good idea to put your idea on the issue.
####Welcome to fork and pull request.
###If you want to use a rapid development framework for developing apps,you can try UltimateAndroid Framework.
###Screenshot
###Sample
You can clone the project and compile it yourself (it includes a sample), or you can check it out already compiled at Google Play
Notice that it might not be the latest version
###Quick Setup(Basic Usage) ######1.Integration
repositories {
jcenter()
}
dependencies {
...
compile 'com.marshalchen.ultimaterecyclerview:library:0.3.0'
}
#####2.Usage:
<com.marshalchen.ultimaterecyclerview.UltimateRecyclerView
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:id="@+id/ultimate_recycler_view"
app:recyclerviewClipToPadding="true"
app:recyclerviewPadding="2dp">
</com.marshalchen.ultimaterecyclerview.UltimateRecyclerView>
#####3.Features:
Loading more:
ultimateRecyclerView.enableLoadmore();
Set ParallaxHeader:
ultimateRecyclerView.setParallaxHeader(getLayoutInflater().inflate(R.layout.parallax_recyclerview_header, ultimateRecyclerView.mRecyclerView, false));
ultimateRecyclerView.setOnParallaxScroll(new UltimateRecyclerView.OnParallaxScroll() {
@Override
public void onParallaxScroll(float percentage, float offset, View parallax) {
Drawable c = toolbar.getBackground();
c.setAlpha(Math.round(127 + percentage * 128));
toolbar.setBackgroundDrawable(c);
}
});
Set swipe to refresh:
ultimateRecyclerView.setOnRefreshListener(new SwipeRefreshLayout.OnRefreshListener() {
@Override
public void onRefresh() {
new Handler().postDelayed(new Runnable() {
@Override
public void run() {
simpleRecyclerViewAdapter.insert("Refresh things", 0);
ultimateRecyclerView.setRefreshing(false);
// ultimateRecyclerView.scrollBy(0, -50);
linearLayoutManager.scrollToPosition(0);
}
}, 1000);
}
});
Set swipe to dismiss:
ultimateRecyclerView.setSwipeToDismissCallback(new SwipeToDismissTouchListener.DismissCallbacks() {
@Override
public SwipeToDismissTouchListener.SwipeDirection dismissDirection(int position) {
return SwipeToDismissTouchListener.SwipeDirection.BOTH;
}
@Override
public void onDismiss(RecyclerView view, List<SwipeToDismissTouchListener.PendingDismissData> dismissData) {
for (SwipeToDismissTouchListener.PendingDismissData data : dismissData) {
simpleRecyclerViewAdapter.remove(data.position);
}
}
@Override
public void onResetMotion() {
isDrag = true;
}
@Override
public void onTouchDown() {
isDrag = false;
}
});
Drag and drop:
dragDropTouchListener = new DragDropTouchListener(ultimateRecyclerView.mRecyclerView, this) {
@Override
protected void onItemSwitch(RecyclerView recyclerView, int from, int to) {
simpleRecyclerViewAdapter.swapPositions(from, to);
simpleRecyclerViewAdapter.clearSelection(from);
simpleRecyclerViewAdapter.notifyItemChanged(to);
if (actionMode != null) actionMode.finish();
Logs.d("switch----");
}
@Override
protected void onItemDrop(RecyclerView recyclerView, int position) {
Logs.d("drop----");
ultimateRecyclerView.enableSwipeRefresh(true);
}
};
dragDropTouchListener.setCustomDragHighlight(getResources().getDrawable(R.drawable.custom_drag_frame));
ultimateRecyclerView.mRecyclerView.addOnItemTouchListener(dragDropTouchListener);
Animations:
ultimateRecyclerView.setItemAnimator(Type.values()[position].getAnimator());
ultimateRecyclerView.getItemAnimator().setAddDuration(300);
ultimateRecyclerView.getItemAnimator().setRemoveDuration(300);
Showing and hiding toolbar and floating button:
ultimateRecyclerView.setScrollViewCallbacks(new ObservableScrollViewCallbacks() {
@Override
public void onScrollChanged(int scrollY, boolean firstScroll, boolean dragging) {
}
@Override
public void onDownMotionEvent() {
}
@Override
public void onUpOrCancelMotionEvent(ObservableScrollState observableScrollState) {
if (observableScrollState == ObservableScrollState.DOWN) {
ultimateRecyclerView.showToolbar(toolbar, ultimateRecyclerView,getScreenHeight());
} else if (observableScrollState == ObservableScrollState.UP) {
ultimateRecyclerView.hideToolbar(toolbar,ultimateRecyclerView,getScreenHeight());
} else if (observableScrollState == ObservableScrollState.STOP) {
}
}
});
Show empty view when the adapter is null:
<com.marshalchen.ultimaterecyclerview.UltimateRecyclerView
...
app:recyclerviewEmptyView="@layout/empty_view"/>
Show custom FloatingView(Both menu and button are fine. It is easy to set click event on them) when the adapter is null:
<com.marshalchen.ultimaterecyclerview.UltimateRecyclerView
...
app:recyclerviewFloatingActionView="@layout/floating_view"/>
Set custom colorful style of pull to refresh:
<com.marshalchen.ultimaterecyclerview.CustomUltimateRecyclerview
.../>
Using CustomUltimateRecyclerview instead of UltimateRecyclerView
ultimateRecyclerView.setCustomSwipeToRefresh();
Set scrollbars of RecyclerView by set attributes of UltimateRecyclerView in xml layout:
<com.marshalchen.ultimaterecyclerview.UltimateRecyclerView
app:recyclerviewScrollbars="vertical" />
Note that set scrollbars of RecyclerView dynamically by code is NOT SUPPORTED refer to this
####If you want to see more details,you can check the demo.
###Thanks
If there are someone who I do not mention here,please accept my sincerely appologies and tell me.
Copyright 2015 Marshal Chen
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
FAQs
A RecyclerView(advanced and flexible version of ListView) with refreshing,loading more,animation and many other features.
We found that com.marshalchen:ultimaterecyclerview.library demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.