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

Side by Side Diff: chrome/browser/chromeos/arc/arc_util.h

Issue 2642783003: Move more utility functions to arc_util. (Closed)
Patch Set: address comments 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
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_CHROMEOS_ARC_ARC_UTIL_H_
6 #define CHROME_BROWSER_CHROMEOS_ARC_ARC_UTIL_H_
7
8 // Most utility should be put in components/arc/arc_util.{h,cc}, rather than
9 // here. However, some utility implementation requires other modules defined in
10 // chrome/, so this file contains such utilities.
11 // Note that it is not allowed to have dependency from components/ to chrome/
12 // by DEPS.
13
14 class Profile;
15
16 namespace arc {
17
18 // Returns true if ARC is allowed to run for the given profile.
19 // Otherwise, returns false, e.g. if the Profile is not for the primary user,
20 // ARC is not available on the device, it is in the flow to set up managed
21 // account creation.
22 // nullptr can be safely passed to this function. In that case, returns false.
23 bool IsArcAllowedForProfile(const Profile* profile);
24
25 // Disallows ARC for all profiles for testing.
26 // In most cases, disabling ARC should be done via commandline. However,
27 // there are some cases to be tested where ARC is available, but ARC is not
28 // supported for some reasons (e.g. incognito mode, supervised user,
29 // secondary profile). On the other hand, some test infra does not support
30 // such situations (e.g. API test). This is for workaround to emulate the
31 // case.
32 void DisallowArcForTesting();
33
34 } // namespace arc
35
36 #endif // CHROME_BROWSER_CHROMEOS_ARC_ARC_UTIL_H_
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/arc/arc_session_manager.cc ('k') | chrome/browser/chromeos/arc/arc_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698