| OLD | NEW |
| (Empty) |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef ASH_APP_LIST_APP_LIST_VIEW_DELEGATE_H_ | |
| 6 #define ASH_APP_LIST_APP_LIST_VIEW_DELEGATE_H_ | |
| 7 #pragma once | |
| 8 | |
| 9 #include <string> | |
| 10 | |
| 11 #include "ash/ash_export.h" | |
| 12 | |
| 13 namespace ash { | |
| 14 | |
| 15 class AppListItemModel; | |
| 16 class AppListModel; | |
| 17 | |
| 18 class ASH_EXPORT AppListViewDelegate { | |
| 19 public: | |
| 20 // AppListView owns the delegate. | |
| 21 virtual ~AppListViewDelegate() {} | |
| 22 | |
| 23 // Invoked to set the model that AppListView uses. | |
| 24 // Note that AppListView owns the model. | |
| 25 virtual void SetModel(AppListModel* model) = 0; | |
| 26 | |
| 27 // Invoked to ask the delegate to populate the model for given |query|. | |
| 28 virtual void UpdateModel(const std::string& query) = 0; | |
| 29 | |
| 30 // Invoked an AppListeItemModelView is activated by click or enter key. | |
| 31 virtual void OnAppListItemActivated(AppListItemModel* item, | |
| 32 int event_flags) = 0; | |
| 33 }; | |
| 34 | |
| 35 } // namespace ash | |
| 36 | |
| 37 #endif // ASH_APP_LIST_APP_LIST_VIEW_DELEGATE_H_ | |
| OLD | NEW |