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

Side by Side Diff: content/renderer/browser_plugin/browser_plugin_backing_store.h

Issue 12207144: Apply merge from @fsamuel. (Closed) Base URL: svn://svn.chromium.org/chrome/branches/1364/src/
Patch Set: Created 7 years, 10 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_BACKING_STORE_H__ 5 #ifndef CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_BACKING_STORE_H__
6 #define CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_BACKING_STORE_H__ 6 #define CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_BACKING_STORE_H__
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 20 matching lines...) Expand all
31 // These are called in response to changes in the guest relayed via 31 // These are called in response to changes in the guest relayed via
32 // BrowserPluginMsg_UpdateRect. See BrowserPlugin::UpdateRect. 32 // BrowserPluginMsg_UpdateRect. See BrowserPlugin::UpdateRect.
33 class BrowserPluginBackingStore { 33 class BrowserPluginBackingStore {
34 public: 34 public:
35 BrowserPluginBackingStore(const gfx::Size& size, float scale_factor); 35 BrowserPluginBackingStore(const gfx::Size& size, float scale_factor);
36 virtual ~BrowserPluginBackingStore(); 36 virtual ~BrowserPluginBackingStore();
37 37
38 void PaintToBackingStore( 38 void PaintToBackingStore(
39 const gfx::Rect& bitmap_rect, 39 const gfx::Rect& bitmap_rect,
40 const std::vector<gfx::Rect>& copy_rects, 40 const std::vector<gfx::Rect>& copy_rects,
41 TransportDIB* dib); 41 void* bitmap);
42 42
43 void ScrollBackingStore(const gfx::Vector2d& delta, 43 void ScrollBackingStore(const gfx::Vector2d& delta,
44 const gfx::Rect& clip_rect, 44 const gfx::Rect& clip_rect,
45 const gfx::Size& view_size); 45 const gfx::Size& view_size);
46 46
47 void Clear(SkColor clear_color); 47 void Clear(SkColor clear_color);
48 48
49 const gfx::Size& GetSize() const { return size_; } 49 const gfx::Size& GetSize() const { return size_; }
50 50
51 const SkBitmap& GetBitmap() const { return bitmap_; } 51 const SkBitmap& GetBitmap() const { return bitmap_; }
52 52
53 float GetScaleFactor() const { return scale_factor_; } 53 float GetScaleFactor() const { return scale_factor_; }
54 54
55 private: 55 private:
56 gfx::Size size_; 56 gfx::Size size_;
57 SkBitmap bitmap_; 57 SkBitmap bitmap_;
58 scoped_ptr<SkCanvas> canvas_; 58 scoped_ptr<SkCanvas> canvas_;
59 float scale_factor_; 59 float scale_factor_;
60 60
61 DISALLOW_COPY_AND_ASSIGN(BrowserPluginBackingStore); 61 DISALLOW_COPY_AND_ASSIGN(BrowserPluginBackingStore);
62 }; 62 };
63 63
64 } // namespace content 64 } // namespace content
65 65
66 #endif // CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_BACKING_STORE_H__ 66 #endif // CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_BACKING_STORE_H__
OLDNEW
« no previous file with comments | « content/renderer/browser_plugin/browser_plugin.cc ('k') | content/renderer/browser_plugin/browser_plugin_backing_store.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698