OLD | NEW |
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 #include "ui/gfx/gdi_util.h" | 5 #include "ui/gfx/gdi_util.h" |
6 | 6 |
| 7 #include <stddef.h> |
| 8 |
7 #include <algorithm> | 9 #include <algorithm> |
8 | 10 |
9 #include "base/logging.h" | 11 #include "base/logging.h" |
10 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
11 | 13 |
12 namespace { | 14 namespace { |
13 | 15 |
14 void CreateBitmapHeaderWithColorDepth(LONG width, | 16 void CreateBitmapHeaderWithColorDepth(LONG width, |
15 LONG height, | 17 LONG height, |
16 WORD color_depth, | 18 WORD color_depth, |
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
130 } else { | 132 } else { |
131 rv = ::StretchDIBits(hdc, | 133 rv = ::StretchDIBits(hdc, |
132 dest_x, dest_y, dest_w, dest_h, | 134 dest_x, dest_y, dest_w, dest_h, |
133 src_x, bottom_up_src_y, src_w, src_h, | 135 src_x, bottom_up_src_y, src_w, src_h, |
134 pixels, bitmap_info, DIB_RGB_COLORS, SRCCOPY); | 136 pixels, bitmap_info, DIB_RGB_COLORS, SRCCOPY); |
135 } | 137 } |
136 DCHECK(rv != static_cast<int>(GDI_ERROR)); | 138 DCHECK(rv != static_cast<int>(GDI_ERROR)); |
137 } | 139 } |
138 | 140 |
139 } // namespace gfx | 141 } // namespace gfx |
OLD | NEW |