OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 "chrome/browser/drag_utils.h" | 5 #include "chrome/browser/drag_utils.h" |
6 | 6 |
7 #include <objidl.h> | 7 #include <objidl.h> |
8 #include <shlobj.h> | 8 #include <shlobj.h> |
9 #include <shobjidl.h> | 9 #include <shobjidl.h> |
10 | 10 |
| 11 #include "app/l10n_util.h" |
11 #include "app/resource_bundle.h" | 12 #include "app/resource_bundle.h" |
12 #include "base/file_util.h" | 13 #include "base/file_util.h" |
13 #include "base/gfx/gdi_util.h" | 14 #include "base/gfx/gdi_util.h" |
14 #include "base/gfx/point.h" | 15 #include "base/gfx/point.h" |
15 #include "base/string_util.h" | 16 #include "base/string_util.h" |
16 #include "chrome/browser/views/bookmark_bar_view.h" | 17 #include "chrome/browser/views/bookmark_bar_view.h" |
17 #include "chrome/common/gfx/chrome_canvas.h" | 18 #include "chrome/common/gfx/chrome_canvas.h" |
18 #include "chrome/common/gfx/chrome_font.h" | 19 #include "chrome/common/gfx/chrome_font.h" |
19 #include "chrome/common/l10n_util.h" | |
20 #include "chrome/common/os_exchange_data.h" | 20 #include "chrome/common/os_exchange_data.h" |
21 #include "chrome/common/win_util.h" | 21 #include "chrome/common/win_util.h" |
22 #include "chrome/views/controls/button/text_button.h" | 22 #include "chrome/views/controls/button/text_button.h" |
23 #include "googleurl/src/gurl.h" | 23 #include "googleurl/src/gurl.h" |
24 #include "grit/theme_resources.h" | 24 #include "grit/theme_resources.h" |
25 | 25 |
26 namespace drag_utils { | 26 namespace drag_utils { |
27 | 27 |
28 // Maximum width of the link drag image in pixels. | 28 // Maximum width of the link drag image in pixels. |
29 static const int kLinkDragImageMaxWidth = 200; | 29 static const int kLinkDragImageMaxWidth = 200; |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
152 HBITMAP bitmap = CreateBitmapFromCanvas(canvas, width, height); | 152 HBITMAP bitmap = CreateBitmapFromCanvas(canvas, width, height); |
153 | 153 |
154 // Attach 'bitmap' to the data_object. | 154 // Attach 'bitmap' to the data_object. |
155 SetDragImageOnDataObject(bitmap, width, height, | 155 SetDragImageOnDataObject(bitmap, width, height, |
156 cursor_x_offset, | 156 cursor_x_offset, |
157 cursor_y_offset, | 157 cursor_y_offset, |
158 data_object); | 158 data_object); |
159 } | 159 } |
160 | 160 |
161 } // namespace drag_utils | 161 } // namespace drag_utils |
OLD | NEW |