| 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/button/menu_button.h" | 5 #include "ui/views/controls/button/menu_button.h" |
| 6 | 6 |
| 7 #include "base/utf_string_conversions.h" | 7 #include "base/utf_string_conversions.h" |
| 8 #include "grit/ui_resources.h" | 8 #include "grit/ui_resources.h" |
| 9 #include "grit/ui_strings.h" | 9 #include "grit/ui_strings.h" |
| 10 #include "ui/base/accessibility/accessible_view_state.h" | 10 #include "ui/base/accessibility/accessible_view_state.h" |
| (...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 259 state->default_action = l10n_util::GetStringUTF16(IDS_APP_ACCACTION_PRESS); | 259 state->default_action = l10n_util::GetStringUTF16(IDS_APP_ACCACTION_PRESS); |
| 260 state->state = ui::AccessibilityTypes::STATE_HASPOPUP; | 260 state->state = ui::AccessibilityTypes::STATE_HASPOPUP; |
| 261 } | 261 } |
| 262 | 262 |
| 263 int MenuButton::GetMaximumScreenXCoordinate() { | 263 int MenuButton::GetMaximumScreenXCoordinate() { |
| 264 if (!GetWidget()) { | 264 if (!GetWidget()) { |
| 265 NOTREACHED(); | 265 NOTREACHED(); |
| 266 return 0; | 266 return 0; |
| 267 } | 267 } |
| 268 | 268 |
| 269 gfx::Rect monitor_bounds = GetWidget()->GetWorkAreaScreenBounds(); | 269 gfx::Rect monitor_bounds = GetWidget()->GetWorkAreaBoundsInScreen(); |
| 270 return monitor_bounds.right() - 1; | 270 return monitor_bounds.right() - 1; |
| 271 } | 271 } |
| 272 | 272 |
| 273 } // namespace views | 273 } // namespace views |
| OLD | NEW |