Adds itemsWrap:bool (default false) to ScrollableList and PageableList. If itemsWrap is true then scrolling past the last item wraps around to the first. Similarly, scrolling before the first item wraps around to the last.
Added abstract ExtentScrollBehavior of ScrollBehavior. Renamed fields called contentsExtents to contentExtent, containerExtents to containerExtent, contentSize to contentExtent, etc.
BoundedBehavior is now a subclass of ExtentScrollBehavior.
Added UnboundedBehavior subclass of ExtentScrollBehvaior; contentExtent and maxScrollOffset are double.INFINITY, minScrollExtent is double.NEGATIVE_INFINITY.
This lets clients listen for when a widget with a given global key goes through
a sync operation. We'll need this for mimic to track its mimicable when it
moves around the tree.
These widgets were designed in CSS where you need to specify a layout model for
your children. This patch updates them to the modern style of just taking a
unique child.
Fixes#755
- Introduce _setScrollOffset as a backend for the animations so that scrollTo
can stop animations.
- Create a single function that stops both kinds of scroll animations.
- Refactor how we update the bounds for bounded scroll behaviors so that we
update the bounds and compute the new scroll offset at the same time.
Also refactors ios_sim.py to be part of sky_tool.
The current skyx file that ‘listen’ generates does not contain material design icons, so icons will be missing.
This patch adds a new test harness and a first, trivial test to run with the
harness. The new test harness is built on package:test and should run on
Travis. Over time, we'll migrate our existing tests into this harness.
This also changes the way we insert nodes into a
MultiChildRenderObjectWrapper's renderObject, which fixes issue #626.
Now, instead of the slot being a renderObject, it's the Widget that
currently uses that renderObject. That way when the Widget changes
which renderObject to use, the siblings of that Widget in the same
child list don't have to be notified of the change.
I tested performance of the new algorithm vs the old algorithm using
the stocks demo at idle and the stocks demo scrolling steadily. The
data suggests the algorithms are roughly equivalent in performance.
Workaround for Drawer.initState() fails
This is a hack to avoid #715
In theory, the navigator's state should be updated in the event handler that triggers opening the drawer. It's not obvious how to do this, since we only build the Drawer when it's supposed to be visible (and once we're building it's too late).
When laying out positioned children inside a stack, we should give them
unbounded constraints because if they draw outside of the stack, we'll just
clip them.