Index: ash/app_list/app_list_view.h |
diff --git a/ash/app_list/app_list_view.h b/ash/app_list/app_list_view.h |
index 17bfceca4c1834be5563ba58b2bb372fe81af860..edd2a0a38ae4ee255dbeaf746e551f80443c8c6a 100644 |
--- a/ash/app_list/app_list_view.h |
+++ b/ash/app_list/app_list_view.h |
@@ -6,9 +6,9 @@ |
#define ASH_APP_LIST_APP_LIST_VIEW_H_ |
#pragma once |
-#include "ash/app_list/app_list_item_view_listener.h" |
#include "ash/ash_export.h" |
#include "base/memory/scoped_ptr.h" |
+#include "ui/views/controls/button/button.h" |
#include "ui/views/widget/widget_delegate.h" |
namespace views { |
@@ -18,16 +18,17 @@ class View; |
namespace ash { |
class AppListModel; |
+class AppListModelView; |
class AppListViewDelegate; |
+class SearchBoxView; |
// AppListView is the top-level view and controller of app list UI. It creates |
// and hosts a AppListModelView and passes AppListModel to it for display. |
class ASH_EXPORT AppListView : public views::WidgetDelegateView, |
- public AppListItemViewListener { |
+ public views::ButtonListener { |
public: |
- // Takes ownership of |model| and |delegate|. |
- AppListView(AppListModel* model, |
- AppListViewDelegate* delegate, |
+ // Takes ownership of |delegate|. |
+ AppListView(AppListViewDelegate* delegate, |
const gfx::Rect& bounds); |
virtual ~AppListView(); |
@@ -38,18 +39,28 @@ class ASH_EXPORT AppListView : public views::WidgetDelegateView, |
// Initializes the window. |
void Init(const gfx::Rect& bounds); |
+ // Updates model using query text in search box. |
+ void UpdateModel(); |
+ |
+ // Overridden from views::WidgetDelegateView: |
+ virtual views::View* GetInitiallyFocusedView() OVERRIDE; |
+ |
// Overridden from views::View: |
+ virtual void Layout() OVERRIDE; |
virtual bool OnKeyPressed(const views::KeyEvent& event) OVERRIDE; |
virtual bool OnMousePressed(const views::MouseEvent& event) OVERRIDE; |
- // Overridden from AppListItemModelViewListener: |
- virtual void AppListItemActivated(AppListItemView* sender, |
- int event_flags) OVERRIDE; |
+ // Overridden from views::ButtonListener: |
+ virtual void ButtonPressed(views::Button* sender, |
+ const views::Event& event) OVERRIDE; |
scoped_ptr<AppListModel> model_; |
scoped_ptr<AppListViewDelegate> delegate_; |
+ SearchBoxView* search_box_view_; |
+ AppListModelView* model_view_; |
+ |
DISALLOW_COPY_AND_ASSIGN(AppListView); |
}; |