Send OnPrimaryAccountSet() on ChromeOS

Conceptually, we have long thought of the primary account as being
immutable on ChromeOS. To reflect this conceptual understanding, the
observer notifications for the primary account being set/cleared are
never fired on ChromeOS.

Notwithstanding the above conceptual reality, in practice the primary
account is set on ChromeOS. The reason is simple: after the Profile is
created along with the infrastructure for managing Gaia identities,
ChromeOS-specific code configures the browser’s primary account to be
the account used to log into the device.

This CL introduces the firing of the
IdentityManager::Observer::OnPrimaryAccountSet() notification on
ChromeOS when the primary account is set, thus reflecting the reality
that the primary account in practice is set on this platform.

Note that the primary account is never cleared on ChromeOS, so there is
no need to introducing firing of that notification on this platform.

Design doc for the full effort of rationalizing setting of the primary
account on ChromeOS is here:
https://docs.google.com/document/d/1kjNtay0nTvqPkjOSBWFMwQ49eXO0hQ9OhG9LSpBTFwY/edit#

Change-Id: I5fd69ea256a1653ea6a59261cf1f2da5ac435ed6
Bug: 814787
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1524489
Commit-Queue: Colin Blundell <blundell@chromium.org>
Reviewed-by: Xiyuan Xia <xiyuan@chromium.org>
Reviewed-by: Mihai Sardarescu <msarda@chromium.org>
Reviewed-by: Marc Treib <treib@chromium.org>
Cr-Commit-Position: refs/heads/master@{#643379}
3 files changed