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/views/controls/menu/menu_controller.h" | 5 #include "ui/views/controls/menu/menu_controller.h" |
6 | 6 |
7 #include "base/i18n/case_conversion.h" | 7 #include "base/i18n/case_conversion.h" |
8 #include "base/i18n/rtl.h" | 8 #include "base/i18n/rtl.h" |
9 #include "base/strings/utf_string_conversions.h" | 9 #include "base/strings/utf_string_conversions.h" |
10 #include "base/time/time.h" | 10 #include "base/time/time.h" |
11 #include "ui/base/dragdrop/drag_utils.h" | 11 #include "ui/base/dragdrop/drag_utils.h" |
12 #include "ui/base/dragdrop/os_exchange_data.h" | 12 #include "ui/base/dragdrop/os_exchange_data.h" |
13 #include "ui/base/l10n/l10n_util.h" | 13 #include "ui/base/l10n/l10n_util.h" |
14 #include "ui/events/event.h" | 14 #include "ui/events/event.h" |
15 #include "ui/events/event_utils.h" | 15 #include "ui/events/event_utils.h" |
16 #include "ui/gfx/canvas.h" | 16 #include "ui/gfx/canvas.h" |
| 17 #include "ui/gfx/geometry/point.h" |
| 18 #include "ui/gfx/geometry/vector2d.h" |
17 #include "ui/gfx/native_widget_types.h" | 19 #include "ui/gfx/native_widget_types.h" |
18 #include "ui/gfx/point.h" | |
19 #include "ui/gfx/screen.h" | 20 #include "ui/gfx/screen.h" |
20 #include "ui/gfx/vector2d.h" | |
21 #include "ui/native_theme/native_theme.h" | 21 #include "ui/native_theme/native_theme.h" |
22 #include "ui/views/controls/button/menu_button.h" | 22 #include "ui/views/controls/button/menu_button.h" |
23 #include "ui/views/controls/menu/menu_config.h" | 23 #include "ui/views/controls/menu/menu_config.h" |
24 #include "ui/views/controls/menu/menu_controller_delegate.h" | 24 #include "ui/views/controls/menu/menu_controller_delegate.h" |
25 #include "ui/views/controls/menu/menu_host_root_view.h" | 25 #include "ui/views/controls/menu/menu_host_root_view.h" |
26 #include "ui/views/controls/menu/menu_item_view.h" | 26 #include "ui/views/controls/menu/menu_item_view.h" |
27 #include "ui/views/controls/menu/menu_message_loop.h" | 27 #include "ui/views/controls/menu/menu_message_loop.h" |
28 #include "ui/views/controls/menu/menu_scroll_view_container.h" | 28 #include "ui/views/controls/menu/menu_scroll_view_container.h" |
29 #include "ui/views/controls/menu/submenu_view.h" | 29 #include "ui/views/controls/menu/submenu_view.h" |
30 #include "ui/views/drag_utils.h" | 30 #include "ui/views/drag_utils.h" |
(...skipping 2268 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2299 } | 2299 } |
2300 } | 2300 } |
2301 | 2301 |
2302 gfx::Screen* MenuController::GetScreen() { | 2302 gfx::Screen* MenuController::GetScreen() { |
2303 Widget* root = owner_ ? owner_->GetTopLevelWidget() : NULL; | 2303 Widget* root = owner_ ? owner_->GetTopLevelWidget() : NULL; |
2304 return root ? gfx::Screen::GetScreenFor(root->GetNativeView()) | 2304 return root ? gfx::Screen::GetScreenFor(root->GetNativeView()) |
2305 : gfx::Screen::GetNativeScreen(); | 2305 : gfx::Screen::GetNativeScreen(); |
2306 } | 2306 } |
2307 | 2307 |
2308 } // namespace views | 2308 } // namespace views |
OLD | NEW |