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

Side by Side Diff: chrome/browser/chromeos/extensions/wallpaper_manager_util.cc

Issue 2700783002: s/\bArc\b/ARC/g for ARC related code. (Closed)
Patch Set: Address ARC++ Created 3 years, 10 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 (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 #include "chrome/browser/chromeos/extensions/wallpaper_manager_util.h" 5 #include "chrome/browser/chromeos/extensions/wallpaper_manager_util.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/metrics/field_trial.h" 9 #include "base/metrics/field_trial.h"
10 #include "chrome/browser/chromeos/arc/arc_session_manager.h" 10 #include "chrome/browser/chromeos/arc/arc_session_manager.h"
(...skipping 20 matching lines...) Expand all
31 const char kAndroidWallpapersAppPackage[] = "com.google.android.apps.wallpaper"; 31 const char kAndroidWallpapersAppPackage[] = "com.google.android.apps.wallpaper";
32 const char kAndroidWallpapersAppActivity[] = 32 const char kAndroidWallpapersAppActivity[] =
33 "com.google.android.apps.wallpaper.picker.CategoryPickerActivity"; 33 "com.google.android.apps.wallpaper.picker.CategoryPickerActivity";
34 34
35 const char kAndroidWallpapersAppTrialName[] = "AndroidWallpapersAppOnChromeOS"; 35 const char kAndroidWallpapersAppTrialName[] = "AndroidWallpapersAppOnChromeOS";
36 const char kEnableAndroidWallpapersApp[] = 36 const char kEnableAndroidWallpapersApp[] =
37 "Enable-android-wallpapers-app_Dogfood"; 37 "Enable-android-wallpapers-app_Dogfood";
38 38
39 } // namespace 39 } // namespace
40 40
41 // Only if the current profile is the primary profile && Arc service is enabled 41 // Only if the current profile is the primary profile && ARC service is enabled
42 // && the Android Wallpapers App has been installed && the finch experiment or 42 // && the Android Wallpapers App has been installed && the finch experiment or
43 // chrome flag is enabled, launch the Android Wallpapers App. Otherwise launch 43 // chrome flag is enabled, launch the Android Wallpapers App. Otherwise launch
44 // the old Chrome OS Wallpaper Picker App. 44 // the old Chrome OS Wallpaper Picker App.
45 bool ShouldUseAndroidWallpapersApp(Profile* profile) { 45 bool ShouldUseAndroidWallpapersApp(Profile* profile) {
46 if (!chromeos::ProfileHelper::IsPrimaryProfile(profile)) 46 if (!chromeos::ProfileHelper::IsPrimaryProfile(profile))
47 return false; 47 return false;
48 48
49 // Check if the ARC++ is enabled. 49 // Check if the ARC is enabled.
50 const arc::ArcSessionManager* const arc_session_manager = 50 const arc::ArcSessionManager* const arc_session_manager =
51 arc::ArcSessionManager::Get(); 51 arc::ArcSessionManager::Get();
52 if (!arc_session_manager || !arc_session_manager->IsArcPlayStoreEnabled()) 52 if (!arc_session_manager || !arc_session_manager->IsArcPlayStoreEnabled())
53 return false; 53 return false;
54 54
55 // Check if Android Wallpapers App has been installed. 55 // Check if Android Wallpapers App has been installed.
56 const ArcAppListPrefs* const prefs = ArcAppListPrefs::Get(profile); 56 const ArcAppListPrefs* const prefs = ArcAppListPrefs::Get(profile);
57 if (!prefs || prefs->GetAppsForPackage(kAndroidWallpapersAppPackage).empty()) 57 if (!prefs || prefs->GetAppsForPackage(kAndroidWallpapersAppPackage).empty())
58 return false; 58 return false;
59 59
(...skipping 27 matching lines...) Expand all
87 if (!extension) 87 if (!extension)
88 return; 88 return;
89 89
90 OpenApplication(AppLaunchParams( 90 OpenApplication(AppLaunchParams(
91 profile, extension, extensions::LAUNCH_CONTAINER_WINDOW, 91 profile, extension, extensions::LAUNCH_CONTAINER_WINDOW,
92 WindowOpenDisposition::NEW_WINDOW, extensions::SOURCE_CHROME_INTERNAL)); 92 WindowOpenDisposition::NEW_WINDOW, extensions::SOURCE_CHROME_INTERNAL));
93 } 93 }
94 } 94 }
95 95
96 } // namespace wallpaper_manager_util 96 } // namespace wallpaper_manager_util
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/extensions/gfx_utils.cc ('k') | chrome/browser/chromeos/login/arc_kiosk_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698