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

Side by Side Diff: chrome/browser/ui/app_list/app_list_util.cc

Issue 2406303003: Move enable_app_list to a buildflag. (Closed)
Patch Set: More grit defines Created 4 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
« no previous file with comments | « chrome/browser/ui/BUILD.gn ('k') | chrome/browser/ui/apps/app_info_dialog.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "chrome/browser/ui/app_list/app_list_util.h" 5 #include "chrome/browser/ui/app_list/app_list_util.h"
6 6
7 #include "build/build_config.h" 7 #include "build/build_config.h"
8 #include "chrome/browser/browser_process.h" 8 #include "chrome/browser/browser_process.h"
9 #include "chrome/common/pref_names.h" 9 #include "chrome/common/pref_names.h"
10 #include "components/prefs/pref_service.h" 10 #include "components/prefs/pref_service.h"
11 11
12 bool IsAppLauncherEnabled() { 12 bool IsAppLauncherEnabled() {
13 #if !defined(ENABLE_APP_LIST) 13 #if !BUILDFLAG(ENABLE_APP_LIST)
14 return false; 14 return false;
15 #elif defined(OS_CHROMEOS) || defined(USE_ASH) 15 #elif defined(OS_CHROMEOS) || defined(USE_ASH)
16 return true; 16 return true;
17 #else 17 #else
18 PrefService* prefs = g_browser_process->local_state(); 18 PrefService* prefs = g_browser_process->local_state();
19 // In some tests, the prefs aren't initialised. 19 // In some tests, the prefs aren't initialised.
20 return prefs && prefs->GetBoolean(prefs::kAppLauncherHasBeenEnabled); 20 return prefs && prefs->GetBoolean(prefs::kAppLauncherHasBeenEnabled);
21 #endif 21 #endif
22 } 22 }
23 23
24 bool ShouldShowAppLauncherPromo() { 24 bool ShouldShowAppLauncherPromo() {
25 // Never promote. TODO(tapted): Delete this function and supporting code. 25 // Never promote. TODO(tapted): Delete this function and supporting code.
26 return false; 26 return false;
27 } 27 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/BUILD.gn ('k') | chrome/browser/ui/apps/app_info_dialog.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698