From 999938d955cbee443cf310fc6441ef6f56319d9d Mon Sep 17 00:00:00 2001 From: Hans Muller Date: Tue, 30 Jun 2015 17:08:14 -0700 Subject: [PATCH] Add a TabNavigator to the Stocks demo Changed FixedHeightScrollable so that if the list shrinks past the current scrollOffset, the scrollOffset is adjusted so that the last/only page of the list remains visible. R=abarth@chromium.org Review URL: https://codereview.chromium.org/1216323002. --- .../tests/examples/stocks-expected.txt | 76 ++++++++++++++----- 1 file changed, 58 insertions(+), 18 deletions(-) diff --git a/engine/src/flutter/tests/examples/stocks-expected.txt b/engine/src/flutter/tests/examples/stocks-expected.txt index fafea500fe1..52d64de6b1c 100644 --- a/engine/src/flutter/tests/examples/stocks-expected.txt +++ b/engine/src/flutter/tests/examples/stocks-expected.txt @@ -10,16 +10,36 @@ PAINT FOR FRAME #2 ---------------------------------------------- 2 | | TestPaintingCanvas() constructor: 800.0 x 600.0 2 | | paintChild RenderScaffold at Point(0.0, 0.0) 2 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | paintChild RenderDecoratedBox at Point(0.0, 81.0) +2 | | | paintChild RenderFlex at Point(0.0, 81.0) 2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -2 | | | | drawRect(Rect.fromLTRB(0.0, 81.0, 800.0, 600.0), Paint(color:Color(0xfffafafa))) -2 | | | | save -2 | | | | clipRect(Rect.fromLTRB(0.0, 81.0, 800.0, 600.0)) -2 | | | | save -2 | | | | translate(0.0, 81.0) -2 | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) -2 | | | | restore -2 | | | | restore +2 | | | | paintChild RenderTabBar at Point(0.0, 81.0) +2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 +2 | | | | | drawRect(Rect.fromLTRB(0.0, 81.0, 800.0, 129.0), Paint(color:Color(0xff9c27b0))) +2 | | | | | paintChild RenderInkWell at Point(0.0, 81.0) +2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 +2 | | | | | | paintChild RenderOpacity at Point(174.5, 97.0) +2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 +2 | | | | | | | translate(174.5, 97.0) +2 | | | | | | | translate(-174.5, -97.0) +2 | | | | | drawRect(Rect.fromLTRB(0.0, 127.0, 400.0, 129.0), Paint(color:Color(0xffff5252))) +2 | | | | | paintChild RenderInkWell at Point(400.0, 81.0) +2 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 +2 | | | | | | paintChild RenderOpacity at Point(562.0, 97.0) +2 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 +2 | | | | | | | saveLayer(null, Paint(color:Color(0xb3000000))) +2 | | | | | | | translate(562.0, 97.0) +2 | | | | | | | translate(-562.0, -97.0) +2 | | | | | | | restore +2 | | | | paintChild RenderDecoratedBox at Point(0.0, 129.0) +2 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 +2 | | | | | drawRect(Rect.fromLTRB(0.0, 129.0, 800.0, 600.0), Paint(color:Color(0xfffafafa))) +2 | | | | | save +2 | | | | | clipRect(Rect.fromLTRB(0.0, 129.0, 800.0, 600.0)) +2 | | | | | save +2 | | | | | translate(0.0, 129.0) +2 | | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) +2 | | | | | restore +2 | | | | | restore 2 | | | paintChild RenderDecoratedBox at Point(0.0, 0.0) 2 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 2 | | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 81.0), Paint(color:Color(0xff9c27b0), drawLooper:true)) @@ -61,16 +81,36 @@ PAINT FOR FRAME #3 ---------------------------------------------- 3 | | TestPaintingCanvas() constructor: 800.0 x 600.0 3 | | paintChild RenderScaffold at Point(0.0, 0.0) 3 | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | paintChild RenderDecoratedBox at Point(0.0, 81.0) +3 | | | paintChild RenderFlex at Point(0.0, 81.0) 3 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 -3 | | | | drawRect(Rect.fromLTRB(0.0, 81.0, 800.0, 600.0), Paint(color:Color(0xfffafafa))) -3 | | | | save -3 | | | | clipRect(Rect.fromLTRB(0.0, 81.0, 800.0, 600.0)) -3 | | | | save -3 | | | | translate(0.0, 81.0) -3 | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) -3 | | | | restore -3 | | | | restore +3 | | | | paintChild RenderTabBar at Point(0.0, 81.0) +3 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 +3 | | | | | drawRect(Rect.fromLTRB(0.0, 81.0, 800.0, 129.0), Paint(color:Color(0xff9c27b0))) +3 | | | | | paintChild RenderInkWell at Point(0.0, 81.0) +3 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 +3 | | | | | | paintChild RenderOpacity at Point(174.5, 97.0) +3 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 +3 | | | | | | | translate(174.5, 97.0) +3 | | | | | | | translate(-174.5, -97.0) +3 | | | | | drawRect(Rect.fromLTRB(0.0, 127.0, 400.0, 129.0), Paint(color:Color(0xffff5252))) +3 | | | | | paintChild RenderInkWell at Point(400.0, 81.0) +3 | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 +3 | | | | | | paintChild RenderOpacity at Point(562.0, 97.0) +3 | | | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 +3 | | | | | | | saveLayer(null, Paint(color:Color(0xb3000000))) +3 | | | | | | | translate(562.0, 97.0) +3 | | | | | | | translate(-562.0, -97.0) +3 | | | | | | | restore +3 | | | | paintChild RenderDecoratedBox at Point(0.0, 129.0) +3 | | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 +3 | | | | | drawRect(Rect.fromLTRB(0.0, 129.0, 800.0, 600.0), Paint(color:Color(0xfffafafa))) +3 | | | | | save +3 | | | | | clipRect(Rect.fromLTRB(0.0, 129.0, 800.0, 600.0)) +3 | | | | | save +3 | | | | | translate(0.0, 129.0) +3 | | | | | concat([1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0]) +3 | | | | | restore +3 | | | | | restore 3 | | | paintChild RenderDecoratedBox at Point(0.0, 0.0) 3 | | | | TestPaintingCanvas() constructor: 800.0 x 600.0 3 | | | | drawRect(Rect.fromLTRB(0.0, 0.0, 800.0, 81.0), Paint(color:Color(0xff9c27b0), drawLooper:true))