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

Side by Side Diff: chrome/browser/ui/app_list/app_list_controller.h

Issue 11094019: Auto hide app list on Windows when it loses focus. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Feedback Created 8 years, 2 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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_CONTROLLER_H_ 5 #ifndef CHROME_BROWSER_UI_APP_LIST_APP_LIST_CONTROLLER_H_
6 #define CHROME_BROWSER_UI_APP_LIST_APP_LIST_CONTROLLER_H_ 6 #define CHROME_BROWSER_UI_APP_LIST_APP_LIST_CONTROLLER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 class Profile; 10 class Profile;
11 11
12 // Interface to allow the view delegate to call out to whatever is controlling 12 // Interface to allow the view delegate to call out to whatever is controlling
13 // the app list. This will have different implementations for different 13 // the app list. This will have different implementations for different
14 // platforms. 14 // platforms.
15 class AppListController { 15 class AppListControllerDelegate {
16 public: 16 public:
17 virtual ~AppListController() {} 17 virtual ~AppListControllerDelegate();
18 18
19 // Handle the controller being closed. 19 // Close the view.
20 virtual void CloseView() = 0; 20 virtual void CloseView() = 0;
21 21
22 // Handle the view being closed.
23 virtual void ViewClosing();
24
25 // Handle the view being activated or deactivated.
26 virtual void ViewActivationChanged(bool active);
27
22 // Control of pinning apps. 28 // Control of pinning apps.
23 virtual bool IsAppPinned(const std::string& extension_id) = 0; 29 virtual bool IsAppPinned(const std::string& extension_id);
24 virtual void PinApp(const std::string& extension_id) = 0; 30 virtual void PinApp(const std::string& extension_id);
25 virtual void UnpinApp(const std::string& extension_id) = 0; 31 virtual void UnpinApp(const std::string& extension_id);
26 virtual bool CanPin() = 0; 32 virtual bool CanPin() = 0;
27 33
28 // Whether the controller supports showing the Create Shortcuts dialog. 34 // Whether the controller supports showing the Create Shortcuts dialog.
29 virtual bool CanShowCreateShortcutsDialog() = 0; 35 virtual bool CanShowCreateShortcutsDialog() = 0;
30 virtual void ShowCreateShortcutsDialog(Profile* profile, 36 virtual void ShowCreateShortcutsDialog(Profile* profile,
31 const std::string& extension_id) = 0; 37 const std::string& extension_id);
32 38
33 // App has been clicked on in the app list. 39 // App has been clicked on in the app list.
34 virtual void ActivateApp(Profile* profile, 40 virtual void ActivateApp(Profile* profile,
35 const std::string& extension_id, 41 const std::string& extension_id,
36 int event_flags) = 0; 42 int event_flags) = 0;
37 }; 43 };
38 44
39 namespace app_list_controller { 45 namespace app_list_controller {
40 46
41 // Show the app list. 47 // Show the app list.
42 void ShowAppList(); 48 void ShowAppList();
43 49
44 } 50 }
45 51
46 #endif // CHROME_BROWSER_UI_APP_LIST_APP_LIST_CONTROLLER_H_ 52 #endif // CHROME_BROWSER_UI_APP_LIST_APP_LIST_CONTROLLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698