public PullToRefreshModule setPulledImageDelegate( PullToRefreshHelper.PulledImageDelegate pulledImageDelegate) { this.pulledImageDelegate = pulledImageDelegate; if (refreshImageView != null) refreshImageView.setPulledImageDelagate(pulledImageDelegate); return this; }
protected void onPrepareForPullToRefresh(MotionEvent event) { if (container == null) container = (ViewGroup) parent.getChildAt(0); refreshViewParent = (ViewGroup) container.findViewById(R.id.cu__ptr_parent); if (refreshViewParent != null) { refreshImageView = (PTRImageView) refreshViewParent.findViewById(R.id.cu__ptr_image); refreshImageView.setPulledImageDelagate(pulledImageDelegate); refreshLoadingViewParent = (ViewGroup) parent.findViewById(R.id.cu__ptr_loading_view_parent); refreshLoadingView = (PTRLoadingView) parent.findViewById(R.id.cu__ptr_loading_view); refreshLoadingView.setLoadingImageDelegate(loadingImageDelegate); } pullTouchStartY = event.getRawY(); }