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

Unified Diff: chrome/browser/ui/window_snapshot/window_snapshot.h

Issue 126373002: Make ChromeOS screenshots use async readback path (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 6 years, 11 months 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: chrome/browser/ui/window_snapshot/window_snapshot.h
diff --git a/chrome/browser/ui/window_snapshot/window_snapshot.h b/chrome/browser/ui/window_snapshot/window_snapshot.h
index cb681db739eb1cb3940ae43f8349fb3b135cf2ff..463b1b0a62ad53131eaad7d20c95c8218aaf05de 100644
--- a/chrome/browser/ui/window_snapshot/window_snapshot.h
+++ b/chrome/browser/ui/window_snapshot/window_snapshot.h
@@ -8,6 +8,7 @@
#include <vector>
#include "ui/gfx/native_widget_types.h"
+#include "ui/snapshot/snapshot.h"
class PrefRegistrySimple;
@@ -27,10 +28,15 @@ void RegisterScreenshotPrefs(PrefRegistrySimple* registry);
// by browser code. If you need to take a screenshot for debugging purposes,
// consider using ui::GrabWindowSnapshot.
// Returns true if the operation is successful (ie. permitted).
-bool GrabWindowSnapshotForUser(
+bool GrabWindowSnapshotForUser(gfx::NativeWindow window,
+ std::vector<unsigned char>* png_representation,
+ const gfx::Rect& snapshot_bounds);
+
+void GrabWindowSnapshotForUserAsync(
gfx::NativeWindow window,
- std::vector<unsigned char>* png_representation,
- const gfx::Rect& snapshot_bounds);
+ const gfx::Rect& snapshot_bounds,
+ scoped_refptr<base::TaskRunner> background_task_runner,
+ ui::GrabWindowSnapshotAsyncPNGCallback callback);
} // namespace chrome

Powered by Google App Engine
This is Rietveld 408576698