Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(85)

Unified Diff: ui/app_list/presenter/app_list.h

Issue 2647833003: Adds AppListDelegate to AppList that is notified on visibility changes (Closed)
Patch Set: fix Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/app_list/presenter/BUILD.gn ('k') | ui/app_list/presenter/app_list.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/app_list/presenter/app_list.h
diff --git a/ui/app_list/presenter/app_list.h b/ui/app_list/presenter/app_list.h
index fb4b8a22c04b666dd96a3cdfca9be9cb20e7708d..a5f76d3de67c08f4b3dcd559384f69ea973c8fdf 100644
--- a/ui/app_list/presenter/app_list.h
+++ b/ui/app_list/presenter/app_list.h
@@ -11,12 +11,16 @@
namespace app_list {
+class AppListDelegate;
+
// Stores the app list presenter interface pointer.
class APP_LIST_PRESENTER_EXPORT AppList : public mojom::AppList {
public:
AppList();
~AppList() override;
+ void set_delegate(AppListDelegate* delegate) { delegate_ = delegate; }
xiyuan 2017/01/20 17:20:49 nit: move accessor to the last of declarations sin
sky 2017/01/20 17:45:56 Done.
+
// Binds the mojom::AppList interface request to this object.
void BindRequest(mojom::AppListRequest request);
@@ -35,7 +39,7 @@ class APP_LIST_PRESENTER_EXPORT AppList : public mojom::AppList {
// mojom::AppList:
void SetAppListPresenter(mojom::AppListPresenterPtr presenter) override;
void OnTargetVisibilityChanged(bool visible) override;
- void OnVisibilityChanged(bool visible) override;
+ void OnVisibilityChanged(bool visible, int64_t display_id) override;
private:
// Bindings for the mojom::AppList interface.
@@ -48,6 +52,8 @@ class APP_LIST_PRESENTER_EXPORT AppList : public mojom::AppList {
bool target_visible_ = false;
bool visible_ = false;
+ AppListDelegate* delegate_ = nullptr;
+
DISALLOW_COPY_AND_ASSIGN(AppList);
};
« no previous file with comments | « ui/app_list/presenter/BUILD.gn ('k') | ui/app_list/presenter/app_list.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698