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

Side by Side Diff: content/browser/renderer_host/backing_store_win.h

Issue 10540144: Tag TransportDIBs with the device scale factor they expect. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: comments Created 8 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_BROWSER_RENDERER_HOST_BACKING_STORE_WIN_H_ 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_BACKING_STORE_WIN_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_BACKING_STORE_WIN_H_ 6 #define CONTENT_BROWSER_RENDERER_HOST_BACKING_STORE_WIN_H_
7 #pragma once 7 #pragma once
8 8
9 #include <windows.h> 9 #include <windows.h>
10 10
(...skipping 11 matching lines...) Expand all
22 // Returns true if we should convert to the monitor profile when painting. 22 // Returns true if we should convert to the monitor profile when painting.
23 static bool ColorManagementEnabled(); 23 static bool ColorManagementEnabled();
24 24
25 // BackingStore implementation. 25 // BackingStore implementation.
26 virtual size_t MemorySize() OVERRIDE; 26 virtual size_t MemorySize() OVERRIDE;
27 virtual void PaintToBackingStore( 27 virtual void PaintToBackingStore(
28 content::RenderProcessHost* process, 28 content::RenderProcessHost* process,
29 TransportDIB::Id bitmap, 29 TransportDIB::Id bitmap,
30 const gfx::Rect& bitmap_rect, 30 const gfx::Rect& bitmap_rect,
31 const std::vector<gfx::Rect>& copy_rects, 31 const std::vector<gfx::Rect>& copy_rects,
32 float scale_factor,
32 const base::Closure& completion_callback, 33 const base::Closure& completion_callback,
33 bool* scheduled_completion_callback) OVERRIDE; 34 bool* scheduled_completion_callback) OVERRIDE;
34 virtual bool CopyFromBackingStore(const gfx::Rect& rect, 35 virtual bool CopyFromBackingStore(const gfx::Rect& rect,
35 skia::PlatformCanvas* output) OVERRIDE; 36 skia::PlatformCanvas* output) OVERRIDE;
36 virtual void ScrollBackingStore(int dx, int dy, 37 virtual void ScrollBackingStore(int dx, int dy,
37 const gfx::Rect& clip_rect, 38 const gfx::Rect& clip_rect,
38 const gfx::Size& view_size) OVERRIDE; 39 const gfx::Size& view_size) OVERRIDE;
39 40
40 private: 41 private:
41 // The backing store dc. 42 // The backing store dc.
42 HDC hdc_; 43 HDC hdc_;
43 44
44 // Handle to the backing store dib. 45 // Handle to the backing store dib.
45 HANDLE backing_store_dib_; 46 HANDLE backing_store_dib_;
46 47
47 // Handle to the original bitmap in the dc. 48 // Handle to the original bitmap in the dc.
48 HANDLE original_bitmap_; 49 HANDLE original_bitmap_;
49 50
50 // Number of bits per pixel of the screen. 51 // Number of bits per pixel of the screen.
51 int color_depth_; 52 int color_depth_;
52 53
53 DISALLOW_COPY_AND_ASSIGN(BackingStoreWin); 54 DISALLOW_COPY_AND_ASSIGN(BackingStoreWin);
54 }; 55 };
55 56
56 #endif // CONTENT_BROWSER_RENDERER_HOST_BACKING_STORE_WIN_H_ 57 #endif // CONTENT_BROWSER_RENDERER_HOST_BACKING_STORE_WIN_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698