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

Side by Side Diff: ui/app_list/app_list_switches.cc

Issue 2965813002: Added flag in chrome://flags to enable the New Launcher UI. (Closed)
Patch Set: Added flag in chrome://flags to enable the feature. Created 3 years, 5 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #include "ui/app_list/app_list_switches.h" 5 #include "ui/app_list/app_list_switches.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 8
9 namespace app_list { 9 namespace app_list {
10 namespace switches { 10 namespace switches {
11 11
12 // Specifies the chrome-extension:// URL for the contents of an additional page 12 // Specifies the chrome-extension:// URL for the contents of an additional page
13 // added to the app launcher. 13 // added to the app launcher.
14 const char kCustomLauncherPage[] = "custom-launcher-page"; 14 const char kCustomLauncherPage[] = "custom-launcher-page";
15 15
16 // If set, the app list will not be dismissed when it loses focus. This is 16 // If set, the app list will not be dismissed when it loses focus. This is
17 // useful when testing the app list or a custom launcher page. It can still be 17 // useful when testing the app list or a custom launcher page. It can still be
18 // dismissed via the other methods (like the Esc key). 18 // dismissed via the other methods (like the Esc key).
19 const char kDisableAppListDismissOnBlur[] = "disable-app-list-dismiss-on-blur"; 19 const char kDisableAppListDismissOnBlur[] = "disable-app-list-dismiss-on-blur";
20 20
21 // If set, the app list will be enabled as if enabled from CWS. 21 // If set, the app list will be enabled as if enabled from CWS.
22 const char kEnableAppList[] = "enable-app-list"; 22 const char kEnableAppList[] = "enable-app-list";
23 23
24 // If set, fullscreen app list will be enabled as if the feature flag was set.
25 const char kEnableNewAppListUI[] = "enable-new-launcher-ui";
stevenjb 2017/06/30 21:17:26 Is this just intended to enable the fullscreen app
newcomer 2017/06/30 21:40:24 Done.
26
24 // Enable/disable syncing of the app list independent of extensions. 27 // Enable/disable syncing of the app list independent of extensions.
25 const char kEnableSyncAppList[] = "enable-sync-app-list"; 28 const char kEnableSyncAppList[] = "enable-sync-app-list";
26 const char kDisableSyncAppList[] = "disable-sync-app-list"; 29 const char kDisableSyncAppList[] = "disable-sync-app-list";
27 30
28 // Enable/disable drive search in chrome launcher. 31 // Enable/disable drive search in chrome launcher.
29 const char kEnableDriveSearchInChromeLauncher[] = 32 const char kEnableDriveSearchInChromeLauncher[] =
30 "enable-drive-search-in-app-launcher"; 33 "enable-drive-search-in-app-launcher";
31 const char kDisableDriveSearchInChromeLauncher[] = 34 const char kDisableDriveSearchInChromeLauncher[] =
32 "disable-drive-search-in-app-launcher"; 35 "disable-drive-search-in-app-launcher";
33 36
34 // If set, the app list will forget it has been installed on startup. Note this 37 // If set, the app list will forget it has been installed on startup. Note this
35 // doesn't prevent the app list from running, it just makes Chrome think the app 38 // doesn't prevent the app list from running, it just makes Chrome think the app
36 // list hasn't been enabled (as in kEnableAppList) yet. 39 // list hasn't been enabled (as in kEnableAppList) yet.
37 const char kResetAppListInstallState[] = "reset-app-list-install-state"; 40 const char kResetAppListInstallState[] = "reset-app-list-install-state";
38 41
39 bool IsAppListSyncEnabled() { 42 bool IsAppListSyncEnabled() {
40 return !base::CommandLine::ForCurrentProcess()->HasSwitch( 43 return !base::CommandLine::ForCurrentProcess()->HasSwitch(
41 kDisableSyncAppList); 44 kDisableSyncAppList);
42 } 45 }
43 46
47 bool IsNewAppListUIEnabled() {
48 return base::CommandLine::ForCurrentProcess()->HasSwitch(kEnableNewAppListUI);
49 }
50
44 bool IsFolderUIEnabled() { 51 bool IsFolderUIEnabled() {
45 // Folder UI is available only when AppList sync is enabled, and should 52 // Folder UI is available only when AppList sync is enabled, and should
46 // not be disabled separately. 53 // not be disabled separately.
47 return IsAppListSyncEnabled(); 54 return IsAppListSyncEnabled();
48 } 55 }
49 56
50 bool IsVoiceSearchEnabled() { 57 bool IsVoiceSearchEnabled() {
51 // Speech recognition in AppList is only for ChromeOS right now. 58 // Speech recognition in AppList is only for ChromeOS right now.
52 return true; 59 return true;
53 } 60 }
(...skipping 14 matching lines...) Expand all
68 75
69 if (base::CommandLine::ForCurrentProcess()->HasSwitch( 76 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
70 kDisableDriveSearchInChromeLauncher)) 77 kDisableDriveSearchInChromeLauncher))
71 return false; 78 return false;
72 79
73 return true; 80 return true;
74 } 81 }
75 82
76 } // namespace switches 83 } // namespace switches
77 } // namespace app_list 84 } // namespace app_list
OLDNEW
« chrome/browser/flag_descriptions.cc ('K') | « ui/app_list/app_list_switches.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698