I created my own adapter - implementing ListAdapter.
I checked fastScrollEnabled in the XML: android:fastScrollEnabled="true"
.
But, when the list/grid was being painted, I got a ClassCastException:
09-29 17:23:27.333: E/AndroidRuntime(25515): FATAL EXCEPTION: main
09-29 17:23:27.333: E/AndroidRuntime(25515): java.lang.ClassCastException: XAdapter cannot be cast to android.widget.BaseAdapter
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.widget.FastScroller.getSectionsFromIndexer(FastScroller.java:541)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.widget.FastScroller.getThumbPositionForListPosition(FastScroller.java:662)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.widget.FastScroller.onScroll(FastScroller.java:487)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.widget.AbsListView.invokeOnItemScrollListener(AbsListView.java:1337)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.widget.GridView.layoutChildren(GridView.java:1301)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.widget.AbsListView.onLayout(AbsListView.java:2012)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.View.layout(View.java:14289)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.ViewGroup.layout(ViewGroup.java:4559)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.widget.RelativeLayout.onLayout(RelativeLayout.java:1076)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.View.layout(View.java:14289)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.ViewGroup.layout(ViewGroup.java:4559)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1671)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1525)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.widget.LinearLayout.onLayout(LinearLayout.java:1434)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.View.layout(View.java:14289)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.ViewGroup.layout(ViewGroup.java:4559)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.widget.FrameLayout.onLayout(FrameLayout.java:448)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.View.layout(View.java:14289)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.ViewGroup.layout(ViewGroup.java:4559)
09-29 17:23:27.333: E/AndroidRuntime(25515): at com.android.internal.widget.ActionBarOverlayLayout.onLayout(ActionBarOverlayLayout.java:349)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.View.layout(View.java:14289)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.ViewGroup.layout(ViewGroup.java:4559)
09-29 17:23:27.333: E/AndroidRuntime(25515): at com.slidingmenu.lib.CustomViewAbove.onLayout(CustomViewAbove.java:470)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.View.layout(View.java:14289)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.ViewGroup.layout(ViewGroup.java:4559)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.widget.RelativeLayout.onLayout(RelativeLayout.java:1076)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.View.layout(View.java:14289)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.ViewGroup.layout(ViewGroup.java:4559)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.widget.FrameLayout.onLayout(FrameLayout.java:448)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.View.layout(View.java:14289)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.ViewGroup.layout(ViewGroup.java:4559)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.ViewRootImpl.performLayout(ViewRootImpl.java:1976)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1730)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1004)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:5481)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.Choreographer$CallbackRecord.run(Choreographer.java:749)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.Choreographer.doCallbacks(Choreographer.java:562)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.Choreographer.doFrame(Choreographer.java:532)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:735)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.os.Handler.handleCallback(Handler.java:730)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.os.Handler.dispatchMessage(Handler.java:92)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.os.Looper.loop(Looper.java:137)
09-29 17:23:27.333: E/AndroidRuntime(25515): at android.app.ActivityThread.main(ActivityThread.java:5103)
09-29 17:23:27.333: E/AndroidRuntime(25515): at java.lang.reflect.Method.invokeNative(Native Method)
09-29 17:23:27.333: E/AndroidRuntime(25515): at java.lang.reflect.Method.invoke(Method.java:525)
09-29 17:23:27.333: E/AndroidRuntime(25515): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:737)
09-29 17:23:27.333: E/AndroidRuntime(25515): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:553)
09-29 17:23:27.333: E/AndroidRuntime(25515): at dalvik.system.NativeStart.main(Native Method)
Well, it seems that Android's built in code assumes that you're using BaseAdapter if you want fast-scroll to be enabled.
Couldn't find info on the subject so thought of posting this info on SO.
The solution was to extends BaseAdapter. I didn't want to do this as I have my own listen/refresh mechanism but I couldn't find a different solution without rocking the ship too much.
Looking further into FastScroller, I don't understand why it is so much based on BaseAdapter and not ListAdapter or just Adapter.