This repository has been archived by the owner on Jan 8, 2018. It is now read-only.
forked from chrisbanes/Android-PullToRefresh
-
Notifications
You must be signed in to change notification settings - Fork 82
Migration from v2.1.x to v3.0.0
Wonjun Kim edited this page Dec 2, 2013
·
2 revisions
- You should use DefaultIndicatorLayout instead of IndicatorLayout if you are already using IndicatorLayout in your project.
someIndicator = new IndicatorLayout (...);
to
someIndicator = new DefaultIndicatorLayout (...);
- Codes calling PullToRefreshBase(Context, Mode, AnimationStyle) constructor in your project, should be changed to PullToRefreshBase(Context, Mode, Class<? extends LoadingLayout>) constructor.
class SomePullToRefreshView extends PullToRefreshBase<SomeView> {
public SomePullToRefreshView(Context context, Mode mode, AnimationStyle animStyle) {
super(context, mode, animStyle);
}
...
}
...
SomePullToRefreshView view = new SomePullToRefreshView(context, Mode.PULL_FROM_START, AnimationStyle.ROTATE);
to
class SomePullToRefreshView extends PullToRefreshBase<SomeView> {
public SomePullToRefreshView(Context context, Mode mode, Class<? extends LoadingLayout> loadingLayoutClazz) {
super(context, mode, loadingLayoutClazz);
}
...
}
...
SomePullToRefreshView view = new SomePullToRefreshView(context, Mode.PULL_FROM_START, RotateLoadingLayout.class);
-
(Optional) Don’t call
PullToRefreshBase.demo()
if possible. That method is now deprecated. -
If your project contains Pull To Refresh library's source code, remove it and reference the provided library from your project. Please read Quick Start Guide for detail information .