Closed martingg88 closed 10 years ago
Create your own LoadingLayout like below. And use the loading layout on the Pull-to-refresh view. How to use your own LoadingLayout is described in a reply of issue #17.
public class OnlyImageLoadingLayout extends RotateLoadingLayout {
public OnlyImageLoadingLayout(Context context, Mode mode, Orientation scrollDirection, TypedArray attrs) {
super(context, mode, scrollDirection, attrs);
// FrameLayout containing an image will be on center.
FrameLayout imageLayout = (FrameLayout) mHeaderImage.getParent();
LayoutParams params = (FrameLayout.LayoutParams) imageLayout.getLayoutParams();
params.gravity = Gravity.CENTER | Gravity.CENTER_VERTICAL;
// LinearLayout containing text will be disappeared.
LinearLayout textLayout = (LinearLayout)mHeaderText.getParent();
textLayout.setVisibility(View.GONE);
}
}
thanks.
What is the possible way to only show image at center instead ?