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

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

Issue 11399002: Implemented GetWindowSnapshot on RenderViewImpl (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fixed aura snapshot circular dependency Created 8 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: chrome/browser/ui/window_snapshot/window_snapshot_aura.h
diff --git a/chrome/browser/ui/window_snapshot/window_snapshot_aura.h b/chrome/browser/ui/window_snapshot/window_snapshot_aura.h
new file mode 100644
index 0000000000000000000000000000000000000000..9b967b3335c2232525fc7cff6a8dd147b1bd8bba
--- /dev/null
+++ b/chrome/browser/ui/window_snapshot/window_snapshot_aura.h
@@ -0,0 +1,30 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_UI_WINDOW_SNAPSHOT_WINDOW_SNAPSHOT_AURA_H_
+#define CHROME_BROWSER_UI_WINDOW_SNAPSHOT_WINDOW_SNAPSHOT_AURA_H_
+
+#include <vector>
+
+#include "ui/aura/window.h"
+
+namespace gfx {
+class Rect;
+}
+
+namespace chrome {
+
+// Grabs a snapshot of the aura window from the compositor backbuffer. This
+// differs from the behavior of ui:GrabWindowSnapshot in that the image returned
+// may differ from the one presented to the screen. As such, this function is
+// not appropriate for rendering validation.
+// Returns true if the operation is successful (ie. permitted).
+bool GrabAuraCompositorSnapshot(
+ aura::Window* window,
+ std::vector<unsigned char>* png_representation,
+ const gfx::Rect& snapshot_bounds);
+
+} // namespace chrome
+
+#endif // CHROME_BROWSER_UI_WINDOW_SNAPSHOT_WINDOW_SNAPSHOT_AURA_H_

Powered by Google App Engine
This is Rietveld 408576698