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

Unified Diff: chrome/browser/renderer_host/backing_store.h

Issue 126101: Adds kind-of-live thumbnail generation for a potential tab switcher. (Closed)
Patch Set: For Checking hopefully Created 11 years, 6 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
« no previous file with comments | « chrome/browser/profile.cc ('k') | chrome/browser/renderer_host/backing_store_mac.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/renderer_host/backing_store.h
diff --git a/chrome/browser/renderer_host/backing_store.h b/chrome/browser/renderer_host/backing_store.h
index 5d817d0383f0cc1dde23d907086badd4ddc8ce1c..0fb47ab9039fb7b9db0f81b8680973e0cb627416 100644
--- a/chrome/browser/renderer_host/backing_store.h
+++ b/chrome/browser/renderer_host/backing_store.h
@@ -21,6 +21,7 @@
#endif
class RenderWidgetHost;
+class SkBitmap;
class TransportDIB;
// BackingStore ----------------------------------------------------------------
@@ -29,31 +30,31 @@ class TransportDIB;
class BackingStore {
public:
#if defined(OS_WIN) || defined(OS_MACOSX)
- explicit BackingStore(const gfx::Size& size);
+ BackingStore(RenderWidgetHost* widget, const gfx::Size& size);
#elif defined(OS_LINUX)
- // Create a backing store on the X server.
- // size: the size of the server-side pixmap
- // x_connection: the display to target
- // depth: the depth of the X window which will be drawn into
- // visual: An Xlib Visual describing the format of the target window
- // root_window: The X id of the root window
- // use_render: if true, the X server supports Xrender
- // use_shared_memory: if true, the X server is local
- BackingStore(const gfx::Size& size, Display* x_connection, int depth,
- void* visual, XID root_window, bool use_render,
- bool use_shared_memory);
+ // Create a backing store on the X server. The visual is an Xlib Visual
+ // describing the format of the target window and the depth is the color
+ // depth of the X window which will be drawn into.
+ BackingStore(RenderWidgetHost* widget,
+ const gfx::Size& size,
+ void* visual,
+ int depth);
+
// This is for unittesting only. An object constructed using this constructor
// will silently ignore all paints
- explicit BackingStore(const gfx::Size& size);
+ BackingStore(RenderWidgetHost* widget, const gfx::Size& size);
#endif
~BackingStore();
+ RenderWidgetHost* render_widget_host() const { return render_widget_host_; }
const gfx::Size& size() { return size_; }
#if defined(OS_WIN)
HDC hdc() { return hdc_; }
+
#elif defined(OS_MACOSX)
skia::PlatformCanvas* canvas() { return &canvas_; }
+
#elif defined(OS_LINUX)
// Copy from the server-side backing store to the target window
// display: the display of the backing store and target window
@@ -77,6 +78,9 @@ class BackingStore {
const gfx::Size& view_size);
private:
+ // The owner of this backing store.
+ RenderWidgetHost* render_widget_host_;
+
// The size of the backing store.
gfx::Size size_;
« no previous file with comments | « chrome/browser/profile.cc ('k') | chrome/browser/renderer_host/backing_store_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698