Returns a new default Scroller that works in simple cases. In complex cases
you may try a
StepBasedScroller
with a custom
ScrollStepStrategy
:
- If the Scroller is used with InstrumentationDriver,
StaticSentinelStrategy may work and it's the simplest.
- Otherwise, DynamicSentinelStrategy should work in all cases, including
the case of dynamic list, which shows more items when scrolling beyond the
end. On the other hand, it's complex and needs more configuration.
Note if a
StepBasedScroller
is returned, it is constructed with
arguments that apply to typical cases. You may want to customize them for
specific cases. For instance,
perScrollTimeoutMillis
can be 0L if
there are no asynchronously updated views. To that extent, this method
serves as an example of how to construct
Scroller
s rather than
providing the "official"
Scroller
.