Update path of checkdeps to buildtools checkout
[chromium-blink-merge.git] / ui / app_list / views / start_page_view.h
blob89d27a57171f7914578668eee21fd33e8233ff5b
1 // Copyright 2014 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.
5 #ifndef UI_APP_LIST_VIEWS_START_PAGE_VIEW_H_
6 #define UI_APP_LIST_VIEWS_START_PAGE_VIEW_H_
8 #include "base/basictypes.h"
9 #include "ui/app_list/app_list_model_observer.h"
10 #include "ui/app_list/app_list_view_delegate_observer.h"
11 #include "ui/views/controls/button/button.h"
12 #include "ui/views/view.h"
14 namespace content {
15 class WebContents;
18 namespace app_list {
20 class AppListMainView;
21 class AppListModel;
22 class AppListViewDelegate;
23 class TileItemView;
25 // The start page for the experimental app list.
26 class StartPageView : public views::View,
27 public views::ButtonListener,
28 public AppListViewDelegateObserver,
29 public AppListModelObserver {
30 public:
31 StartPageView(AppListMainView* app_list_main_view,
32 AppListViewDelegate* view_delegate);
33 virtual ~StartPageView();
35 void Reset();
37 const std::vector<TileItemView*>& tile_views() const { return tile_views_; }
39 private:
40 void SetModel(AppListModel* model);
42 // Overridden from views::ButtonListener:
43 virtual void ButtonPressed(views::Button* sender,
44 const ui::Event& event) OVERRIDE;
46 // Overridden from AppListViewDelegateObserver:
47 virtual void OnProfilesChanged() OVERRIDE;
49 // Overridden from AppListModelObserver:
50 virtual void OnAppListModelStatusChanged() OVERRIDE;
51 virtual void OnAppListItemAdded(AppListItem* item) OVERRIDE;
52 virtual void OnAppListItemDeleted() OVERRIDE;
53 virtual void OnAppListItemUpdated(AppListItem* item) OVERRIDE;
55 // The parent view of ContentsView which is the parent of this view.
56 AppListMainView* app_list_main_view_;
58 AppListModel* model_; // Owned by AppListSyncableService.
60 AppListViewDelegate* view_delegate_; // Owned by AppListView.
62 views::View* instant_container_; // Owned by views hierarchy.
63 views::View* tiles_container_; // Owned by views hierarchy.
65 std::vector<TileItemView*> tile_views_;
67 DISALLOW_COPY_AND_ASSIGN(StartPageView);
70 } // namespace app_list
72 #endif // UI_APP_LIST_VIEWS_START_PAGE_VIEW_H_