diff --git a/ci/analyze.sh b/ci/analyze.sh index 7c5cc39194c0b..85c2c2387144d 100755 --- a/ci/analyze.sh +++ b/ci/analyze.sh @@ -95,5 +95,6 @@ analyze \ "$FLUTTER_DIR/testing/scenario_app" # Check that dart libraries conform. +echo "Checking web_ui api conformance..." (cd "$FLUTTER_DIR/web_sdk"; pub get) (cd "$FLUTTER_DIR"; dart "web_sdk/test/api_conform_test.dart") diff --git a/lib/web_ui/lib/src/engine.dart b/lib/web_ui/lib/src/engine.dart index 3fb4c44490e31..e9684afea6bc9 100644 --- a/lib/web_ui/lib/src/engine.dart +++ b/lib/web_ui/lib/src/engine.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 @JS() library engine; diff --git a/lib/web_ui/lib/src/engine/alarm_clock.dart b/lib/web_ui/lib/src/engine/alarm_clock.dart index 8308d725d2e06..1a9c384f2c898 100644 --- a/lib/web_ui/lib/src/engine/alarm_clock.dart +++ b/lib/web_ui/lib/src/engine/alarm_clock.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A function that returns current system time. diff --git a/lib/web_ui/lib/src/engine/assets.dart b/lib/web_ui/lib/src/engine/assets.dart index 326ab952c9b96..61c056f3f6763 100644 --- a/lib/web_ui/lib/src/engine/assets.dart +++ b/lib/web_ui/lib/src/engine/assets.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// This class downloads assets over the network. diff --git a/lib/web_ui/lib/src/engine/bitmap_canvas.dart b/lib/web_ui/lib/src/engine/bitmap_canvas.dart index a343a7bef593c..3575d1491bbc1 100644 --- a/lib/web_ui/lib/src/engine/bitmap_canvas.dart +++ b/lib/web_ui/lib/src/engine/bitmap_canvas.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A raw HTML canvas that is directly written to. diff --git a/lib/web_ui/lib/src/engine/browser_detection.dart b/lib/web_ui/lib/src/engine/browser_detection.dart index 1ada5e37ed512..88eed23c4110a 100644 --- a/lib/web_ui/lib/src/engine/browser_detection.dart +++ b/lib/web_ui/lib/src/engine/browser_detection.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// The HTML engine used by the current browser. @@ -27,6 +27,14 @@ enum BrowserEngine { unknown, } +/// html webgl version qualifier constants. +abstract class WebGLVersion { + // WebGL 1.0 is based on OpenGL ES 2.0 / GLSL 1.00 + static const int webgl1 = 1; + // WebGL 2.0 is based on OpenGL ES 3.0 / GLSL 3.00 + static const int webgl2 = 2; +} + /// Lazily initialized current browser engine. late final BrowserEngine _browserEngine = _detectBrowserEngine(); @@ -181,10 +189,10 @@ int _detectWebGLVersion() { height: 1, ); if (canvas.getContext('webgl2') != null) { - return 2; + return WebGLVersion.webgl2; } if (canvas.getContext('webgl') != null) { - return 1; + return WebGLVersion.webgl1; } return -1; } diff --git a/lib/web_ui/lib/src/engine/canvas_pool.dart b/lib/web_ui/lib/src/engine/canvas_pool.dart index efe49dfe48925..a20a39cd92207 100644 --- a/lib/web_ui/lib/src/engine/canvas_pool.dart +++ b/lib/web_ui/lib/src/engine/canvas_pool.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Allocates and caches 0 or more canvas(s) for [BitmapCanvas]. @@ -515,19 +515,28 @@ class _CanvasPool extends _SaveStackTracking { void strokeLine(ui.Offset p1, ui.Offset p2) { html.CanvasRenderingContext2D ctx = context; ctx.beginPath(); - ctx.moveTo(p1.dx, p1.dy); - ctx.lineTo(p2.dx, p2.dy); + final ui.Rect? shaderBounds = contextHandle._shaderBounds; + if (shaderBounds == null) { + ctx.moveTo(p1.dx, p1.dy); + ctx.lineTo(p2.dx, p2.dy); + } else { + ctx.moveTo(p1.dx - shaderBounds.left, p1.dy - shaderBounds.top); + ctx.lineTo(p2.dx - shaderBounds.left, p2.dy - shaderBounds.top); + } ctx.stroke(); } void drawPoints(ui.PointMode pointMode, Float32List points, double radius) { html.CanvasRenderingContext2D ctx = context; final int len = points.length; + final ui.Rect? shaderBounds = contextHandle._shaderBounds; + double offsetX = shaderBounds == null ? 0 : -shaderBounds.left; + double offsetY = shaderBounds == null ? 0 : -shaderBounds.top; switch (pointMode) { case ui.PointMode.points: for (int i = 0; i < len; i += 2) { - final double x = points[i]; - final double y = points[i + 1]; + final double x = points[i] + offsetX; + final double y = points[i + 1] + offsetY; ctx.beginPath(); ctx.arc(x, y, radius, 0, 2.0 * math.pi); ctx.fill(); @@ -536,16 +545,16 @@ class _CanvasPool extends _SaveStackTracking { case ui.PointMode.lines: ctx.beginPath(); for (int i = 0; i < (len - 2); i += 4) { - ctx.moveTo(points[i], points[i + 1]); - ctx.lineTo(points[i + 2], points[i + 3]); + ctx.moveTo(points[i] + offsetX, points[i + 1] + offsetY); + ctx.lineTo(points[i + 2] + offsetX, points[i + 3] + offsetY); ctx.stroke(); } break; case ui.PointMode.polygon: ctx.beginPath(); - ctx.moveTo(points[0], points[1]); + ctx.moveTo(points[0] + offsetX, points[1] + offsetY); for (int i = 2; i < len; i += 2) { - ctx.lineTo(points[i], points[i + 1]); + ctx.lineTo(points[i] + offsetX, points[i + 1] + offsetY); } ctx.stroke(); break; @@ -597,39 +606,117 @@ class _CanvasPool extends _SaveStackTracking { } } + /// Applies path to drawing context, preparing for fill and other operations. + /// + /// WARNING: Don't refactor _runPath/_runPathWithOffset. Latency sensitive + void _runPathWithOffset(html.CanvasRenderingContext2D ctx, SurfacePath path, + double offsetX, double offsetY) { + ctx.beginPath(); + final Float32List p = _runBuffer; + final PathRefIterator iter = PathRefIterator(path.pathRef); + int verb = 0; + while ((verb = iter.next(p)) != SPath.kDoneVerb) { + switch (verb) { + case SPath.kMoveVerb: + ctx.moveTo(p[0] + offsetX, p[1] + offsetY); + break; + case SPath.kLineVerb: + ctx.lineTo(p[2] + offsetX, p[3] + offsetY); + break; + case SPath.kCubicVerb: + ctx.bezierCurveTo(p[2] + offsetX, p[3] + offsetY, + p[4] + offsetX, p[5] + offsetY, p[6] + offsetX, p[7] + offsetY); + break; + case SPath.kQuadVerb: + ctx.quadraticCurveTo(p[2] + offsetX, p[3] + offsetY, + p[4] + offsetX, p[5] + offsetY); + break; + case SPath.kConicVerb: + final double w = iter.conicWeight; + Conic conic = Conic(p[0], p[1], p[2], p[3], p[4], p[5], w); + List points = conic.toQuads(); + final int len = points.length; + for (int i = 1; i < len; i += 2) { + final double p1x = points[i].dx; + final double p1y = points[i].dy; + final double p2x = points[i + 1].dx; + final double p2y = points[i + 1].dy; + ctx.quadraticCurveTo(p1x + offsetX, p1y + offsetY, + p2x + offsetX, p2y + offsetY); + } + break; + case SPath.kCloseVerb: + ctx.closePath(); + break; + default: + throw UnimplementedError('Unknown path verb $verb'); + } + } + } + void drawRect(ui.Rect rect, ui.PaintingStyle? style) { context.beginPath(); - context.rect(rect.left, rect.top, rect.width, rect.height); + final ui.Rect? shaderBounds = contextHandle._shaderBounds; + if (shaderBounds == null) { + context.rect(rect.left, rect.top, rect.width, rect.height); + } else { + context.rect(rect.left - shaderBounds.left, rect.top - shaderBounds.top, + rect.width, rect.height); + } contextHandle.paint(style); } void drawRRect(ui.RRect roundRect, ui.PaintingStyle? style) { - _RRectToCanvasRenderer(context).render(roundRect); + final ui.Rect? shaderBounds = contextHandle._shaderBounds; + _RRectToCanvasRenderer(context).render( + shaderBounds == null ? roundRect + : roundRect.shift(ui.Offset(-shaderBounds.left, -shaderBounds.top))); contextHandle.paint(style); } void drawDRRect(ui.RRect outer, ui.RRect inner, ui.PaintingStyle? style) { _RRectRenderer renderer = _RRectToCanvasRenderer(context); - renderer.render(outer); - renderer.render(inner, startNewPath: false, reverse: true); + final ui.Rect? shaderBounds = contextHandle._shaderBounds; + if (shaderBounds == null) { + renderer.render(outer); + renderer.render(inner, startNewPath: false, reverse: true); + } else { + final ui.Offset shift = ui.Offset(-shaderBounds.left, -shaderBounds.top); + renderer.render(outer.shift(shift)); + renderer.render(inner.shift(shift), startNewPath: false, reverse: true); + } contextHandle.paint(style); } void drawOval(ui.Rect rect, ui.PaintingStyle? style) { context.beginPath(); - DomRenderer.ellipse(context, rect.center.dx, rect.center.dy, rect.width / 2, + ui.Rect? shaderBounds = contextHandle._shaderBounds; + final double cx = shaderBounds == null ? rect.center.dx : + rect.center.dx - shaderBounds.left; + final double cy = shaderBounds == null ? rect.center.dy : + rect.center.dy - shaderBounds.top; + DomRenderer.ellipse(context, cx, cy, rect.width / 2, rect.height / 2, 0, 0, 2.0 * math.pi, false); contextHandle.paint(style); } void drawCircle(ui.Offset c, double radius, ui.PaintingStyle? style) { context.beginPath(); - DomRenderer.ellipse(context, c.dx, c.dy, radius, radius, 0, 0, 2.0 * math.pi, false); + final ui.Rect? shaderBounds = contextHandle._shaderBounds; + final double cx = shaderBounds == null ? c.dx : c.dx - shaderBounds.left; + final double cy = shaderBounds == null ? c.dy : c.dy - shaderBounds.top; + DomRenderer.ellipse(context, cx, cy, radius, radius, 0, 0, 2.0 * math.pi, false); contextHandle.paint(style); } void drawPath(ui.Path path, ui.PaintingStyle? style) { - _runPath(context, path as SurfacePath); + final ui.Rect? shaderBounds = contextHandle._shaderBounds; + if (shaderBounds == null) { + _runPath(context, path as SurfacePath); + } else { + _runPathWithOffset(context, path as SurfacePath, + -shaderBounds.left, -shaderBounds.top); + } contextHandle.paintPath(style, path.fillType); } @@ -789,6 +876,14 @@ class ContextStateHandle { ui.MaskFilter? _currentFilter; SurfacePaintData? _lastUsedPaint; + /// Currently active shader bounds. + /// + /// When a paint style uses a shader that produces a pattern, the pattern + /// origin is relative to current transform. Therefore any painting operations + /// will have to reverse the transform to correctly align pattern with + /// drawing bounds. + ui.Rect? _shaderBounds; + /// The painting state. /// /// Used to validate that the [setUpPaint] and [tearDownPaint] are called in @@ -824,6 +919,9 @@ class ContextStateHandle { density); fillStyle = paintStyle; strokeStyle = paintStyle; + _shaderBounds = shaderBounds; + // Align pattern origin to destination. + context.translate(shaderBounds!.left, shaderBounds.top); } else if (paint.color != null) { final String? colorString = colorToCssString(paint.color); fillStyle = colorString; @@ -906,6 +1004,10 @@ class ContextStateHandle { // shadow attributes. context.restore(); } + if (_shaderBounds != null) { + context.translate(-_shaderBounds!.left, -_shaderBounds!.top); + _shaderBounds = null; + } } void paint(ui.PaintingStyle? style) { @@ -948,6 +1050,7 @@ class ContextStateHandle { _currentStrokeCap = ui.StrokeCap.butt; context.lineJoin = 'miter'; _currentStrokeJoin = ui.StrokeJoin.miter; + _shaderBounds = null; } } diff --git a/lib/web_ui/lib/src/engine/canvaskit/canvas.dart b/lib/web_ui/lib/src/engine/canvaskit/canvas.dart index 61ceb231e811b..5703e6105e8c9 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/canvas.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/canvas.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A Dart wrapper around Skia's [SkCanvas]. diff --git a/lib/web_ui/lib/src/engine/canvaskit/canvaskit_api.dart b/lib/web_ui/lib/src/engine/canvaskit/canvaskit_api.dart index 40ee255c71a1f..ed0de4261304b 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/canvaskit_api.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/canvaskit_api.dart @@ -7,7 +7,7 @@ /// Prefer keeping the original CanvasKit names so it is easier to locate /// the API behind these bindings in the Skia source code. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Entrypoint into the CanvasKit API. diff --git a/lib/web_ui/lib/src/engine/canvaskit/canvaskit_canvas.dart b/lib/web_ui/lib/src/engine/canvaskit/canvaskit_canvas.dart index 26f534c386c7f..31a5e5f366a3e 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/canvaskit_canvas.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/canvaskit_canvas.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// An implementation of [ui.Canvas] that is backed by a CanvasKit canvas. diff --git a/lib/web_ui/lib/src/engine/canvaskit/color_filter.dart b/lib/web_ui/lib/src/engine/canvaskit/color_filter.dart index 86bb58cbcde98..5495ed2bc4c49 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/color_filter.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/color_filter.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A concrete [ManagedSkiaObject] subclass that owns a [SkColorFilter] and diff --git a/lib/web_ui/lib/src/engine/canvaskit/embedded_views.dart b/lib/web_ui/lib/src/engine/canvaskit/embedded_views.dart index d8d424fe8cd6b..92351db5e62a1 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/embedded_views.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/embedded_views.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// This composites HTML views into the [ui.Scene]. diff --git a/lib/web_ui/lib/src/engine/canvaskit/fonts.dart b/lib/web_ui/lib/src/engine/canvaskit/fonts.dart index e8812a3b94e58..4f8fd3bba9d65 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/fonts.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/fonts.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; // This URL was found by using the Google Fonts Developer API to find the URL diff --git a/lib/web_ui/lib/src/engine/canvaskit/image.dart b/lib/web_ui/lib/src/engine/canvaskit/image.dart index 0f1f2d98ff055..77c1444b3b28e 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/image.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/image.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Instantiates a [ui.Codec] backed by an `SkAnimatedImage` from Skia. diff --git a/lib/web_ui/lib/src/engine/canvaskit/image_filter.dart b/lib/web_ui/lib/src/engine/canvaskit/image_filter.dart index 5562e84c65f69..941c1a6ef3892 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/image_filter.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/image_filter.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// An [ImageFilter] that can create a managed skia [SkImageFilter] object. diff --git a/lib/web_ui/lib/src/engine/canvaskit/initialization.dart b/lib/web_ui/lib/src/engine/canvaskit/initialization.dart index 131eef0bcea67..ffe3fc08ff734 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/initialization.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/initialization.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A JavaScript entrypoint that allows developer to set rendering backend diff --git a/lib/web_ui/lib/src/engine/canvaskit/layer.dart b/lib/web_ui/lib/src/engine/canvaskit/layer.dart index eb885ef9b5f3e..4f2e0547c4ee4 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/layer.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/layer.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A layer to be composed into a scene. diff --git a/lib/web_ui/lib/src/engine/canvaskit/layer_scene_builder.dart b/lib/web_ui/lib/src/engine/canvaskit/layer_scene_builder.dart index 71e634ed41b94..1bf67b6b9a957 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/layer_scene_builder.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/layer_scene_builder.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class LayerScene implements ui.Scene { diff --git a/lib/web_ui/lib/src/engine/canvaskit/layer_tree.dart b/lib/web_ui/lib/src/engine/canvaskit/layer_tree.dart index 3b40be4728b39..47173a65b22fe 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/layer_tree.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/layer_tree.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A tree of [Layer]s that, together with a [Size] compose a frame. diff --git a/lib/web_ui/lib/src/engine/canvaskit/mask_filter.dart b/lib/web_ui/lib/src/engine/canvaskit/mask_filter.dart index 8c120d1520035..e51771983ca3d 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/mask_filter.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/mask_filter.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// The CanvasKit implementation of [ui.MaskFilter]. diff --git a/lib/web_ui/lib/src/engine/canvaskit/n_way_canvas.dart b/lib/web_ui/lib/src/engine/canvaskit/n_way_canvas.dart index bc736dd8a6f6c..3e1bf0f551306 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/n_way_canvas.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/n_way_canvas.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A virtual canvas that applies operations to multiple canvases at once. diff --git a/lib/web_ui/lib/src/engine/canvaskit/painting.dart b/lib/web_ui/lib/src/engine/canvaskit/painting.dart index 69ab374db06b5..4db4cd6e13269 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/painting.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/painting.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// The implementation of [ui.Paint] used by the CanvasKit backend. diff --git a/lib/web_ui/lib/src/engine/canvaskit/path.dart b/lib/web_ui/lib/src/engine/canvaskit/path.dart index caf1d86387869..12626d5ec354e 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/path.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/path.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// An implementation of [ui.Path] which is backed by an `SkPath`. diff --git a/lib/web_ui/lib/src/engine/canvaskit/path_metrics.dart b/lib/web_ui/lib/src/engine/canvaskit/path_metrics.dart index 8dab50a3ba6ba..f220a37bc6ee6 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/path_metrics.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/path_metrics.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class CkPathMetrics extends IterableBase diff --git a/lib/web_ui/lib/src/engine/canvaskit/picture.dart b/lib/web_ui/lib/src/engine/canvaskit/picture.dart index 2a0d292ebd45b..2a1cc0b8a4a01 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/picture.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/picture.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class CkPicture implements ui.Picture { diff --git a/lib/web_ui/lib/src/engine/canvaskit/picture_recorder.dart b/lib/web_ui/lib/src/engine/canvaskit/picture_recorder.dart index 126ffd97648de..9069008142734 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/picture_recorder.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/picture_recorder.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class CkPictureRecorder implements ui.PictureRecorder { diff --git a/lib/web_ui/lib/src/engine/canvaskit/platform_message.dart b/lib/web_ui/lib/src/engine/canvaskit/platform_message.dart index 543b2d56bcc28..37b71fc714cdd 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/platform_message.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/platform_message.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class PlatformMessage { diff --git a/lib/web_ui/lib/src/engine/canvaskit/raster_cache.dart b/lib/web_ui/lib/src/engine/canvaskit/raster_cache.dart index 85ebf7c49ec7d..9a49e08a019dc 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/raster_cache.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/raster_cache.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A cache of [Picture]s that have already been rasterized. diff --git a/lib/web_ui/lib/src/engine/canvaskit/rasterizer.dart b/lib/web_ui/lib/src/engine/canvaskit/rasterizer.dart index 76b9e69e53afe..86e7052fbac2d 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/rasterizer.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/rasterizer.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A class that can rasterize [LayerTree]s into a given [Surface]. diff --git a/lib/web_ui/lib/src/engine/canvaskit/shader.dart b/lib/web_ui/lib/src/engine/canvaskit/shader.dart index ea251bfd7b5e4..66a6e43bef5b4 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/shader.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/shader.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; abstract class CkShader extends ManagedSkiaObject implements ui.Shader { diff --git a/lib/web_ui/lib/src/engine/canvaskit/skia_object_cache.dart b/lib/web_ui/lib/src/engine/canvaskit/skia_object_cache.dart index 15bfe68101bc5..3ce432d20592e 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/skia_object_cache.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/skia_object_cache.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A cache of Skia objects whose memory Flutter manages. diff --git a/lib/web_ui/lib/src/engine/canvaskit/surface.dart b/lib/web_ui/lib/src/engine/canvaskit/surface.dart index 17aac05770ecd..e537f4fcf0f40 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/surface.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/surface.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; typedef SubmitCallback = bool Function(SurfaceFrame, CkCanvas); diff --git a/lib/web_ui/lib/src/engine/canvaskit/text.dart b/lib/web_ui/lib/src/engine/canvaskit/text.dart index 8faab8953654f..36f609f64d83a 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/text.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/text.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class CkParagraphStyle implements ui.ParagraphStyle { diff --git a/lib/web_ui/lib/src/engine/canvaskit/util.dart b/lib/web_ui/lib/src/engine/canvaskit/util.dart index ea96cdb0b3206..8e96c3ea193f6 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/util.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/util.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// An error related to the CanvasKit rendering backend. diff --git a/lib/web_ui/lib/src/engine/canvaskit/vertices.dart b/lib/web_ui/lib/src/engine/canvaskit/vertices.dart index ec13910db9c39..5a19717a7e091 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/vertices.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/vertices.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class CkVertices extends ManagedSkiaObject implements ui.Vertices { diff --git a/lib/web_ui/lib/src/engine/canvaskit/viewport_metrics.dart b/lib/web_ui/lib/src/engine/canvaskit/viewport_metrics.dart index 2e7572f224a88..7e6fa6e74359e 100644 --- a/lib/web_ui/lib/src/engine/canvaskit/viewport_metrics.dart +++ b/lib/web_ui/lib/src/engine/canvaskit/viewport_metrics.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class ViewportMetrics { diff --git a/lib/web_ui/lib/src/engine/clipboard.dart b/lib/web_ui/lib/src/engine/clipboard.dart index 251b85650fd75..12126df8b2cff 100644 --- a/lib/web_ui/lib/src/engine/clipboard.dart +++ b/lib/web_ui/lib/src/engine/clipboard.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Handles clipboard related platform messages. diff --git a/lib/web_ui/lib/src/engine/color_filter.dart b/lib/web_ui/lib/src/engine/color_filter.dart index 3513a605dc28e..a5a4f85b45d26 100644 --- a/lib/web_ui/lib/src/engine/color_filter.dart +++ b/lib/web_ui/lib/src/engine/color_filter.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A description of a color filter to apply when drawing a shape or compositing diff --git a/lib/web_ui/lib/src/engine/dom_canvas.dart b/lib/web_ui/lib/src/engine/dom_canvas.dart index 71fdc931312c3..768f6c8a4c8cb 100644 --- a/lib/web_ui/lib/src/engine/dom_canvas.dart +++ b/lib/web_ui/lib/src/engine/dom_canvas.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A canvas that renders to DOM elements and CSS properties. diff --git a/lib/web_ui/lib/src/engine/dom_renderer.dart b/lib/web_ui/lib/src/engine/dom_renderer.dart index cf2ff54602629..d650614f24448 100644 --- a/lib/web_ui/lib/src/engine/dom_renderer.dart +++ b/lib/web_ui/lib/src/engine/dom_renderer.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class DomRenderer { diff --git a/lib/web_ui/lib/src/engine/engine_canvas.dart b/lib/web_ui/lib/src/engine/engine_canvas.dart index 955bac1266ee1..18593f3e5aff0 100644 --- a/lib/web_ui/lib/src/engine/engine_canvas.dart +++ b/lib/web_ui/lib/src/engine/engine_canvas.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Defines canvas interface common across canvases that the [SceneBuilder] diff --git a/lib/web_ui/lib/src/engine/frame_reference.dart b/lib/web_ui/lib/src/engine/frame_reference.dart index 0df43a53c1b44..70de0a274aaaf 100644 --- a/lib/web_ui/lib/src/engine/frame_reference.dart +++ b/lib/web_ui/lib/src/engine/frame_reference.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A monotonically increasing frame number being rendered. diff --git a/lib/web_ui/lib/src/engine/html/backdrop_filter.dart b/lib/web_ui/lib/src/engine/html/backdrop_filter.dart index fe06a0553a9a6..ea2e54bd82696 100644 --- a/lib/web_ui/lib/src/engine/html/backdrop_filter.dart +++ b/lib/web_ui/lib/src/engine/html/backdrop_filter.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A surface that applies an image filter to background. diff --git a/lib/web_ui/lib/src/engine/html/canvas.dart b/lib/web_ui/lib/src/engine/html/canvas.dart index 40788b1139744..282b703838983 100644 --- a/lib/web_ui/lib/src/engine/html/canvas.dart +++ b/lib/web_ui/lib/src/engine/html/canvas.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class SurfaceCanvas implements ui.Canvas { diff --git a/lib/web_ui/lib/src/engine/html/clip.dart b/lib/web_ui/lib/src/engine/html/clip.dart index d1992f93be2f4..127327bfcc287 100644 --- a/lib/web_ui/lib/src/engine/html/clip.dart +++ b/lib/web_ui/lib/src/engine/html/clip.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Mixin used by surfaces that clip their contents using an overflowing DOM diff --git a/lib/web_ui/lib/src/engine/html/color_filter.dart b/lib/web_ui/lib/src/engine/html/color_filter.dart index abf08bb53e6ee..4b203897b52ac 100644 --- a/lib/web_ui/lib/src/engine/html/color_filter.dart +++ b/lib/web_ui/lib/src/engine/html/color_filter.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A surface that applies an [ColorFilter] to its children. diff --git a/lib/web_ui/lib/src/engine/html/debug_canvas_reuse_overlay.dart b/lib/web_ui/lib/src/engine/html/debug_canvas_reuse_overlay.dart index 3211ecf3bef61..b218430d1398b 100644 --- a/lib/web_ui/lib/src/engine/html/debug_canvas_reuse_overlay.dart +++ b/lib/web_ui/lib/src/engine/html/debug_canvas_reuse_overlay.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; html.HtmlElement _createContainer() { diff --git a/lib/web_ui/lib/src/engine/html/image_filter.dart b/lib/web_ui/lib/src/engine/html/image_filter.dart index fe49ac83c8a87..ce8afa83fd809 100644 --- a/lib/web_ui/lib/src/engine/html/image_filter.dart +++ b/lib/web_ui/lib/src/engine/html/image_filter.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A surface that applies an [imageFilter] to its children. diff --git a/lib/web_ui/lib/src/engine/html/offset.dart b/lib/web_ui/lib/src/engine/html/offset.dart index c622884e52720..e1cb4226cf75f 100644 --- a/lib/web_ui/lib/src/engine/html/offset.dart +++ b/lib/web_ui/lib/src/engine/html/offset.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A surface that translates its children using CSS transform and translate. diff --git a/lib/web_ui/lib/src/engine/html/opacity.dart b/lib/web_ui/lib/src/engine/html/opacity.dart index 4fd6d9155d863..126bc5b7fec4a 100644 --- a/lib/web_ui/lib/src/engine/html/opacity.dart +++ b/lib/web_ui/lib/src/engine/html/opacity.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A surface that makes its children transparent. diff --git a/lib/web_ui/lib/src/engine/html/painting.dart b/lib/web_ui/lib/src/engine/html/painting.dart index 0a955d2bb15d0..b90358cb0212d 100644 --- a/lib/web_ui/lib/src/engine/html/painting.dart +++ b/lib/web_ui/lib/src/engine/html/painting.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Implementation of [ui.Paint] used by the HTML rendering backend. diff --git a/lib/web_ui/lib/src/engine/html/path/conic.dart b/lib/web_ui/lib/src/engine/html/path/conic.dart index 84e6e0c378f2f..73437c366e908 100644 --- a/lib/web_ui/lib/src/engine/html/path/conic.dart +++ b/lib/web_ui/lib/src/engine/html/path/conic.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Converts conic curve to a list of quadratic curves for rendering on diff --git a/lib/web_ui/lib/src/engine/html/path/cubic.dart b/lib/web_ui/lib/src/engine/html/path/cubic.dart index 1a222e6f4f933..223d0fc651230 100644 --- a/lib/web_ui/lib/src/engine/html/path/cubic.dart +++ b/lib/web_ui/lib/src/engine/html/path/cubic.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Chops cubic at Y extrema points and writes result to [dest]. diff --git a/lib/web_ui/lib/src/engine/html/path/path.dart b/lib/web_ui/lib/src/engine/html/path/path.dart index 15677cb99d9b6..3eb52f8ea0fd3 100644 --- a/lib/web_ui/lib/src/engine/html/path/path.dart +++ b/lib/web_ui/lib/src/engine/html/path/path.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A complex, one-dimensional subset of a plane. diff --git a/lib/web_ui/lib/src/engine/html/path/path_metrics.dart b/lib/web_ui/lib/src/engine/html/path/path_metrics.dart index ada8f12335d02..5ac8f7d815b44 100644 --- a/lib/web_ui/lib/src/engine/html/path/path_metrics.dart +++ b/lib/web_ui/lib/src/engine/html/path/path_metrics.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; const double kEpsilon = 0.000000001; diff --git a/lib/web_ui/lib/src/engine/html/path/path_ref.dart b/lib/web_ui/lib/src/engine/html/path/path_ref.dart index 55f41de303a16..e4ded5a2fe3ce 100644 --- a/lib/web_ui/lib/src/engine/html/path/path_ref.dart +++ b/lib/web_ui/lib/src/engine/html/path/path_ref.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Stores the path verbs, points and conic weights. diff --git a/lib/web_ui/lib/src/engine/html/path/path_to_svg.dart b/lib/web_ui/lib/src/engine/html/path/path_to_svg.dart index 85b5ab4cfb3c7..3f606ec00e33b 100644 --- a/lib/web_ui/lib/src/engine/html/path/path_to_svg.dart +++ b/lib/web_ui/lib/src/engine/html/path/path_to_svg.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Converts [path] to SVG path syntax to be used as "d" attribute in path diff --git a/lib/web_ui/lib/src/engine/html/path/path_utils.dart b/lib/web_ui/lib/src/engine/html/path/path_utils.dart index 9908cf52370c8..d8fa2b710ec22 100644 --- a/lib/web_ui/lib/src/engine/html/path/path_utils.dart +++ b/lib/web_ui/lib/src/engine/html/path/path_utils.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Mask used to keep track of types of verbs used in a path segment. diff --git a/lib/web_ui/lib/src/engine/html/path/path_windings.dart b/lib/web_ui/lib/src/engine/html/path/path_windings.dart index e922e4a53360a..6401b1f26d175 100644 --- a/lib/web_ui/lib/src/engine/html/path/path_windings.dart +++ b/lib/web_ui/lib/src/engine/html/path/path_windings.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Computes winding number and onCurveCount for a path and point. diff --git a/lib/web_ui/lib/src/engine/html/path/tangent.dart b/lib/web_ui/lib/src/engine/html/path/tangent.dart index ce3a2e4336647..5784431668ad0 100644 --- a/lib/web_ui/lib/src/engine/html/path/tangent.dart +++ b/lib/web_ui/lib/src/engine/html/path/tangent.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Computes tangent at point x,y on a line. diff --git a/lib/web_ui/lib/src/engine/html/picture.dart b/lib/web_ui/lib/src/engine/html/picture.dart index 1bd6ca87a5f80..650aa90d3dfd8 100644 --- a/lib/web_ui/lib/src/engine/html/picture.dart +++ b/lib/web_ui/lib/src/engine/html/picture.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; // TODO(yjbanov): this is currently very naive. We probably want to cache diff --git a/lib/web_ui/lib/src/engine/html/platform_view.dart b/lib/web_ui/lib/src/engine/html/platform_view.dart index df76f70602ef7..c5bb82a6aa3aa 100644 --- a/lib/web_ui/lib/src/engine/html/platform_view.dart +++ b/lib/web_ui/lib/src/engine/html/platform_view.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A surface containing a platform view, which is an HTML element. diff --git a/lib/web_ui/lib/src/engine/html/recording_canvas.dart b/lib/web_ui/lib/src/engine/html/recording_canvas.dart index f20635a4e6d14..4ee18c65abc59 100644 --- a/lib/web_ui/lib/src/engine/html/recording_canvas.dart +++ b/lib/web_ui/lib/src/engine/html/recording_canvas.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Enable this to print every command applied by a canvas. diff --git a/lib/web_ui/lib/src/engine/html/render_vertices.dart b/lib/web_ui/lib/src/engine/html/render_vertices.dart index 4d18e17a69984..cc8720fa4a6e3 100644 --- a/lib/web_ui/lib/src/engine/html/render_vertices.dart +++ b/lib/web_ui/lib/src/engine/html/render_vertices.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; _GlRenderer? _glRenderer; @@ -833,7 +833,7 @@ class _GlContextCache { _GlContext.fromOffscreenCanvas(_offScreenCanvas!._canvas!); } else { _cachedContext ??= _GlContext.fromCanvas(_offScreenCanvas!._glCanvas!, - webGLVersion == 1); + webGLVersion == WebGLVersion.webgl1); } _cachedContext!.setViewportSize(widthInPixels, heightInPixels); return _cachedContext; diff --git a/lib/web_ui/lib/src/engine/html/scene.dart b/lib/web_ui/lib/src/engine/html/scene.dart index 2207deeba72d8..9e8a9e1159010 100644 --- a/lib/web_ui/lib/src/engine/html/scene.dart +++ b/lib/web_ui/lib/src/engine/html/scene.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class SurfaceScene implements ui.Scene { diff --git a/lib/web_ui/lib/src/engine/html/scene_builder.dart b/lib/web_ui/lib/src/engine/html/scene_builder.dart index bdeca3aed8345..80cf5ed1c9660 100644 --- a/lib/web_ui/lib/src/engine/html/scene_builder.dart +++ b/lib/web_ui/lib/src/engine/html/scene_builder.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class SurfaceSceneBuilder implements ui.SceneBuilder { diff --git a/lib/web_ui/lib/src/engine/html/shaders/normalized_gradient.dart b/lib/web_ui/lib/src/engine/html/shaders/normalized_gradient.dart index f53dc4d7fc946..24ae27b0e7efb 100644 --- a/lib/web_ui/lib/src/engine/html/shaders/normalized_gradient.dart +++ b/lib/web_ui/lib/src/engine/html/shaders/normalized_gradient.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Converts colors and stops to typed array of bias, scale and threshold to use diff --git a/lib/web_ui/lib/src/engine/html/shaders/shader.dart b/lib/web_ui/lib/src/engine/html/shaders/shader.dart index 380dbfec8c9e1..1d103aeaa367a 100644 --- a/lib/web_ui/lib/src/engine/html/shaders/shader.dart +++ b/lib/web_ui/lib/src/engine/html/shaders/shader.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; abstract class EngineGradient implements ui.Gradient { @@ -31,8 +31,8 @@ class GradientSweep extends EngineGradient { Object createPaintStyle(html.CanvasRenderingContext2D? ctx, ui.Rect? shaderBounds, double density) { assert(shaderBounds != null); - int widthInPixels = shaderBounds!.right.ceil(); - int heightInPixels = shaderBounds.bottom.ceil(); + int widthInPixels = shaderBounds!.width.ceil(); + int heightInPixels = shaderBounds.height.ceil(); assert(widthInPixels > 0 && heightInPixels > 0); initWebGl(); @@ -42,7 +42,7 @@ class GradientSweep extends EngineGradient { _GlContext gl = _OffScreenCanvas.supported ? _GlContext.fromOffscreenCanvas(offScreenCanvas._canvas!) : _GlContext.fromCanvas(offScreenCanvas._glCanvas!, - webGLVersion == 1); + webGLVersion == WebGLVersion.webgl1); gl.setViewportSize(widthInPixels, heightInPixels); NormalizedGradient normalizedGradient = NormalizedGradient( @@ -56,8 +56,8 @@ class GradientSweep extends EngineGradient { double centerX = (center.dx - shaderBounds.left) / (shaderBounds.width); double centerY = (center.dy - shaderBounds.top) / (shaderBounds.height); gl.setUniform2f(tileOffset, - shaderBounds.left + 2 * (shaderBounds.width * (centerX - 0.5)), - -shaderBounds.top - 2 * (shaderBounds.height * (centerY - 0.5))); + 2 * (shaderBounds.width * (centerX - 0.5)), + 2 * (shaderBounds.height * (centerY - 0.5))); Object angleRange = gl.getUniformLocation(glProgram.program, 'angle_range'); gl.setUniform2f(angleRange, startAngle, endAngle); normalizedGradient.setupUniforms(gl, glProgram); @@ -67,8 +67,8 @@ class GradientSweep extends EngineGradient { gl.setUniformMatrix4fv(gradientMatrix, false, matrix4!); } - Object? imageBitmap = _glRenderer!.drawRect(shaderBounds, gl, - glProgram, normalizedGradient, widthInPixels, heightInPixels); + Object? imageBitmap = _glRenderer!.drawRect(ui.Rect.fromLTWH(0, 0, shaderBounds.width, shaderBounds.height), + gl, glProgram, normalizedGradient, widthInPixels, heightInPixels); return ctx!.createPattern(imageBitmap!, 'no-repeat')!; } @@ -170,6 +170,8 @@ class GradientLinear extends EngineGradient { ui.Rect? shaderBounds, double density) { _FastMatrix64? matrix4 = this.matrix4; html.CanvasGradient gradient; + final double offsetX = shaderBounds!.left; + final double offsetY = shaderBounds.top; if (matrix4 != null) { final centerX = (from.dx + to.dx) / 2.0; final centerY = (from.dy + to.dy) / 2.0; @@ -177,10 +179,10 @@ class GradientLinear extends EngineGradient { final double fromX = matrix4.transformedX + centerX; final double fromY = matrix4.transformedY + centerY; matrix4.transform(to.dx - centerX, to.dy - centerY); - gradient = ctx!.createLinearGradient(fromX, fromY, - matrix4.transformedX + centerX, matrix4.transformedY + centerY); + gradient = ctx!.createLinearGradient(fromX - offsetX, fromY - offsetY, + matrix4.transformedX + centerX - offsetX, matrix4.transformedY - offsetY + centerY); } else { - gradient = ctx!.createLinearGradient(from.dx, from.dy, to.dx, to.dy); + gradient = ctx!.createLinearGradient(from.dx - offsetX, from.dy - offsetY, to.dx - offsetX, to.dy - offsetY); } final List? colorStops = this.colorStops; @@ -222,8 +224,11 @@ class GradientRadial extends EngineGradient { 'TileMode not supported in GradientRadial shader'); } } + final double offsetX = shaderBounds!.left; + final double offsetY = shaderBounds.top; final html.CanvasGradient gradient = ctx!.createRadialGradient( - center.dx, center.dy, 0, center.dx, center.dy, radius); + center.dx - offsetX, center.dy - offsetY, 0, + center.dx - offsetX, center.dy - offsetY, radius); final List? colorStops = this.colorStops; if (colorStops == null) { assert(colors.length == 2); diff --git a/lib/web_ui/lib/src/engine/html/shaders/shader_builder.dart b/lib/web_ui/lib/src/engine/html/shaders/shader_builder.dart index d5d90cb93eee0..402b64c6bcabc 100644 --- a/lib/web_ui/lib/src/engine/html/shaders/shader_builder.dart +++ b/lib/web_ui/lib/src/engine/html/shaders/shader_builder.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Creates shader program for target webgl version. @@ -266,14 +266,6 @@ class ShaderMethod { } } -/// html webgl version qualifier constants. -abstract class WebGLVersion { - // WebGL 1.0 is based on OpenGL ES 2.0 / GLSL 1.00 - static const int webgl1 = 1; - // WebGL 2.0 is based on OpenGL ES 3.0 / GLSL 3.00 - static const int webgl2 = 2; -} - /// WebGl Shader data types. abstract class ShaderType { // Basic types. diff --git a/lib/web_ui/lib/src/engine/html/surface.dart b/lib/web_ui/lib/src/engine/html/surface.dart index f6b3ffe5fa893..3a947bb15dc1b 100644 --- a/lib/web_ui/lib/src/engine/html/surface.dart +++ b/lib/web_ui/lib/src/engine/html/surface.dart @@ -2,10 +2,10 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 -part of engine; - /// When `true` prints statistics about what happened to the surface tree when + +// @dart = 2.12 +part of engine; /// it was composited. /// /// Also paints an on-screen overlay with the numbers visualized as a timeline. diff --git a/lib/web_ui/lib/src/engine/html/surface_stats.dart b/lib/web_ui/lib/src/engine/html/surface_stats.dart index 6e524a4f6e266..d74f4b39100d2 100644 --- a/lib/web_ui/lib/src/engine/html/surface_stats.dart +++ b/lib/web_ui/lib/src/engine/html/surface_stats.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Surfaces that were retained this frame. diff --git a/lib/web_ui/lib/src/engine/html/transform.dart b/lib/web_ui/lib/src/engine/html/transform.dart index b1e99808af11c..ea540dd655b23 100644 --- a/lib/web_ui/lib/src/engine/html/transform.dart +++ b/lib/web_ui/lib/src/engine/html/transform.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A surface that transforms its children using CSS transform. diff --git a/lib/web_ui/lib/src/engine/html_image_codec.dart b/lib/web_ui/lib/src/engine/html_image_codec.dart index c7a5e7e911b3d..b6de4cc334887 100644 --- a/lib/web_ui/lib/src/engine/html_image_codec.dart +++ b/lib/web_ui/lib/src/engine/html_image_codec.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; final bool _supportsDecode = js_util.getProperty( diff --git a/lib/web_ui/lib/src/engine/keyboard.dart b/lib/web_ui/lib/src/engine/keyboard.dart index 95068184cb984..8779e095d552d 100644 --- a/lib/web_ui/lib/src/engine/keyboard.dart +++ b/lib/web_ui/lib/src/engine/keyboard.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// After a keydown is received, this is the duration we wait for a repeat event diff --git a/lib/web_ui/lib/src/engine/mouse_cursor.dart b/lib/web_ui/lib/src/engine/mouse_cursor.dart index 6a979c554e3fe..ad926e4a6c4bf 100644 --- a/lib/web_ui/lib/src/engine/mouse_cursor.dart +++ b/lib/web_ui/lib/src/engine/mouse_cursor.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Provides mouse cursor bindings, such as the `flutter/mousecursor` channel. diff --git a/lib/web_ui/lib/src/engine/navigation/history.dart b/lib/web_ui/lib/src/engine/navigation/history.dart index 98f74fc48d3fb..d6623bb686a4c 100644 --- a/lib/web_ui/lib/src/engine/navigation/history.dart +++ b/lib/web_ui/lib/src/engine/navigation/history.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// An abstract class that provides the API for [EngineWindow] to delegate its diff --git a/lib/web_ui/lib/src/engine/navigation/js_url_strategy.dart b/lib/web_ui/lib/src/engine/navigation/js_url_strategy.dart index decb7c249d44d..1592d9451c974 100644 --- a/lib/web_ui/lib/src/engine/navigation/js_url_strategy.dart +++ b/lib/web_ui/lib/src/engine/navigation/js_url_strategy.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; typedef _PathGetter = String Function(); diff --git a/lib/web_ui/lib/src/engine/navigation/url_strategy.dart b/lib/web_ui/lib/src/engine/navigation/url_strategy.dart index fcf2cecfd0b8e..0cf1470050512 100644 --- a/lib/web_ui/lib/src/engine/navigation/url_strategy.dart +++ b/lib/web_ui/lib/src/engine/navigation/url_strategy.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Represents and reads route state from the browser's URL. diff --git a/lib/web_ui/lib/src/engine/onscreen_logging.dart b/lib/web_ui/lib/src/engine/onscreen_logging.dart index c52580191f3f8..49a4dff26d435 100644 --- a/lib/web_ui/lib/src/engine/onscreen_logging.dart +++ b/lib/web_ui/lib/src/engine/onscreen_logging.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; html.Element? _logElement; diff --git a/lib/web_ui/lib/src/engine/picture.dart b/lib/web_ui/lib/src/engine/picture.dart index 42304da062c9d..c4e2207655ef5 100644 --- a/lib/web_ui/lib/src/engine/picture.dart +++ b/lib/web_ui/lib/src/engine/picture.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// An implementation of [ui.PictureRecorder] backed by a [RecordingCanvas]. diff --git a/lib/web_ui/lib/src/engine/platform_dispatcher.dart b/lib/web_ui/lib/src/engine/platform_dispatcher.dart index 6ca71d440d41f..d196ef5c9ff93 100644 --- a/lib/web_ui/lib/src/engine/platform_dispatcher.dart +++ b/lib/web_ui/lib/src/engine/platform_dispatcher.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Requests that the browser schedule a frame. diff --git a/lib/web_ui/lib/src/engine/platform_views.dart b/lib/web_ui/lib/src/engine/platform_views.dart index cc6e904c9d76c..14448269e55fb 100644 --- a/lib/web_ui/lib/src/engine/platform_views.dart +++ b/lib/web_ui/lib/src/engine/platform_views.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; // TODO(yjbanov): The code in this file was temporarily moved to lib/web_ui/lib/ui.dart diff --git a/lib/web_ui/lib/src/engine/plugins.dart b/lib/web_ui/lib/src/engine/plugins.dart index ec39df944124f..1f7361be83347 100644 --- a/lib/web_ui/lib/src/engine/plugins.dart +++ b/lib/web_ui/lib/src/engine/plugins.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; Future Function(String, ByteData?, ui.PlatformMessageResponseCallback?)? pluginMessageCallHandler; diff --git a/lib/web_ui/lib/src/engine/pointer_binding.dart b/lib/web_ui/lib/src/engine/pointer_binding.dart index 994815675e835..7a28ad5588467 100644 --- a/lib/web_ui/lib/src/engine/pointer_binding.dart +++ b/lib/web_ui/lib/src/engine/pointer_binding.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Set this flag to true to see all the fired events in the console. diff --git a/lib/web_ui/lib/src/engine/pointer_converter.dart b/lib/web_ui/lib/src/engine/pointer_converter.dart index 0140663a2bb5d..f7870823b97fb 100644 --- a/lib/web_ui/lib/src/engine/pointer_converter.dart +++ b/lib/web_ui/lib/src/engine/pointer_converter.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class _PointerState { diff --git a/lib/web_ui/lib/src/engine/profiler.dart b/lib/web_ui/lib/src/engine/profiler.dart index eeeab3d576d1c..825bdbeb35e50 100644 --- a/lib/web_ui/lib/src/engine/profiler.dart +++ b/lib/web_ui/lib/src/engine/profiler.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A function that receives a benchmark [value] labeleb by [name]. diff --git a/lib/web_ui/lib/src/engine/rrect_renderer.dart b/lib/web_ui/lib/src/engine/rrect_renderer.dart index 3ccc054331d41..a32b398966723 100644 --- a/lib/web_ui/lib/src/engine/rrect_renderer.dart +++ b/lib/web_ui/lib/src/engine/rrect_renderer.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Renders an RRect using path primitives. diff --git a/lib/web_ui/lib/src/engine/semantics/accessibility.dart b/lib/web_ui/lib/src/engine/semantics/accessibility.dart index 101ae7bded7f1..e0f3374227fe3 100644 --- a/lib/web_ui/lib/src/engine/semantics/accessibility.dart +++ b/lib/web_ui/lib/src/engine/semantics/accessibility.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Singleton for accessing accessibility announcements from the platform. diff --git a/lib/web_ui/lib/src/engine/semantics/checkable.dart b/lib/web_ui/lib/src/engine/semantics/checkable.dart index 9c7c2c101d834..2fbf58ad3888c 100644 --- a/lib/web_ui/lib/src/engine/semantics/checkable.dart +++ b/lib/web_ui/lib/src/engine/semantics/checkable.dart @@ -11,7 +11,7 @@ // framework. Currently the framework does not report the // grouping of radio buttons. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// The specific type of checkable control. diff --git a/lib/web_ui/lib/src/engine/semantics/image.dart b/lib/web_ui/lib/src/engine/semantics/image.dart index af469fcfd3547..8a037b5c3b082 100644 --- a/lib/web_ui/lib/src/engine/semantics/image.dart +++ b/lib/web_ui/lib/src/engine/semantics/image.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Represents semantic objects that deliver information in a visual manner. diff --git a/lib/web_ui/lib/src/engine/semantics/incrementable.dart b/lib/web_ui/lib/src/engine/semantics/incrementable.dart index 616663a25d9ac..8a3f144a9af58 100644 --- a/lib/web_ui/lib/src/engine/semantics/incrementable.dart +++ b/lib/web_ui/lib/src/engine/semantics/incrementable.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Adds increment/decrement event handling to a semantics object. diff --git a/lib/web_ui/lib/src/engine/semantics/label_and_value.dart b/lib/web_ui/lib/src/engine/semantics/label_and_value.dart index 1e4d94060db8c..0784a5317b661 100644 --- a/lib/web_ui/lib/src/engine/semantics/label_and_value.dart +++ b/lib/web_ui/lib/src/engine/semantics/label_and_value.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Renders [_label] and [_value] to the semantics DOM. diff --git a/lib/web_ui/lib/src/engine/semantics/live_region.dart b/lib/web_ui/lib/src/engine/semantics/live_region.dart index a34c86c75624e..b926beed86950 100644 --- a/lib/web_ui/lib/src/engine/semantics/live_region.dart +++ b/lib/web_ui/lib/src/engine/semantics/live_region.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Manages semantics configurations that represent live regions. diff --git a/lib/web_ui/lib/src/engine/semantics/scrollable.dart b/lib/web_ui/lib/src/engine/semantics/scrollable.dart index 9cae3a9189c11..9be2379df40fc 100644 --- a/lib/web_ui/lib/src/engine/semantics/scrollable.dart +++ b/lib/web_ui/lib/src/engine/semantics/scrollable.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Implements vertical and horizontal scrolling functionality for semantics diff --git a/lib/web_ui/lib/src/engine/semantics/semantics.dart b/lib/web_ui/lib/src/engine/semantics/semantics.dart index 791caed14cfb2..226d9a478acb5 100644 --- a/lib/web_ui/lib/src/engine/semantics/semantics.dart +++ b/lib/web_ui/lib/src/engine/semantics/semantics.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Set this flag to `true` to cause the engine to visualize the semantics tree diff --git a/lib/web_ui/lib/src/engine/semantics/semantics_helper.dart b/lib/web_ui/lib/src/engine/semantics/semantics_helper.dart index e07a9dc1f57f2..93c086670addd 100644 --- a/lib/web_ui/lib/src/engine/semantics/semantics_helper.dart +++ b/lib/web_ui/lib/src/engine/semantics/semantics_helper.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// The maximum [semanticsActivationAttempts] before we give up waiting for diff --git a/lib/web_ui/lib/src/engine/semantics/tappable.dart b/lib/web_ui/lib/src/engine/semantics/tappable.dart index 8439dd3f70f08..f7edf344ed3f2 100644 --- a/lib/web_ui/lib/src/engine/semantics/tappable.dart +++ b/lib/web_ui/lib/src/engine/semantics/tappable.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Listens to HTML "click" gestures detected by the browser. diff --git a/lib/web_ui/lib/src/engine/semantics/text_field.dart b/lib/web_ui/lib/src/engine/semantics/text_field.dart index 91b5d8ba9dc5b..cde9820563c35 100644 --- a/lib/web_ui/lib/src/engine/semantics/text_field.dart +++ b/lib/web_ui/lib/src/engine/semantics/text_field.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Text editing used by accesibility mode. diff --git a/lib/web_ui/lib/src/engine/services/buffers.dart b/lib/web_ui/lib/src/engine/services/buffers.dart index 747f13c0f5a51..33455825f05af 100644 --- a/lib/web_ui/lib/src/engine/services/buffers.dart +++ b/lib/web_ui/lib/src/engine/services/buffers.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; abstract class _TypedDataBuffer extends ListBase { diff --git a/lib/web_ui/lib/src/engine/services/message_codec.dart b/lib/web_ui/lib/src/engine/services/message_codec.dart index 8a3cfdabd5f14..1ae695210c8e4 100644 --- a/lib/web_ui/lib/src/engine/services/message_codec.dart +++ b/lib/web_ui/lib/src/engine/services/message_codec.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A message encoding/decoding mechanism. diff --git a/lib/web_ui/lib/src/engine/services/message_codecs.dart b/lib/web_ui/lib/src/engine/services/message_codecs.dart index fbad9a56d1ebe..768a744fa2f3f 100644 --- a/lib/web_ui/lib/src/engine/services/message_codecs.dart +++ b/lib/web_ui/lib/src/engine/services/message_codecs.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// [MessageCodec] with unencoded binary messages represented using [ByteData]. diff --git a/lib/web_ui/lib/src/engine/services/serialization.dart b/lib/web_ui/lib/src/engine/services/serialization.dart index 4296aacbf6982..2fc103a31c288 100644 --- a/lib/web_ui/lib/src/engine/services/serialization.dart +++ b/lib/web_ui/lib/src/engine/services/serialization.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Write-only buffer for incrementally building a [ByteData] instance. diff --git a/lib/web_ui/lib/src/engine/shadow.dart b/lib/web_ui/lib/src/engine/shadow.dart index 09292aead178e..fb5dbec217701 100644 --- a/lib/web_ui/lib/src/engine/shadow.dart +++ b/lib/web_ui/lib/src/engine/shadow.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// How far is the light source from the surface of the UI. diff --git a/lib/web_ui/lib/src/engine/test_embedding.dart b/lib/web_ui/lib/src/engine/test_embedding.dart index 0255e5fb19601..17c582605b32e 100644 --- a/lib/web_ui/lib/src/engine/test_embedding.dart +++ b/lib/web_ui/lib/src/engine/test_embedding.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; const bool _debugLogHistoryActions = false; diff --git a/lib/web_ui/lib/src/engine/text/canvas_paragraph.dart b/lib/web_ui/lib/src/engine/text/canvas_paragraph.dart index 0134a3d4c4284..7f576fde19df8 100644 --- a/lib/web_ui/lib/src/engine/text/canvas_paragraph.dart +++ b/lib/web_ui/lib/src/engine/text/canvas_paragraph.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A paragraph made up of a flat list of text spans and placeholders. diff --git a/lib/web_ui/lib/src/engine/text/font_collection.dart b/lib/web_ui/lib/src/engine/text/font_collection.dart index 96a63e1ebbe73..09e7d43e7f25b 100644 --- a/lib/web_ui/lib/src/engine/text/font_collection.dart +++ b/lib/web_ui/lib/src/engine/text/font_collection.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; const String _ahemFontFamily = 'Ahem'; diff --git a/lib/web_ui/lib/src/engine/text/line_break_properties.dart b/lib/web_ui/lib/src/engine/text/line_break_properties.dart index f9dbc99bef6f9..98077391dfd05 100644 --- a/lib/web_ui/lib/src/engine/text/line_break_properties.dart +++ b/lib/web_ui/lib/src/engine/text/line_break_properties.dart @@ -12,7 +12,7 @@ // # Unicode and the Unicode Logo are registered trademarks of Unicode, Inc. in the U.S. and other countries. // # For terms of use, see http://www.unicode.org/terms_of_use.html -// @dart = 2.10 +// @dart = 2.12 part of engine; /// For an explanation of these enum values, see: diff --git a/lib/web_ui/lib/src/engine/text/line_breaker.dart b/lib/web_ui/lib/src/engine/text/line_breaker.dart index 50970980bf518..d8f7804f2a9c9 100644 --- a/lib/web_ui/lib/src/engine/text/line_breaker.dart +++ b/lib/web_ui/lib/src/engine/text/line_breaker.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Various types of line breaks as defined by the Unicode spec. diff --git a/lib/web_ui/lib/src/engine/text/measurement.dart b/lib/web_ui/lib/src/engine/text/measurement.dart index a03ea9f8ddc92..9707069c4a04d 100644 --- a/lib/web_ui/lib/src/engine/text/measurement.dart +++ b/lib/web_ui/lib/src/engine/text/measurement.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; // TODO(yjbanov): this is a hack we use to compute ideographic baseline; this diff --git a/lib/web_ui/lib/src/engine/text/paragraph.dart b/lib/web_ui/lib/src/engine/text/paragraph.dart index d956e520e620f..6481501e1b3e0 100644 --- a/lib/web_ui/lib/src/engine/text/paragraph.dart +++ b/lib/web_ui/lib/src/engine/text/paragraph.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; const ui.Color _defaultTextColor = ui.Color(0xFFFF0000); diff --git a/lib/web_ui/lib/src/engine/text/ruler.dart b/lib/web_ui/lib/src/engine/text/ruler.dart index 2883d83d56e91..f3a450a011f51 100644 --- a/lib/web_ui/lib/src/engine/text/ruler.dart +++ b/lib/web_ui/lib/src/engine/text/ruler.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; String _buildCssFontString({ diff --git a/lib/web_ui/lib/src/engine/text/unicode_range.dart b/lib/web_ui/lib/src/engine/text/unicode_range.dart index a2148fdcee35c..e882835f80a12 100644 --- a/lib/web_ui/lib/src/engine/text/unicode_range.dart +++ b/lib/web_ui/lib/src/engine/text/unicode_range.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; const int _kChar_0 = 48; diff --git a/lib/web_ui/lib/src/engine/text/word_break_properties.dart b/lib/web_ui/lib/src/engine/text/word_break_properties.dart index 53acf3a267b8b..298cf1e166287 100644 --- a/lib/web_ui/lib/src/engine/text/word_break_properties.dart +++ b/lib/web_ui/lib/src/engine/text/word_break_properties.dart @@ -12,7 +12,7 @@ // # Unicode and the Unicode Logo are registered trademarks of Unicode, Inc. in the U.S. and other countries. // # For terms of use, see http://www.unicode.org/terms_of_use.html -// @dart = 2.10 +// @dart = 2.12 part of engine; /// For an explanation of these enum values, see: diff --git a/lib/web_ui/lib/src/engine/text/word_breaker.dart b/lib/web_ui/lib/src/engine/text/word_breaker.dart index 1904b89ca8c15..ce9327748c75f 100644 --- a/lib/web_ui/lib/src/engine/text/word_breaker.dart +++ b/lib/web_ui/lib/src/engine/text/word_breaker.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class _FindBreakDirection { diff --git a/lib/web_ui/lib/src/engine/text_editing/autofill_hint.dart b/lib/web_ui/lib/src/engine/text_editing/autofill_hint.dart index 0ce6f3b426698..427bc6afe595b 100644 --- a/lib/web_ui/lib/src/engine/text_editing/autofill_hint.dart +++ b/lib/web_ui/lib/src/engine/text_editing/autofill_hint.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Maps AutofillHints from the framework to the autofill hints that is used for diff --git a/lib/web_ui/lib/src/engine/text_editing/input_type.dart b/lib/web_ui/lib/src/engine/text_editing/input_type.dart index af65b91a38a41..4b3f6576b69bb 100644 --- a/lib/web_ui/lib/src/engine/text_editing/input_type.dart +++ b/lib/web_ui/lib/src/engine/text_editing/input_type.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Various types of inputs used in text fields. diff --git a/lib/web_ui/lib/src/engine/text_editing/text_capitalization.dart b/lib/web_ui/lib/src/engine/text_editing/text_capitalization.dart index a9f04137bb0bb..c9b07851a2397 100644 --- a/lib/web_ui/lib/src/engine/text_editing/text_capitalization.dart +++ b/lib/web_ui/lib/src/engine/text_editing/text_capitalization.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Controls the capitalization of the text. diff --git a/lib/web_ui/lib/src/engine/text_editing/text_editing.dart b/lib/web_ui/lib/src/engine/text_editing/text_editing.dart index 05f4331f2ed92..b8342b7b6c8e5 100644 --- a/lib/web_ui/lib/src/engine/text_editing/text_editing.dart +++ b/lib/web_ui/lib/src/engine/text_editing/text_editing.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Make the content editable span visible to facilitate debugging. diff --git a/lib/web_ui/lib/src/engine/ulps.dart b/lib/web_ui/lib/src/engine/ulps.dart index a4b279bf700c6..e65792d5db9bf 100644 --- a/lib/web_ui/lib/src/engine/ulps.dart +++ b/lib/web_ui/lib/src/engine/ulps.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; // This is a small library to handle stability for floating point operations. diff --git a/lib/web_ui/lib/src/engine/util.dart b/lib/web_ui/lib/src/engine/util.dart index f371594efaa75..cfb2a73cfb9fa 100644 --- a/lib/web_ui/lib/src/engine/util.dart +++ b/lib/web_ui/lib/src/engine/util.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// Generic callback signature, used by [_futurize]. diff --git a/lib/web_ui/lib/src/engine/validators.dart b/lib/web_ui/lib/src/engine/validators.dart index c01fa8eff2b23..d90acc59c4201 100644 --- a/lib/web_ui/lib/src/engine/validators.dart +++ b/lib/web_ui/lib/src/engine/validators.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; bool rectIsValid(ui.Rect rect) { diff --git a/lib/web_ui/lib/src/engine/vector_math.dart b/lib/web_ui/lib/src/engine/vector_math.dart index df614126ce342..d91b4178809d5 100644 --- a/lib/web_ui/lib/src/engine/vector_math.dart +++ b/lib/web_ui/lib/src/engine/vector_math.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; class Matrix4 { diff --git a/lib/web_ui/lib/src/engine/web_experiments.dart b/lib/web_ui/lib/src/engine/web_experiments.dart index 1a425ab0bb2f2..ecc53cb70be3f 100644 --- a/lib/web_ui/lib/src/engine/web_experiments.dart +++ b/lib/web_ui/lib/src/engine/web_experiments.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// A bag of all experiment flags in the web engine. diff --git a/lib/web_ui/lib/src/engine/window.dart b/lib/web_ui/lib/src/engine/window.dart index 4b206ac644d47..78defa3bd3ca9 100644 --- a/lib/web_ui/lib/src/engine/window.dart +++ b/lib/web_ui/lib/src/engine/window.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of engine; /// When set to true, all platform messages will be printed to the console. diff --git a/lib/web_ui/lib/src/ui/annotations.dart b/lib/web_ui/lib/src/ui/annotations.dart index c2670d5282cc7..3aa8f3a009cb0 100644 --- a/lib/web_ui/lib/src/ui/annotations.dart +++ b/lib/web_ui/lib/src/ui/annotations.dart @@ -4,7 +4,7 @@ // TODO(dnfield): Remove unused_import ignores when https://github.com/dart-lang/sdk/issues/35164 is resolved. -// @dart = 2.10 +// @dart = 2.12 part of ui; // TODO(dnfield): Update this if/when we default this to on in the tool, diff --git a/lib/web_ui/lib/src/ui/canvas.dart b/lib/web_ui/lib/src/ui/canvas.dart index 7c00dbc53c1d0..d52995fd2d091 100644 --- a/lib/web_ui/lib/src/ui/canvas.dart +++ b/lib/web_ui/lib/src/ui/canvas.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; enum PointMode { diff --git a/lib/web_ui/lib/src/ui/channel_buffers.dart b/lib/web_ui/lib/src/ui/channel_buffers.dart index e045e75864cc7..4c35fae809cf1 100644 --- a/lib/web_ui/lib/src/ui/channel_buffers.dart +++ b/lib/web_ui/lib/src/ui/channel_buffers.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 // This is identical to ../../../../ui/channel_buffers.dart with the // following exceptions: diff --git a/lib/web_ui/lib/src/ui/compositing.dart b/lib/web_ui/lib/src/ui/compositing.dart index 6850caeaec73f..6808059c0c5dc 100644 --- a/lib/web_ui/lib/src/ui/compositing.dart +++ b/lib/web_ui/lib/src/ui/compositing.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; abstract class Scene { diff --git a/lib/web_ui/lib/src/ui/geometry.dart b/lib/web_ui/lib/src/ui/geometry.dart index 0ec3c06550a20..122b6ea6cffeb 100644 --- a/lib/web_ui/lib/src/ui/geometry.dart +++ b/lib/web_ui/lib/src/ui/geometry.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; abstract class OffsetBase { diff --git a/lib/web_ui/lib/src/ui/hash_codes.dart b/lib/web_ui/lib/src/ui/hash_codes.dart index 58efa17c69588..702efc3bef0ab 100644 --- a/lib/web_ui/lib/src/ui/hash_codes.dart +++ b/lib/web_ui/lib/src/ui/hash_codes.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; class _HashEnd { diff --git a/lib/web_ui/lib/src/ui/initialization.dart b/lib/web_ui/lib/src/ui/initialization.dart index 06bd1eb80ba27..ffb54dc60d08b 100644 --- a/lib/web_ui/lib/src/ui/initialization.dart +++ b/lib/web_ui/lib/src/ui/initialization.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; Future webOnlyInitializePlatform({ diff --git a/lib/web_ui/lib/src/ui/lerp.dart b/lib/web_ui/lib/src/ui/lerp.dart index 364209411fa6e..0948e36810243 100644 --- a/lib/web_ui/lib/src/ui/lerp.dart +++ b/lib/web_ui/lib/src/ui/lerp.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; /// Linearly interpolate between two numbers, `a` and `b`, by an extrapolation diff --git a/lib/web_ui/lib/src/ui/natives.dart b/lib/web_ui/lib/src/ui/natives.dart index e4817afca7241..02e8e7c19d258 100644 --- a/lib/web_ui/lib/src/ui/natives.dart +++ b/lib/web_ui/lib/src/ui/natives.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; List saveCompilationTrace() { diff --git a/lib/web_ui/lib/src/ui/painting.dart b/lib/web_ui/lib/src/ui/painting.dart index 1316783d4bcbb..c4014e44dee5f 100644 --- a/lib/web_ui/lib/src/ui/painting.dart +++ b/lib/web_ui/lib/src/ui/painting.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; // ignore: unused_element, Used in Shader assert. diff --git a/lib/web_ui/lib/src/ui/path.dart b/lib/web_ui/lib/src/ui/path.dart index f612de56d0228..0ee1486d2fb1e 100644 --- a/lib/web_ui/lib/src/ui/path.dart +++ b/lib/web_ui/lib/src/ui/path.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; abstract class Path { diff --git a/lib/web_ui/lib/src/ui/path_metrics.dart b/lib/web_ui/lib/src/ui/path_metrics.dart index b24856ef19865..fe0148e1bcccc 100644 --- a/lib/web_ui/lib/src/ui/path_metrics.dart +++ b/lib/web_ui/lib/src/ui/path_metrics.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; abstract class PathMetrics extends collection.IterableBase { diff --git a/lib/web_ui/lib/src/ui/platform_dispatcher.dart b/lib/web_ui/lib/src/ui/platform_dispatcher.dart index 1ec3fdb09da82..122e2befd336c 100644 --- a/lib/web_ui/lib/src/ui/platform_dispatcher.dart +++ b/lib/web_ui/lib/src/ui/platform_dispatcher.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; typedef VoidCallback = void Function(); diff --git a/lib/web_ui/lib/src/ui/pointer.dart b/lib/web_ui/lib/src/ui/pointer.dart index 0ad384b4d1209..5a4e55f8f6627 100644 --- a/lib/web_ui/lib/src/ui/pointer.dart +++ b/lib/web_ui/lib/src/ui/pointer.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; enum PointerChange { diff --git a/lib/web_ui/lib/src/ui/semantics.dart b/lib/web_ui/lib/src/ui/semantics.dart index 00d9d03a68879..eece4c7ae48f3 100644 --- a/lib/web_ui/lib/src/ui/semantics.dart +++ b/lib/web_ui/lib/src/ui/semantics.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; class SemanticsAction { diff --git a/lib/web_ui/lib/src/ui/test_embedding.dart b/lib/web_ui/lib/src/ui/test_embedding.dart index 7007ebf4420c2..4b99f329b35e8 100644 --- a/lib/web_ui/lib/src/ui/test_embedding.dart +++ b/lib/web_ui/lib/src/ui/test_embedding.dart @@ -4,7 +4,7 @@ // TODO(flutter_web): the Web-only API below need to be cleaned up. -// @dart = 2.10 +// @dart = 2.12 part of ui; Future? _testPlatformInitializedFuture; diff --git a/lib/web_ui/lib/src/ui/text.dart b/lib/web_ui/lib/src/ui/text.dart index fbf9321813116..2d9ef7d3b9ee1 100644 --- a/lib/web_ui/lib/src/ui/text.dart +++ b/lib/web_ui/lib/src/ui/text.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; enum FontStyle { diff --git a/lib/web_ui/lib/src/ui/tile_mode.dart b/lib/web_ui/lib/src/ui/tile_mode.dart index 567b9a551573b..45bce2e2f5a66 100644 --- a/lib/web_ui/lib/src/ui/tile_mode.dart +++ b/lib/web_ui/lib/src/ui/tile_mode.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; // These enum values must be kept in sync with SkShader::TileMode. diff --git a/lib/web_ui/lib/src/ui/window.dart b/lib/web_ui/lib/src/ui/window.dart index d3519f19b13d0..9966ef3617b4e 100644 --- a/lib/web_ui/lib/src/ui/window.dart +++ b/lib/web_ui/lib/src/ui/window.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 part of ui; abstract class FlutterView { diff --git a/lib/web_ui/lib/ui.dart b/lib/web_ui/lib/ui.dart index b616c223212d5..c64360fec5403 100644 --- a/lib/web_ui/lib/ui.dart +++ b/lib/web_ui/lib/ui.dart @@ -5,7 +5,7 @@ /// This library defines the web equivalent of the native dart:ui. /// /// All types in this library are public. -// @dart = 2.10 +// @dart = 2.12 library ui; import 'dart:async'; diff --git a/lib/web_ui/pubspec.yaml b/lib/web_ui/pubspec.yaml index 8116e434bab07..b85a59e194c67 100644 --- a/lib/web_ui/pubspec.yaml +++ b/lib/web_ui/pubspec.yaml @@ -2,7 +2,7 @@ name: ui publish_to: none environment: - sdk: ">=2.10.0-0 <3.0.0" + sdk: ">=2.12.0-0 <3.0.0" dependencies: js: 0.6.3-nullsafety.3 diff --git a/lib/web_ui/test/canvaskit/test_data.dart b/lib/web_ui/test/canvaskit/test_data.dart index 9ce6313d714ae..53043567ec987 100644 --- a/lib/web_ui/test/canvaskit/test_data.dart +++ b/lib/web_ui/test/canvaskit/test_data.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 import 'dart:typed_data'; diff --git a/lib/web_ui/test/engine/surface/path/path_winding_test.dart b/lib/web_ui/test/engine/surface/path/path_winding_test.dart index e7658e608c5cb..941da71343704 100644 --- a/lib/web_ui/test/engine/surface/path/path_winding_test.dart +++ b/lib/web_ui/test/engine/surface/path/path_winding_test.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 import 'dart:math' as math; import 'package:test/bootstrap/browser.dart'; // ignore: import_of_legacy_library_into_null_safe diff --git a/lib/web_ui/test/golden_tests/engine/color_filter_golden_test.dart b/lib/web_ui/test/golden_tests/engine/color_filter_golden_test.dart index ac34b1f1655a7..986ef9183949e 100644 --- a/lib/web_ui/test/golden_tests/engine/color_filter_golden_test.dart +++ b/lib/web_ui/test/golden_tests/engine/color_filter_golden_test.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 import 'dart:html' as html; import 'dart:js_util' as js_util; diff --git a/lib/web_ui/test/lerp_test.dart b/lib/web_ui/test/lerp_test.dart index e7a5d7ad7cb0e..1d458d3fa7d7a 100644 --- a/lib/web_ui/test/lerp_test.dart +++ b/lib/web_ui/test/lerp_test.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 import 'package:test/bootstrap/browser.dart'; // ignore: import_of_legacy_library_into_null_safe import 'package:test/test.dart'; // ignore: import_of_legacy_library_into_null_safe diff --git a/lib/web_ui/test/path_test.dart b/lib/web_ui/test/path_test.dart index 14bcd95e1fee9..da3d77397201f 100644 --- a/lib/web_ui/test/path_test.dart +++ b/lib/web_ui/test/path_test.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 import 'dart:js_util' as js_util; import 'dart:html' as html; diff --git a/lib/web_ui/test/text/canvas_paragraph_builder_test.dart b/lib/web_ui/test/text/canvas_paragraph_builder_test.dart index ecacd78b41d80..a0d0e4b8ccc1f 100644 --- a/lib/web_ui/test/text/canvas_paragraph_builder_test.dart +++ b/lib/web_ui/test/text/canvas_paragraph_builder_test.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 import 'package:test/bootstrap/browser.dart'; import 'package:test/test.dart'; import 'package:ui/src/engine.dart'; diff --git a/lib/web_ui/test/text/line_breaker_test.dart b/lib/web_ui/test/text/line_breaker_test.dart index 3d33d1a9854ce..e58b8e04895aa 100644 --- a/lib/web_ui/test/text/line_breaker_test.dart +++ b/lib/web_ui/test/text/line_breaker_test.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 import 'package:test/bootstrap/browser.dart'; // ignore: import_of_legacy_library_into_null_safe import 'package:test/test.dart'; // ignore: import_of_legacy_library_into_null_safe diff --git a/lib/web_ui/test/text/line_breaker_test_helper.dart b/lib/web_ui/test/text/line_breaker_test_helper.dart index 07a4229d23837..fb4aeb2b2b466 100644 --- a/lib/web_ui/test/text/line_breaker_test_helper.dart +++ b/lib/web_ui/test/text/line_breaker_test_helper.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 // The following test cases contradict rule LB25, so we are replacing them // with correct expectations. diff --git a/lib/web_ui/test/text/line_breaker_test_raw_data.dart b/lib/web_ui/test/text/line_breaker_test_raw_data.dart index 13b3e1e791f9a..863b6ca696ad0 100644 --- a/lib/web_ui/test/text/line_breaker_test_raw_data.dart +++ b/lib/web_ui/test/text/line_breaker_test_raw_data.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -// @dart = 2.10 +// @dart = 2.12 /// The list of test cases from: /// - https://www.unicode.org/Public/13.0.0/ucd/auxiliary/LineBreakTest.txt diff --git a/web_sdk/pubspec.yaml b/web_sdk/pubspec.yaml index d60237bea2e8c..f25f7ccb2f953 100644 --- a/web_sdk/pubspec.yaml +++ b/web_sdk/pubspec.yaml @@ -2,5 +2,5 @@ name: web_sdk_tests author: Flutter Authors dev_dependencies: - analyzer: ^0.39.15 + analyzer: ^0.40.6 test: any