OLD | NEW |
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 #include "chrome/browser/automation/ui_controls.h" | 5 #include "chrome/browser/automation/ui_controls.h" |
6 #include "chrome/test/base/view_event_test_base.h" | 6 #include "chrome/test/base/view_event_test_base.h" |
7 #include "ui/base/models/menu_model.h" | 7 #include "ui/base/models/menu_model.h" |
8 #include "views/controls/button/menu_button.h" | 8 #include "views/controls/button/menu_button.h" |
9 #include "views/controls/menu/menu_controller.h" | 9 #include "views/controls/menu/menu_controller.h" |
10 #include "views/controls/menu/menu_item_view.h" | 10 #include "views/controls/menu/menu_item_view.h" |
(...skipping 26 matching lines...) Expand all Loading... |
37 } | 37 } |
38 | 38 |
39 virtual views::View* GetDefaultParentView() OVERRIDE | 39 virtual views::View* GetDefaultParentView() OVERRIDE |
40 { | 40 { |
41 return NULL; | 41 return NULL; |
42 } | 42 } |
43 | 43 |
44 virtual void SaveWindowPlacement(const views::Widget* widget, | 44 virtual void SaveWindowPlacement(const views::Widget* widget, |
45 const std::wstring& window_name, | 45 const std::wstring& window_name, |
46 const gfx::Rect& bounds, | 46 const gfx::Rect& bounds, |
47 ui::WindowShowState show_state) OVERRIDE { | 47 bool maximized) OVERRIDE { |
48 } | 48 } |
49 | 49 |
50 virtual bool GetSavedWindowPlacement( | 50 virtual bool GetSavedWindowBounds(const std::wstring& window_name, |
51 const std::wstring& window_name, | 51 gfx::Rect* bounds) const OVERRIDE { |
52 gfx::Rect* bounds, | 52 return false; |
53 ui::WindowShowState* show_state) const OVERRIDE { | 53 } |
| 54 |
| 55 virtual bool GetSavedMaximizedState(const std::wstring& window_name, |
| 56 bool* maximized) const OVERRIDE { |
54 return false; | 57 return false; |
55 } | 58 } |
56 | 59 |
57 virtual void NotifyAccessibilityEvent( | 60 virtual void NotifyAccessibilityEvent( |
58 views::View* view, ui::AccessibilityTypes::Event event_type) OVERRIDE { | 61 views::View* view, ui::AccessibilityTypes::Event event_type) OVERRIDE { |
59 } | 62 } |
60 | 63 |
61 virtual void NotifyMenuItemFocused( | 64 virtual void NotifyMenuItemFocused( |
62 const std::wstring& menu_name, | 65 const std::wstring& menu_name, |
63 const std::wstring& menu_item_name, | 66 const std::wstring& menu_item_name, |
(...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
364 TestViewsDelegate views_delegate_; | 367 TestViewsDelegate views_delegate_; |
365 | 368 |
366 views::MenuButton* button_; | 369 views::MenuButton* button_; |
367 TopMenuModel top_menu_model_; | 370 TopMenuModel top_menu_model_; |
368 views::MenuModelAdapter menu_model_adapter_; | 371 views::MenuModelAdapter menu_model_adapter_; |
369 views::MenuItemView* menu_; | 372 views::MenuItemView* menu_; |
370 scoped_ptr<views::MenuRunner> menu_runner_; | 373 scoped_ptr<views::MenuRunner> menu_runner_; |
371 }; | 374 }; |
372 | 375 |
373 VIEW_TEST(MenuModelAdapterTest, RebuildMenu) | 376 VIEW_TEST(MenuModelAdapterTest, RebuildMenu) |
OLD | NEW |