commit | 14f47c129185c7827ff41d728bafb9848d726cf8 | [log] [tgz] |
---|---|---|
author | Victor Costan <pwnall@chromium.org> | Thu Mar 01 08:02:24 2018 |
committer | Commit Bot <commit-bot@chromium.org> | Thu Mar 01 08:02:24 2018 |
tree | ffe0dd680d4c60803f1241e36e0fcf54a12aa0df | |
parent | a86185d8cfa79bc08c7484b83447de6c172688e6 [diff] |
Cookie Store: Extract change notifications to separate classes. Currently, CookieStore implementations are responsible for storing cookies and dispatching notifications when the cookies they store change. The dispatch logic is non-trivial, and will grow to support the Async Cookies API (see the associated bug), so it deserves its own class. This CL splits off the change notification dispatch as follows: * CookieStore -> CookieChangeDispatcher * CookieMonster -> CookieMonsterChangeDispatcher * AwCookieStoreWrapper -> AwCookieStoreChangeDispatcherWrapper * CookieStoreIOS -> CookieChangeDispatcherIOS Due to complexities and upcoming refactoring in the iOS CookieStore implementations, the existing implementation is not split up. Instead, CookieChangeDispatcherIOS is a proxy that directs AddCallback*() calls to CookieStoreIOS. The other CookieStore implementations (CookieMonster, AwCookieStoreWrapper) have the change notification dispatch code moved into the ChangeDispatcher classes. This CL also changes the listener registration APIs to pass base::Callbacks by value instead of passing them by reference, per https://chromium.googlesource.com/chromium/src/+/master/docs/callback.md This CL is large, but only does renames / code moving / minor cleanups. It opens up the way for a small (but dense) CL that will revamp the notification dispatch logic. Bug: 729800 Cq-Include-Trybots: master.tryserver.chromium.linux:linux_mojo;master.tryserver.chromium.mac:ios-simulator-cronet;master.tryserver.chromium.mac:ios-simulator-full-configs Change-Id: Ie56b036419a85f7802c6b1d4bb2c935b58232374 Reviewed-on: https://chromium-review.googlesource.com/919159 Commit-Queue: Victor Costan <pwnall@chromium.org> Reviewed-by: Randy Smith <rdsmith@chromium.org> Reviewed-by: Richard Coles <torne@chromium.org> Reviewed-by: Mohammad Refaat <mrefaat@chromium.org> Reviewed-by: John Abd-El-Malek <jam@chromium.org> Reviewed-by: David Roger <droger@chromium.org> Cr-Commit-Position: refs/heads/master@{#540099}
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.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .