This PR does two things:
- It allows BottomAppBar to have a custom shape even when it doesn't
have a notch.
- It adds AutomaticNotchedShape, an adapter from ShapeBorder to
NotchedShape.
In certain situations, a developer may require the border of a Material to be painted behind its child. For example a Card widget that has a full width image across the top half. In that scenario, the image should ideally be painted above the border with regards to z-position.
This change exposes a flag on Material widget to achieve this behavior. Additionally, the same flag is exposed on Card widget to allow the Card widget to pass this down to its Material.
I added a couple golden tests to verify this new behavior. Goldens are here:
46a3d26acb
Previously, a disabled floating action button always had zero
elevation, which looks dumb.
This also fixes the issue whereby highlightElevation was not honoured
on floating action buttons.
This also fixes an issue I found during testing whereby setState was
being called during build when onHighlightChanged fired due to
onPressed becoming null while a gesture is ongoing (which triggers an
onTapCancel synchronously during build).
* Added the superellipse (a.k.a. squircle) shape to flutter, which is needed to recreate some cupertino components, e.g. buttons in pixel-perfect detail (issue #13914).
Should fix#22226.
Code introduced in #20890 caused a regression that broke color flooding animations in a BottomNavigationBar that has BottomNavigationBarType.shifting.
The original issue (#19653) dealt with background color changes not occurring until another tab was selected. The result is that the background color instantly changes whenever the state changes and when the widget changes, instead of allowing a new widget to animate the background color change.
And update goldens.
git log 04c860fa1dba..8cc49cac3b4a --no-merges --oneline
8cc49cac3 Ensure that the isolate shutdown callback occurs in an isolate scope. (flutter/engine#6572)
04a1ffa42 Roll src/third_party/skia cb65ce7f77c9..3a0c66da5fc2 (10 commits) (flutter/engine#6571)
35340ceaf Pass full locale list with script and variant codes to framework (flutter/engine#6557)
* Add support for shadows in text.
* Use dart:ui Shadow as base class for Shadows
* Update lerp definition
* Roll engine 3ffa3629523..84fe4a9f7e24e4 - Text Shadows and update goldens for skia roll.
git log 50c2e69daff4e207c54e463d2304139985c7511c..32f417db0d566d354605305cb29c251276fa65ee --oneline --no-merges
32f417db0 Roll tonic to 077be256142ede39a271385907faadf4fcc62a4d. (#6541)
4ee77256c Revert "Roll Dart to 1f4dfce179c8f05c9e48759300a15e671b88cc10 (#6515)" (#6537)
964acafeb Roll src/third_party/skia 646d917d3c71..c6a17104ad68 (1 commits) (#6536)
d4bae4ca4 Roll src/third_party/skia 2b2c00f6ec36..646d917d3c71 (1 commits) (#6535)
ff93ccf47 Roll src/third_party/skia 681692726fc0..2b2c00f6ec36 (1 commits) (#6534)
a4161c895 Roll src/third_party/skia 23775a2e9736..681692726fc0 (1 commits) (#6532)
116072e46 Roll src/third_party/skia 7435f2553f53..23775a2e9736 (1 commits) (#6531)
ef0b0f6e9 Roll src/third_party/skia bc7a51e79c5b..7435f2553f53 (1 commits) (#6530)
f46b7b971 Roll src/third_party/skia b28db529c866..bc7a51e79c5b (1 commits) (#6529)
9033c3902 Roll src/third_party/skia 7e67041a1428..b28db529c866 (1 commits) (#6528)
e6887a412 Add missing imports for unicode/utf16.h (#6524)
1242f6dfe Roll src/third_party/skia d38382d060ca..7e67041a1428 (2 commits) (#6527)
a1bbea77c Add a no-op platform view layer. (#6505)
2bb3afad8 Roll src/third_party/skia 21bd60daa3f3..d38382d060ca (10 commits) (#6526)
75e875240 Fix the Mac embedder build (#6525)
436f9707b Add version check for dismissable (#6522)
7767c785b Provide a default GL function resolver in the embedder (#6523)
32841dd89 Case-insensitive matching of family names for custom fonts (#6519)
a9076c7e6 Roll src/third_party/skia 419709dbb167..21bd60daa3f3 (11 commits) (#6520)
f2e7441b5 An API for loading fonts from a buffer provided by the application (#6508)
05aac0f27 fix ResourceExtractor npe. (#6461)
cf5a2a145 Roll src/third_party/skia b27a9cf2f4a8..419709dbb167 (16 commits) (#6517)
84fe4a9f7 Re-revert invalid line height tests (#6516)
5f529566c Add support for text shadows (#6385)
e44c10c96 Reland "Share engine layers with the framework" (#6412) (#6468)
ba0449971 Roll Dart to 1f4dfce179c8f05c9e48759300a15e671b88cc10 (#6515)
Goldens updated due to Skia AA changes. We previously also made a mistake by having a golden test run on MacOS.
git log 3ffa36295234..50c2e69da --no-merges --oneline
50c2e69da Roll src/third_party/skia 1b62fad4b188..b27a9cf2f4a8 (1 commits) (flutter/engine#6514)
8757bf2a1 Roll src/third_party/skia 05caa69a3f5a..1b62fad4b188 (2 commits) (flutter/engine#6513)
c2fd10ad1 Roll src/third_party/skia 2a138544646d..05caa69a3f5a (1 commits) (flutter/engine#6512)
Previously, the engine did not properly pass the AA flag on ClipRect.clipBehavior. flutter/engine#6199 fixes this and enables AA. However, default AA on clipRects has caused severe regressions in benchmark performance.
To maintain expected performance, we should now default the clipBehavior to hardEdge to disable default AA. This is consistent with any flutter projects that did not previously explicitly set the clipBehavior and should not change app appearance.
The average frame time of page transitions on Moto G4 is now very
close to 16ms (the last 10 measurements on our dashboard are
between 15.5ms to 16.7ms and half of them are below 16ms).
It is now much faster than when we disabled it (which was at about
35ms). So I think that we should be able to enable it by default.
I'll leave the flag there until we implement the retained rendering
to bring the frame time comfortably below 16ms.
See https://github.com/flutter/flutter/issues/13736
Enable taking screenshots of arbitrary RenderObjects from a running application from within the inspector.
Key functionality is in the added _ScreenshotPaintingContext class.
This fixes#20483 by letting InkWell do its own clipping.
PathOp.intersect is not used because we have too many unit tests that rely on clipping (e.g., paints..clipXXX()..drawCircle())
The goldens are updated due to small AA changes of the additional clipPath.
* Reland "Roll engine to version b148e628ec86b3a9a0382e0bcfae73f0390a8232 (#20427)"
This is a re-land with downgraded `package:flutter_gallery_assets`
version.
* Downgrade package:flutter_gallery_assets to 0.1.4
* Change engine.version to 81baff97c29bb08cbf8453a3f9042c5813f84ad3 (which contains an additional fix)
* Change engine.version to e3687f70c7ece72000b32ee1b3c02755ba5361ac (since mac tarballs are corrupted on earlier commit)
Reason for revert: The package:flutter_gallery_assets has removed some images which are required for the examples/flutter_gallery, so the gallery build is failing (only discovered after landing, since gallery doesn't seem to get built during github PR presubmit checks)
This CL
* rolls `engine.version` to flutter/engine@b148e628 (which includes dart sdk 2.1.0-dev)
* rolls `goldens.version` to flutter/goldens@6c45fafdf (which includes updates due to skia changes in engine)
* changes `platform.dill` to `platform_strong.dill` in various places due to flutter/engine@a84b210b
* adds explicit `environment: sdk: ">=2.0.0-dev.68 < 3.0.0"` constraints to `pubspec.yaml` and `pubspec.yaml.tmpl` files (since pub defaults to `<2.0.0` if omitted)
* upgrades to newer versions of various 3rd party packages (to ensure transitive dependencies have `<3.0.0` sdk constraint)
ecbb2b28d Call drawPaint instead of drawPath if there's clip (flutter/engine#5937)
597a50849 Roll src/third_party/skia cdfa16d086b8..4c3b63e289c5 (9 commits) (flutter/engine#5936)
715b64ee3 Roll src/third_party/skia 1400d38e0863..cdfa16d086b8 (10 commits) (flutter/engine#5934)
ffbafc852 Flush all embedded Android views on hot restart. (flutter/engine#5929)
9fe6a573e Roll src/third_party/skia 578ef2847b72..1400d38e0863 (7 commits) (flutter/engine#5933)
3b66f20d9 Don't drop MotionEvents with unknown tool type. (flutter/engine#5931)
391ac2f95 Roll src/third_party/skia 64cc576b1fa7..578ef2847b72 (20 commits) (flutter/engine#5930)
Goldens:
64b7a3a Add updated golden files
cb1fa8a Update golden files of PhysicalModel and PhysicalShape
3baed8d Add a goldens package for the embedded Android views integration test.
* fixed segmented control golden test
* fixed segmented control golden test
* made the comments more explanatory
* changed comment, wrapped tests with if statements so they only run on MacOS
* changed formatting
* added width and radius fields to TextField; to do: tests and Material defaults
* weak warnings
* added tests
* added default cursor width; changed default EditableText width
* only run golden file tests on linux
* changed goldens version
* actually changed goldens.version
* style changes
* small fixes
* added default material cursor color
* changed goldens.version
* changed goldens version again
* changed goldens.version again (3)
* added todo
* deleted whitespace