| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #ifndef CHROME_BROWSER_UI_VIEWS_TOOLBAR_RELOAD_BUTTON_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_TOOLBAR_RELOAD_BUTTON_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_TOOLBAR_RELOAD_BUTTON_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_TOOLBAR_RELOAD_BUTTON_H_ |
| 7 | 7 |
| 8 #include "base/macros.h" | 8 #include "base/macros.h" |
| 9 #include "base/timer/timer.h" | 9 #include "base/timer/timer.h" |
| 10 #include "chrome/browser/ui/views/toolbar/toolbar_button.h" | 10 #include "chrome/browser/ui/views/toolbar/toolbar_button.h" |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 43 // Enable reload drop-down menu. | 43 // Enable reload drop-down menu. |
| 44 void set_menu_enabled(bool enable) { menu_enabled_ = enable; } | 44 void set_menu_enabled(bool enable) { menu_enabled_ = enable; } |
| 45 | 45 |
| 46 void LoadImages(); | 46 void LoadImages(); |
| 47 | 47 |
| 48 // ToolbarButton: | 48 // ToolbarButton: |
| 49 void OnMouseExited(const ui::MouseEvent& event) override; | 49 void OnMouseExited(const ui::MouseEvent& event) override; |
| 50 bool GetTooltipText(const gfx::Point& p, | 50 bool GetTooltipText(const gfx::Point& p, |
| 51 base::string16* tooltip) const override; | 51 base::string16* tooltip) const override; |
| 52 const char* GetClassName() const override; | 52 const char* GetClassName() const override; |
| 53 void GetAccessibleState(ui::AXViewState* state) override; | 53 void GetAccessibleNodeData(ui::AXNodeData* node_data) override; |
| 54 bool ShouldShowMenu() override; | 54 bool ShouldShowMenu() override; |
| 55 void ShowDropDownMenu(ui::MenuSourceType source_type) override; | 55 void ShowDropDownMenu(ui::MenuSourceType source_type) override; |
| 56 | 56 |
| 57 // views::ButtonListener: | 57 // views::ButtonListener: |
| 58 void ButtonPressed(views::Button* /* button */, | 58 void ButtonPressed(views::Button* /* button */, |
| 59 const ui::Event& event) override; | 59 const ui::Event& event) override; |
| 60 | 60 |
| 61 // ui::SimpleMenuModel::Delegate: | 61 // ui::SimpleMenuModel::Delegate: |
| 62 bool IsCommandIdChecked(int command_id) const override; | 62 bool IsCommandIdChecked(int command_id) const override; |
| 63 bool IsCommandIdEnabled(int command_id) const override; | 63 bool IsCommandIdEnabled(int command_id) const override; |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 101 // True if we should pretend the button is hovered. | 101 // True if we should pretend the button is hovered. |
| 102 bool testing_mouse_hovered_; | 102 bool testing_mouse_hovered_; |
| 103 // Increments when we would tell the browser to "reload", so | 103 // Increments when we would tell the browser to "reload", so |
| 104 // test code can tell whether we did so (as there may be no |browser_|). | 104 // test code can tell whether we did so (as there may be no |browser_|). |
| 105 int testing_reload_count_; | 105 int testing_reload_count_; |
| 106 | 106 |
| 107 DISALLOW_COPY_AND_ASSIGN(ReloadButton); | 107 DISALLOW_COPY_AND_ASSIGN(ReloadButton); |
| 108 }; | 108 }; |
| 109 | 109 |
| 110 #endif // CHROME_BROWSER_UI_VIEWS_TOOLBAR_RELOAD_BUTTON_H_ | 110 #endif // CHROME_BROWSER_UI_VIEWS_TOOLBAR_RELOAD_BUTTON_H_ |
| OLD | NEW |