Skip to content

Commit 0dee3e5

Browse files
kjlubickmboetger
authored andcommitted
[skia] Update call to SkImage::makeSubset (flutter#172456)
In https://skia-review.googlesource.com/c/skia/+/1021216, Skia removed some legacy APIs. There was one usage still in Flutter and this fixes that. ## Pre-launch Checklist - [x] I read the [Contributor Guide] and followed the process outlined there for submitting PRs. - [x] I read the [Tree Hygiene] wiki page, which explains my responsibilities. - [x] I read and followed the [Flutter Style Guide], including [Features we expect every widget to implement]. - [x] I signed the [CLA]. - [x] I listed at least one issue that this PR fixes in the description above. - [x] I updated/added relevant documentation (doc comments with `///`). - [x] I added new tests to check the change I am making, or this PR is [test-exempt]. - [x] I followed the [breaking change policy] and added [Data Driven Fixes] where supported. - [ ] All existing and new tests are passing. If you need help, consider asking for advice on the #hackers-new channel on [Discord]. <!-- Links --> [Contributor Guide]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#overview [Tree Hygiene]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md [test-exempt]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#tests [Flutter Style Guide]: https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md [Features we expect every widget to implement]: https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md#features-we-expect-every-widget-to-implement [CLA]: https://cla.developers.google.com/ [flutter/tests]: https://github.com/flutter/tests [breaking change policy]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#handling-breaking-changes [Discord]: https://github.com/flutter/flutter/blob/main/docs/contributing/Chat.md [Data Driven Fixes]: https://github.com/flutter/flutter/blob/main/docs/contributing/Data-driven-Fixes.md
1 parent 69d568a commit 0dee3e5

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

engine/src/flutter/shell/platform/embedder/tests/embedder_unittests_util.cc

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
#include "flutter/shell/platform/embedder/tests/embedder_test_backingstore_producer.h"
1111
#include "flutter/shell/platform/embedder/tests/embedder_unittests_util.h"
1212

13+
#include "third_party/skia/include/core/SkCPURecorder.h"
1314
#include "third_party/skia/include/core/SkImage.h"
1415
#include "third_party/skia/include/core/SkSurface.h"
1516
#include "third_party/skia/include/encode/SkPngEncoder.h"
@@ -168,8 +169,8 @@ bool ImageMatchesFixture(const std::string& fixture_file_name,
168169
FML_CHECK(scene_image) << "Invalid scene image.";
169170

170171
auto scene_image_subset = scene_image->makeSubset(
171-
nullptr,
172-
SkIRect::MakeWH(fixture_image->width(), fixture_image->height()));
172+
skcpu::Recorder::TODO(),
173+
SkIRect::MakeWH(fixture_image->width(), fixture_image->height()), {});
173174

174175
FML_CHECK(scene_image_subset)
175176
<< "Could not create image subset for fixture comparison: "

0 commit comments

Comments
 (0)