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

Issue 23868042: Mark supervised profiles as such immediately when they're created. (Closed)

Created:
7 years, 3 months ago by Bernhard Bauer
Modified:
7 years, 2 months ago
CC:
chromium-reviews, asanka, extensions-reviews_chromium.org, benjhayden+dwatch_chromium.org, rginda+watch_chromium.org, pam+watch_chromium.org, chromium-apps-reviews_chromium.org
Visibility:
Public.

Description

Mark supervised profiles as such immediately when they're created. This happens in Profile::InitProfileUserPrefs(), so we add a new method Profile::Delegate::OnPrefsLoaded() which is called immediately after the PrefService has been creted, and which ProfileManager implements by calling InitProfileUserPrefs(). Also, remove ManagedUserService::InitForTesting in favor of marking the profile as managed at creation. BUG=279307 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=229237

Patch Set 1 #

Patch Set 2 : fix #

Patch Set 3 : sync #

Patch Set 4 : fix #

Patch Set 5 : . #

Total comments: 7

Patch Set 6 : review #

Patch Set 7 : review #

Patch Set 8 : sync #

Patch Set 9 : fix #

Patch Set 10 : leak #

Total comments: 4

Patch Set 11 : review #

Total comments: 8

Patch Set 12 : review #

Total comments: 2

Patch Set 13 : review #

Unified diffs Side-by-side diffs Delta from patch set Stats (+250 lines, -182 lines) Patch
M chrome/browser/extensions/extension_service_unittest.h View 1 2 3 4 5 6 7 8 9 10 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/extensions/extension_service_unittest.cc View 1 2 3 4 5 6 7 8 9 10 7 chunks +39 lines, -25 lines 0 comments Download
M chrome/browser/extensions/webstore_startup_installer_browsertest.cc View 1 2 3 4 5 6 7 2 chunks +12 lines, -7 lines 0 comments Download
M chrome/browser/managed_mode/managed_mode_browsertest.cc View 2 chunks +2 lines, -1 line 0 comments Download
M chrome/browser/managed_mode/managed_mode_resource_throttle_browsertest.cc View 4 chunks +8 lines, -1 line 0 comments Download
M chrome/browser/managed_mode/managed_user_service.h View 4 chunks +1 line, -8 lines 0 comments Download
M chrome/browser/managed_mode/managed_user_service.cc View 3 chunks +0 lines, -19 lines 0 comments Download
M chrome/browser/managed_mode/managed_user_service_browsertest.cc View 4 chunks +26 lines, -12 lines 0 comments Download
M chrome/browser/managed_mode/managed_user_service_unittest.cc View 1 2 3 4 5 6 7 8 9 10 7 chunks +32 lines, -22 lines 0 comments Download
M chrome/browser/profiles/profile_browsertest.cc View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/profiles/profile_impl.cc View 1 2 3 4 5 6 7 8 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/browser/profiles/profile_info_cache_unittest.cc View 1 2 3 4 5 6 7 8 9 2 chunks +6 lines, -0 lines 0 comments Download
M chrome/browser/profiles/profile_manager.h View 1 2 3 4 5 6 7 8 2 chunks +4 lines, -4 lines 0 comments Download
M chrome/browser/profiles/profile_manager.cc View 1 2 3 4 5 6 7 8 3 chunks +8 lines, -2 lines 0 comments Download
M chrome/browser/sync/test/integration/single_client_managed_user_settings_sync_test.cc View 1 3 chunks +8 lines, -1 line 0 comments Download
M chrome/browser/themes/theme_service.cc View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +0 lines, -24 lines 0 comments Download
M chrome/browser/themes/theme_service_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 5 chunks +25 lines, -25 lines 0 comments Download
M chrome/browser/ui/cocoa/browser/avatar_button_controller_unittest.mm View 1 2 3 3 chunks +29 lines, -9 lines 0 comments Download
M chrome/browser/ui/startup/startup_browser_creator_browsertest.cc View 1 chunk +1 line, -5 lines 0 comments Download
M chrome/browser/ui/webui/downloads_ui_browsertest.h View 1 chunk +6 lines, -2 lines 0 comments Download
M chrome/browser/ui/webui/downloads_ui_browsertest.cc View 1 chunk +7 lines, -8 lines 0 comments Download
M chrome/browser/ui/webui/downloads_ui_browsertest.js View 1 chunk +1 line, -3 lines 0 comments Download
M chrome/common/chrome_switches.h View 1 2 3 4 5 6 7 1 chunk +1 line, -0 lines 0 comments Download
M chrome/common/chrome_switches.cc View 1 2 3 4 5 6 7 1 chunk +4 lines, -1 line 0 comments Download
M chrome/test/base/testing_profile.h View 1 2 3 4 5 4 chunks +8 lines, -0 lines 0 comments Download
M chrome/test/base/testing_profile.cc View 1 2 3 4 5 6 7 8 7 chunks +15 lines, -1 line 0 comments Download
M chrome/test/base/testing_profile_manager.cc View 1 2 3 4 1 chunk +2 lines, -0 lines 0 comments Download

Messages

Total messages: 24 (0 generated)
Bernhard Bauer
Please review. Rachel: profiles/ Sergiu: managed_mode/ Thanks!
7 years, 2 months ago (2013-10-01 16:44:11 UTC) #1
rpetterson
https://codereview.chromium.org/23868042/diff/13002/chrome/browser/profiles/profile_manager.cc File chrome/browser/profiles/profile_manager.cc (right): https://codereview.chromium.org/23868042/diff/13002/chrome/browser/profiles/profile_manager.cc#newcode554 chrome/browser/profiles/profile_manager.cc:554: InitProfileUserPrefs(profile); It doesn't really change the call flow, so ...
7 years, 2 months ago (2013-10-01 20:19:56 UTC) #2
Bernhard Bauer
https://codereview.chromium.org/23868042/diff/13002/chrome/browser/profiles/profile_manager.cc File chrome/browser/profiles/profile_manager.cc (right): https://codereview.chromium.org/23868042/diff/13002/chrome/browser/profiles/profile_manager.cc#newcode554 chrome/browser/profiles/profile_manager.cc:554: InitProfileUserPrefs(profile); On 2013/10/01 20:19:57, rpetterson wrote: > It doesn't ...
7 years, 2 months ago (2013-10-01 20:42:15 UTC) #3
Sergiu
lgtm managed_mode/* https://codereview.chromium.org/23868042/diff/13002/chrome/browser/themes/theme_service_unittest.cc File chrome/browser/themes/theme_service_unittest.cc (right): https://codereview.chromium.org/23868042/diff/13002/chrome/browser/themes/theme_service_unittest.cc#newcode30 chrome/browser/themes/theme_service_unittest.cc:30: manager_(TestingBrowserProcess::GetGlobal()) {} nit: 1 extra space
7 years, 2 months ago (2013-10-02 08:56:17 UTC) #4
Bernhard Bauer
https://codereview.chromium.org/23868042/diff/13002/chrome/browser/themes/theme_service_unittest.cc File chrome/browser/themes/theme_service_unittest.cc (right): https://codereview.chromium.org/23868042/diff/13002/chrome/browser/themes/theme_service_unittest.cc#newcode30 chrome/browser/themes/theme_service_unittest.cc:30: manager_(TestingBrowserProcess::GetGlobal()) {} On 2013/10/02 08:56:18, Sergiu wrote: > nit: ...
7 years, 2 months ago (2013-10-02 09:05:45 UTC) #5
rpetterson
https://codereview.chromium.org/23868042/diff/13002/chrome/browser/profiles/profile_manager.cc File chrome/browser/profiles/profile_manager.cc (right): https://codereview.chromium.org/23868042/diff/13002/chrome/browser/profiles/profile_manager.cc#newcode554 chrome/browser/profiles/profile_manager.cc:554: InitProfileUserPrefs(profile); On 2013/10/01 20:42:15, Bernhard Bauer wrote: > On ...
7 years, 2 months ago (2013-10-07 23:22:49 UTC) #6
Bernhard Bauer
https://codereview.chromium.org/23868042/diff/13002/chrome/browser/profiles/profile_manager.cc File chrome/browser/profiles/profile_manager.cc (right): https://codereview.chromium.org/23868042/diff/13002/chrome/browser/profiles/profile_manager.cc#newcode554 chrome/browser/profiles/profile_manager.cc:554: InitProfileUserPrefs(profile); On 2013/10/07 23:22:49, rpetterson wrote: > On 2013/10/01 ...
7 years, 2 months ago (2013-10-08 14:56:01 UTC) #7
rpetterson
https://codereview.chromium.org/23868042/diff/13002/chrome/browser/profiles/profile_manager.cc File chrome/browser/profiles/profile_manager.cc (right): https://codereview.chromium.org/23868042/diff/13002/chrome/browser/profiles/profile_manager.cc#newcode554 chrome/browser/profiles/profile_manager.cc:554: InitProfileUserPrefs(profile); On 2013/10/08 14:56:01, Bernhard Bauer wrote: > On ...
7 years, 2 months ago (2013-10-08 18:02:54 UTC) #8
Bernhard Bauer
OK, I directly call InitProfileUserPrefs now instead of going through the delegate interface. PTAL? To ...
7 years, 2 months ago (2013-10-09 21:38:13 UTC) #9
Bernhard Bauer
Ping? :)
7 years, 2 months ago (2013-10-16 19:10:43 UTC) #10
rpetterson
LGTM Sorry this fell into my e-mail abyss! Thank you for pinging :) And thanks ...
7 years, 2 months ago (2013-10-16 19:40:02 UTC) #11
Bernhard Bauer
https://codereview.chromium.org/23868042/diff/67001/chrome/browser/profiles/profile_manager.cc File chrome/browser/profiles/profile_manager.cc (right): https://codereview.chromium.org/23868042/diff/67001/chrome/browser/profiles/profile_manager.cc#newcode1020 chrome/browser/profiles/profile_manager.cc:1020: managed_user_id = "Test ID"; On 2013/10/16 19:40:03, rpetterson wrote: ...
7 years, 2 months ago (2013-10-16 19:47:20 UTC) #12
Bernhard Bauer
Adding more OWNERS: Benjamin: extensions Peter: themes Scott: tests Thanks!
7 years, 2 months ago (2013-10-16 21:08:57 UTC) #13
not at google - send to devlin
https://codereview.chromium.org/23868042/diff/67001/chrome/browser/extensions/extension_service_unittest.cc File chrome/browser/extensions/extension_service_unittest.cc (right): https://codereview.chromium.org/23868042/diff/67001/chrome/browser/extensions/extension_service_unittest.cc#newcode568 chrome/browser/extensions/extension_service_unittest.cc:568: InitializeExtensionService(params); this 1 -> 3 line thing is awkward. ...
7 years, 2 months ago (2013-10-16 21:12:49 UTC) #14
sky
chrome/test LGTM
7 years, 2 months ago (2013-10-16 22:20:55 UTC) #15
pkotwicz
I will take a look at the CL on Thursday
7 years, 2 months ago (2013-10-16 23:56:54 UTC) #16
Bernhard Bauer
https://codereview.chromium.org/23868042/diff/67001/chrome/browser/extensions/extension_service_unittest.cc File chrome/browser/extensions/extension_service_unittest.cc (right): https://codereview.chromium.org/23868042/diff/67001/chrome/browser/extensions/extension_service_unittest.cc#newcode568 chrome/browser/extensions/extension_service_unittest.cc:568: InitializeExtensionService(params); On 2013/10/16 21:12:50, kalman wrote: > this 1 ...
7 years, 2 months ago (2013-10-17 14:12:02 UTC) #17
not at google - send to devlin
lgtm
7 years, 2 months ago (2013-10-17 14:25:26 UTC) #18
pkotwicz
https://codereview.chromium.org/23868042/diff/80001/chrome/browser/themes/theme_service.cc File chrome/browser/themes/theme_service.cc (right): https://codereview.chromium.org/23868042/diff/80001/chrome/browser/themes/theme_service.cc#newcode99 chrome/browser/themes/theme_service.cc:99: if (!(theme_supplier_ && I do not think that this ...
7 years, 2 months ago (2013-10-17 16:49:08 UTC) #19
Bernhard Bauer
https://codereview.chromium.org/23868042/diff/80001/chrome/browser/themes/theme_service.cc File chrome/browser/themes/theme_service.cc (right): https://codereview.chromium.org/23868042/diff/80001/chrome/browser/themes/theme_service.cc#newcode99 chrome/browser/themes/theme_service.cc:99: if (!(theme_supplier_ && On 2013/10/17 16:49:09, pkotwicz wrote: > ...
7 years, 2 months ago (2013-10-17 16:55:02 UTC) #20
pkotwicz
LGTM with nit https://codereview.chromium.org/23868042/diff/95001/chrome/browser/themes/theme_service_unittest.cc File chrome/browser/themes/theme_service_unittest.cc (right): https://codereview.chromium.org/23868042/diff/95001/chrome/browser/themes/theme_service_unittest.cc#newcode233 chrome/browser/themes/theme_service_unittest.cc:233: public: Nit: Add constructor and destructor
7 years, 2 months ago (2013-10-17 17:40:19 UTC) #21
Bernhard Bauer
https://codereview.chromium.org/23868042/diff/95001/chrome/browser/themes/theme_service_unittest.cc File chrome/browser/themes/theme_service_unittest.cc (right): https://codereview.chromium.org/23868042/diff/95001/chrome/browser/themes/theme_service_unittest.cc#newcode233 chrome/browser/themes/theme_service_unittest.cc:233: public: On 2013/10/17 17:40:20, pkotwicz wrote: > Nit: Add ...
7 years, 2 months ago (2013-10-17 18:14:50 UTC) #22
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/bauerb@chromium.org/23868042/100001
7 years, 2 months ago (2013-10-17 18:29:54 UTC) #23
commit-bot: I haz the power
7 years, 2 months ago (2013-10-17 22:05:29 UTC) #24
Message was sent while issue was closed.
Change committed as 229237

Powered by Google App Engine
This is Rietveld 408576698