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 UI_APP_LIST_VIEWS_FOLDER_HEADER_VIEW_DELEGATE_H_ | 5 #ifndef UI_APP_LIST_VIEWS_FOLDER_HEADER_VIEW_DELEGATE_H_ |
6 #define UI_APP_LIST_VIEWS_FOLDER_HEADER_VIEW_DELEGATE_H_ | 6 #define UI_APP_LIST_VIEWS_FOLDER_HEADER_VIEW_DELEGATE_H_ |
7 | 7 |
8 namespace app_list { | 8 namespace app_list { |
9 | 9 |
10 class AppListFolderItem; | 10 class AppListFolderItem; |
11 | 11 |
12 class FolderHeaderViewDelegate { | 12 class FolderHeaderViewDelegate { |
13 public: | 13 public: |
14 // Invoked when the back button on the folder header view is clicked. | 14 // Invoked when the back button on the folder header view is clicked. |
15 // |item| is the folder item which FolderHeaderview represents. | 15 // |item| is the folder item which FolderHeaderview represents. |
16 // |event_flags| contains the flags of the keyboard/mouse event that triggers | 16 // |event_flags| contains the flags of the keyboard/mouse event that triggers |
17 // the request. | 17 // the request. |
18 virtual void NavigateBack(AppListFolderItem* item, | 18 virtual void NavigateBack(AppListFolderItem* item, |
19 const ui::Event& event_flags) = 0; | 19 const ui::Event& event_flags) = 0; |
20 | 20 |
21 // Gives back the focus to the search box. | 21 // Gives back the focus to the search box. |
22 virtual void GiveBackFocusToSearchBox() = 0; | 22 virtual void GiveBackFocusToSearchBox() = 0; |
23 | 23 |
24 // Tells the model to set the name of |item|. | 24 // Tells the model to set the name of |item|. |
25 virtual void SetItemName(AppListFolderItem* item, | 25 virtual void SetItemName(AppListFolderItem* item, |
26 const std::string& name) = 0; | 26 const std::string& name) = 0; |
27 | 27 |
28 protected: | |
29 virtual ~FolderHeaderViewDelegate() {} | 28 virtual ~FolderHeaderViewDelegate() {} |
30 }; | 29 }; |
31 | 30 |
32 } // namespace app_list | 31 } // namespace app_list |
33 | 32 |
34 #endif // UI_APP_LIST_VIEWS_FOLDER_HEADER_VIEW_DELEGATE_H_ | 33 #endif // UI_APP_LIST_VIEWS_FOLDER_HEADER_VIEW_DELEGATE_H_ |
OLD | NEW |