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 "chrome/browser/task_manager/task_manager.h" | 5 #include "chrome/browser/task_manager/task_manager.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
190 ui::MenuSourceType source_type) override; | 190 ui::MenuSourceType source_type) override; |
191 | 191 |
192 // ui::SimpleMenuModel::Delegate: | 192 // ui::SimpleMenuModel::Delegate: |
193 bool IsCommandIdChecked(int id) const override; | 193 bool IsCommandIdChecked(int id) const override; |
194 bool IsCommandIdEnabled(int id) const override; | 194 bool IsCommandIdEnabled(int id) const override; |
195 bool GetAcceleratorForCommandId(int command_id, | 195 bool GetAcceleratorForCommandId(int command_id, |
196 ui::Accelerator* accelerator) override; | 196 ui::Accelerator* accelerator) override; |
197 void ExecuteCommand(int id, int event_flags) override; | 197 void ExecuteCommand(int id, int event_flags) override; |
198 | 198 |
199 private: | 199 private: |
| 200 friend class TaskManagerTester; |
| 201 |
200 // Creates the child controls. | 202 // Creates the child controls. |
201 void Init(); | 203 void Init(); |
202 | 204 |
203 // Initializes the state of the always-on-top setting as the window is shown. | 205 // Initializes the state of the always-on-top setting as the window is shown. |
204 void InitAlwaysOnTopState(); | 206 void InitAlwaysOnTopState(); |
205 | 207 |
206 // Activates the tab associated with the focused row. | 208 // Activates the tab associated with the focused row. |
207 void ActivateFocusedTab(); | 209 void ActivateFocusedTab(); |
208 | 210 |
209 // Restores saved always on top state from a previous session. | 211 // Restores saved always on top state from a previous session. |
(...skipping 415 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
625 void HideTaskManager() { | 627 void HideTaskManager() { |
626 if (switches::NewTaskManagerEnabled()) { | 628 if (switches::NewTaskManagerEnabled()) { |
627 task_management::NewTaskManagerView::Hide(); | 629 task_management::NewTaskManagerView::Hide(); |
628 return; | 630 return; |
629 } | 631 } |
630 | 632 |
631 TaskManagerView::Hide(); | 633 TaskManagerView::Hide(); |
632 } | 634 } |
633 | 635 |
634 } // namespace chrome | 636 } // namespace chrome |
OLD | NEW |