OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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 CHROME_BROWSER_UI_APP_LIST_APP_LIST_VIEW_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_UI_APP_LIST_APP_LIST_VIEW_DELEGATE_H_ |
6 #define CHROME_BROWSER_UI_APP_LIST_APP_LIST_VIEW_DELEGATE_H_ | 6 #define CHROME_BROWSER_UI_APP_LIST_APP_LIST_VIEW_DELEGATE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 13 matching lines...) Expand all Loading... |
24 #include "ui/app_list/app_list_view_delegate.h" | 24 #include "ui/app_list/app_list_view_delegate.h" |
25 | 25 |
26 class AppListControllerDelegate; | 26 class AppListControllerDelegate; |
27 class Profile; | 27 class Profile; |
28 | 28 |
29 namespace apps { | 29 namespace apps { |
30 class CustomLauncherPageContents; | 30 class CustomLauncherPageContents; |
31 } | 31 } |
32 | 32 |
33 namespace app_list { | 33 namespace app_list { |
| 34 class LauncherPageEventDispatcher; |
34 class SearchController; | 35 class SearchController; |
35 class SearchResourceManager; | 36 class SearchResourceManager; |
36 class SpeechUIModel; | 37 class SpeechUIModel; |
37 } | 38 } |
38 | 39 |
39 namespace base { | 40 namespace base { |
40 class FilePath; | 41 class FilePath; |
41 } | 42 } |
42 | 43 |
43 namespace gfx { | 44 namespace gfx { |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
89 gfx::ImageSkia GetWindowIcon() override; | 90 gfx::ImageSkia GetWindowIcon() override; |
90 void OpenSettings() override; | 91 void OpenSettings() override; |
91 void OpenHelp() override; | 92 void OpenHelp() override; |
92 void OpenFeedback() override; | 93 void OpenFeedback() override; |
93 void ToggleSpeechRecognition() override; | 94 void ToggleSpeechRecognition() override; |
94 void ShowForProfileByPath(const base::FilePath& profile_path) override; | 95 void ShowForProfileByPath(const base::FilePath& profile_path) override; |
95 #if defined(TOOLKIT_VIEWS) | 96 #if defined(TOOLKIT_VIEWS) |
96 views::View* CreateStartPageWebView(const gfx::Size& size) override; | 97 views::View* CreateStartPageWebView(const gfx::Size& size) override; |
97 std::vector<views::View*> CreateCustomPageWebViews( | 98 std::vector<views::View*> CreateCustomPageWebViews( |
98 const gfx::Size& size) override; | 99 const gfx::Size& size) override; |
| 100 void CustomLauncherPageAnimationChanged(double progress) override; |
99 #endif | 101 #endif |
100 bool IsSpeechRecognitionEnabled() override; | 102 bool IsSpeechRecognitionEnabled() override; |
101 const Users& GetUsers() const override; | 103 const Users& GetUsers() const override; |
102 bool ShouldCenterWindow() const override; | 104 bool ShouldCenterWindow() const override; |
103 void AddObserver(app_list::AppListViewDelegateObserver* observer) override; | 105 void AddObserver(app_list::AppListViewDelegateObserver* observer) override; |
104 void RemoveObserver(app_list::AppListViewDelegateObserver* observer) override; | 106 void RemoveObserver(app_list::AppListViewDelegateObserver* observer) override; |
105 | 107 |
106 private: | 108 private: |
107 // Updates the speech webview and start page for the current |profile_|. | 109 // Updates the speech webview and start page for the current |profile_|. |
108 void SetUpSearchUI(); | 110 void SetUpSearchUI(); |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
155 // Unowned pointer to the model owned by AppListSyncableService. Will change | 157 // Unowned pointer to the model owned by AppListSyncableService. Will change |
156 // if |profile_| changes. | 158 // if |profile_| changes. |
157 app_list::AppListModel* model_; | 159 app_list::AppListModel* model_; |
158 | 160 |
159 // Note: order ensures |search_resource_manager_| is destroyed before | 161 // Note: order ensures |search_resource_manager_| is destroyed before |
160 // |speech_ui_|. | 162 // |speech_ui_|. |
161 scoped_ptr<app_list::SpeechUIModel> speech_ui_; | 163 scoped_ptr<app_list::SpeechUIModel> speech_ui_; |
162 scoped_ptr<app_list::SearchResourceManager> search_resource_manager_; | 164 scoped_ptr<app_list::SearchResourceManager> search_resource_manager_; |
163 scoped_ptr<app_list::SearchController> search_controller_; | 165 scoped_ptr<app_list::SearchController> search_controller_; |
164 | 166 |
| 167 scoped_ptr<app_list::LauncherPageEventDispatcher> |
| 168 launcher_page_event_dispatcher_; |
| 169 |
165 base::TimeDelta auto_launch_timeout_; | 170 base::TimeDelta auto_launch_timeout_; |
166 | 171 |
167 Users users_; | 172 Users users_; |
168 | 173 |
169 #if defined(USE_ASH) | 174 #if defined(USE_ASH) |
170 scoped_ptr<AppSyncUIStateWatcher> app_sync_ui_state_watcher_; | 175 scoped_ptr<AppSyncUIStateWatcher> app_sync_ui_state_watcher_; |
171 #endif | 176 #endif |
172 | 177 |
173 ObserverList<app_list::AppListViewDelegateObserver> observers_; | 178 ObserverList<app_list::AppListViewDelegateObserver> observers_; |
174 | 179 |
175 // Used to track the SigninManagers that this instance is observing so that | 180 // Used to track the SigninManagers that this instance is observing so that |
176 // this instance can be removed as an observer on its destruction. | 181 // this instance can be removed as an observer on its destruction. |
177 ScopedObserver<SigninManagerBase, AppListViewDelegate> scoped_observer_; | 182 ScopedObserver<SigninManagerBase, AppListViewDelegate> scoped_observer_; |
178 | 183 |
179 // Window contents of additional custom launcher pages. | 184 // Window contents of additional custom launcher pages. |
180 ScopedVector<apps::CustomLauncherPageContents> custom_page_contents_; | 185 ScopedVector<apps::CustomLauncherPageContents> custom_page_contents_; |
181 | 186 |
182 // Registers for NOTIFICATION_APP_TERMINATING to unload custom launcher pages. | 187 // Registers for NOTIFICATION_APP_TERMINATING to unload custom launcher pages. |
183 content::NotificationRegistrar registrar_; | 188 content::NotificationRegistrar registrar_; |
184 | 189 |
185 DISALLOW_COPY_AND_ASSIGN(AppListViewDelegate); | 190 DISALLOW_COPY_AND_ASSIGN(AppListViewDelegate); |
186 }; | 191 }; |
187 | 192 |
188 #endif // CHROME_BROWSER_UI_APP_LIST_APP_LIST_VIEW_DELEGATE_H_ | 193 #endif // CHROME_BROWSER_UI_APP_LIST_APP_LIST_VIEW_DELEGATE_H_ |
OLD | NEW |