commit | 7d45ddf1833ac94d4b51a7663e407df74c7a6ea0 | [log] [tgz] |
---|---|---|
author | Ryan Sultanem <[email protected]> | Mon Apr 29 16:36:03 2024 |
committer | Chromium LUCI CQ <[email protected]> | Mon Apr 29 16:36:03 2024 |
tree | ec2a9e6dce4a0e2febedbb2286713d2496618ec6 | |
parent | ca62bf125db73fd4b19427b97bc184affb52ff59 [diff] |
[SigninPrefs] Create the main structure for Accounts SigninPrefs Add a structure that takes care of all the prefs related to accounts. Accounts are mapped by their GaiaId which is used as the key of the main dictionary prefs. The account dictionary pref will hold the specific data prefs that will be populated in a follow up change. The structure also allows the deletion of those prefs. This management is expected to be controlled by changes done through the IdentityManager. Attached those calls to the GaiaInfoUpdateService as it already listens to most needed calls and already update the ProfileAttributesStorage. The creation of the prefs is done in a lazy mode. Prefs dictionary and pref data are created when the values are set for the first time. The GaiaIds used to create the prefs are expected to be valid, point to a valid account in Chrome. Otherwise the pref, even though it will be created at first, will probably be deleted after a call to /ListAccount. The structure could actually be replaced by some free functions since it is currently not held anywhere or doesn't hold any independent run time information, but restricting all access to a class scope allows to maintain a more coupled relation with the different future usages and allows for easier extension, such as listening to preference changes for example that might be needed later on. The code done is very similar to what is already done in SyncPrefs, however it is not big/complex enough to actually share the code, which would have made the logic more complex than it is. Also the underlying need will have different usages, duplicating some simple parts of the code is acceptable in this case since it is mainly around container manipulation. Bug: b:331767195, b:335437309 Change-Id: Ia209e5de1020bfb012d4cdc8ad43b28e3b393b73 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5487922 Reviewed-by: David Roger <[email protected]> Commit-Queue: Ryan Sultanem <[email protected]> Cr-Commit-Position: refs/heads/main@{#1293739}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
To check out the source code locally, don't use git clone
! Instead, follow the instructions on how to get the code.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure.
For historical reasons, there are some small top level directories. Now the guidance is that new top level directories are for product (e.g. Chrome, Android WebView, Ash). Even if these products have multiple executables, the code should be in subdirectories of the product.
If you found a bug, please file it at https://crbug.com/new.