Java Code Examples for androidx.recyclerview.widget.RecyclerView#removeOnChildAttachStateChangeListener()

The following examples show how to use androidx.recyclerview.widget.RecyclerView#removeOnChildAttachStateChangeListener() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: EpoxyVisibilityTracker.java    From epoxy with Apache License 2.0 5 votes vote down vote up
/**
 * Detach the tracker
 *
 * @param recyclerView The recycler view that the EpoxyController has its adapter added to.
 */
public void detach(@NonNull RecyclerView recyclerView) {
  recyclerView.removeOnScrollListener(this.listener);
  recyclerView.removeOnLayoutChangeListener(this.listener);
  recyclerView.removeOnChildAttachStateChangeListener(this.listener);
  setTracker(recyclerView, null);
  attachedRecyclerView = null;
}
 
Example 2
Source File: RvItemClickSupport.java    From Aria with Apache License 2.0 4 votes vote down vote up
private void detach(RecyclerView view) {
  view.removeOnChildAttachStateChangeListener(mAttachListener);
  view.setTag(R.id.item_click_support, null);
}