From 0226fef0e6111a291a7e3724767063d8c5664c2f Mon Sep 17 00:00:00 2001 From: Chinmay Garde Date: Mon, 16 Oct 2017 16:43:43 -0700 Subject: [PATCH] Fix build breakage in the iOS software backend due to Skia update. (flutter/engine#4223) --- .../platform/darwin/ios/ios_surface_software.mm | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/engine/src/flutter/shell/platform/darwin/ios/ios_surface_software.mm b/engine/src/flutter/shell/platform/darwin/ios/ios_surface_software.mm index 06dc2c0bec..126759b287 100644 --- a/engine/src/flutter/shell/platform/darwin/ios/ios_surface_software.mm +++ b/engine/src/flutter/shell/platform/darwin/ios/ios_surface_software.mm @@ -82,7 +82,9 @@ bool IOSSurfaceSoftware::PresentBackingStore(sk_sp backing_store) { // Some basic sanity checking. uint64_t expected_pixmap_data_size = pixmap.width() * pixmap.height() * 4; - if (expected_pixmap_data_size != pixmap.getSize64()) { + const size_t pixmap_size = pixmap.computeByteSize(); + + if (expected_pixmap_data_size != pixmap_size) { return false; } @@ -90,10 +92,10 @@ bool IOSSurfaceSoftware::PresentBackingStore(sk_sp backing_store) { // Setup the data provider that gives CG a view into the pixmap. fml::CFRef pixmap_data_provider(CGDataProviderCreateWithData( - nullptr, // info - pixmap.addr32(), // data - pixmap.getSize64(), // size - nullptr // release callback + nullptr, // info + pixmap.addr32(), // data + pixmap_size, // size + nullptr // release callback )); if (!pixmap_data_provider) {