Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…ss-Android into feature/3718-show-available-plans

# Conflicts:
#	WordPress/src/main/java/org/wordpress/android/WordPressDB.java
  • Loading branch information
daniloercoli committed Feb 11, 2016
2 parents 4a9c2a3 + f7bbc16 commit cdc50b8
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,17 @@ public interface RefreshListener {
public void onRefreshStarted();
}

public SwipeToRefreshHelper(Activity activity, CustomSwipeRefreshLayout swipeRefreshLayout, RefreshListener listener) {
init(activity, swipeRefreshLayout, listener);
public SwipeToRefreshHelper(Context context, CustomSwipeRefreshLayout swipeRefreshLayout, RefreshListener listener) {
init(context, swipeRefreshLayout, listener);
}

public void init(Activity activity, CustomSwipeRefreshLayout swipeRefreshLayout, RefreshListener listener) {
public void init(Context context, CustomSwipeRefreshLayout swipeRefreshLayout, RefreshListener listener) {
mRefreshListener = listener;
mSwipeRefreshLayout = swipeRefreshLayout;
mSwipeRefreshLayout.setOnRefreshListener(this);
final TypedArray styleAttrs = obtainStyledAttrsFromThemeAttr(activity, R.attr.swipeToRefreshStyle,
final TypedArray styleAttrs = obtainStyledAttrsFromThemeAttr(context, R.attr.swipeToRefreshStyle,
R.styleable.RefreshIndicator);
int color = styleAttrs.getColor(R.styleable.RefreshIndicator_refreshIndicatorColor, activity.getResources()
int color = styleAttrs.getColor(R.styleable.RefreshIndicator_refreshIndicatorColor, context.getResources()
.getColor(android.R.color.holo_blue_dark));
mSwipeRefreshLayout.setColorSchemeColors(color, color, color, color);
}
Expand Down

0 comments on commit cdc50b8

Please sign in to comment.