Commit 85af6214 authored by David Roger's avatar David Roger Committed by Chromium LUCI CQ

[profiles] Profile picker listen for hosted domain changes

An observer for hosted domain changes was added in CL:
https://chromium-review.googlesource.com/c/chromium/src/+/2568285/4/chrome/browser/profiles/profile_info_cache_observer.h

The profile picker has UI depending on the hosted domain and is intended
to dynamically update when profile changes.
To be consistent with other profile-related events, this CL updates the
picker when the hosted domain changes as well.

Bug: None
Change-Id: Ia0f7a19c23d8f6c86d3358a4ecc58787877597d4
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2569514Reviewed-by: default avatarMonica Basta <msalama@chromium.org>
Commit-Queue: David Roger <droger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#837534}
parent 60ed7e98
...@@ -627,6 +627,11 @@ void ProfilePickerHandler::OnProfileNameChanged( ...@@ -627,6 +627,11 @@ void ProfilePickerHandler::OnProfileNameChanged(
PushProfilesList(); PushProfilesList();
} }
void ProfilePickerHandler::OnProfileHostedDomainChanged(
const base::FilePath& profile_path) {
PushProfilesList();
}
void ProfilePickerHandler::DidFirstVisuallyNonEmptyPaint() { void ProfilePickerHandler::DidFirstVisuallyNonEmptyPaint() {
DCHECK(!creation_time_on_startup_.is_null()); DCHECK(!creation_time_on_startup_.is_null());
base::UmaHistogramTimes("ProfilePicker.StartupTime.FirstPaint", base::UmaHistogramTimes("ProfilePicker.StartupTime.FirstPaint",
......
...@@ -73,6 +73,8 @@ class ProfilePickerHandler : public content::WebUIMessageHandler, ...@@ -73,6 +73,8 @@ class ProfilePickerHandler : public content::WebUIMessageHandler,
const base::FilePath& profile_path) override; const base::FilePath& profile_path) override;
void OnProfileNameChanged(const base::FilePath& profile_path, void OnProfileNameChanged(const base::FilePath& profile_path,
const base::string16& old_profile_name) override; const base::string16& old_profile_name) override;
void OnProfileHostedDomainChanged(
const base::FilePath& profile_path) override;
// content::WebContentsObserver: // content::WebContentsObserver:
void DidFirstVisuallyNonEmptyPaint() override; void DidFirstVisuallyNonEmptyPaint() override;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment