Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(368)

Unified Diff: content/browser/android/content_view_core_impl.cc

Issue 593503003: Support error handling for Surface readbacks (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Formatted code and fixed build issue in test. Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/browser/android/content_view_core_impl.cc
diff --git a/content/browser/android/content_view_core_impl.cc b/content/browser/android/content_view_core_impl.cc
index 9aa69cdf7daa3a7578068240ec0373366ffd46e7..f999d7a1adbb4f1c0075f5939adb058b46ac5ddc 100644
--- a/content/browser/android/content_view_core_impl.cc
+++ b/content/browser/android/content_view_core_impl.cc
@@ -633,10 +633,10 @@ void ContentViewCoreImpl::GetScaledContentBitmap(
float scale,
SkColorType color_type,
gfx::Rect src_subrect,
- const base::Callback<void(bool, const SkBitmap&)>& result_callback) {
+ ReadbackRequestCallback& result_callback) {
RenderWidgetHostViewAndroid* view = GetRenderWidgetHostViewAndroid();
if (!view) {
- result_callback.Run(false, SkBitmap());
+ result_callback.Run(SkBitmap(), READBACK_FAILED);
return;
}

Powered by Google App Engine
This is Rietveld 408576698