Example usage for android.widget AbsListView setScrollingCacheEnabled

List of usage examples for android.widget AbsListView setScrollingCacheEnabled

Introduction

In this page you can find the example usage for android.widget AbsListView setScrollingCacheEnabled.

Prototype

public void setScrollingCacheEnabled(boolean enabled) 

Source Link

Document

Enables or disables the children's drawing cache during a scroll.

Usage

From source file:org.solovyev.android.list.ListViewScroller.java

@Override
public void onScrollStateChanged(AbsListView view, int scrollState) {
    switch (scrollState) {
    case SCROLL_STATE_FLING:
        view.setScrollingCacheEnabled(false);
        break;//ww w. j  a  v a  2s  .  c  o m
    case SCROLL_STATE_IDLE:
        view.setScrollingCacheEnabled(true);
        break;
    }
}