commit | 6af2efe5064b16fcb05f41185c958151a38e82cf | [log] [tgz] |
---|---|---|
author | Peter Beverloo <peter@chromium.org> | Fri Jul 06 17:04:20 2018 |
committer | Commit Bot <commit-bot@chromium.org> | Fri Jul 06 17:04:20 2018 |
tree | 1a7876674d899d3fd2edd29c15ea03f043f03c4d | |
parent | ab64006283ffc61d7028d094a5c2adf4ce7d53f7 [diff] |
Introduce the BackgroundFetchDataManagerObserver class In the Background Fetch code, there currently isn't a clean separation between initiating an action to storage (e.g. updating the title of a background fetch from JavaScript) and propagating such changes to other subsystems that have to know. In effect, there are BackgroundFetchJobController instances for background fetches that aren't active, the BackgroundFetchContext is the one that owns the instances (as opposed to the BackgroundFetchScheduler) and much of the control flow serves multiple purposes. This CL introduces an observer interface for the BackgroundFetchDataManager that notifies observers about successful changes to the data store. This means that such code doesn't have to worry about the source of the change, or whether it was successful. Right now the BackgroundFetchContext observes the data manager. In the mid term we'd like the BackgroundFetchScheduler to observe the data manager instead. Bug: 850512 Change-Id: Ie4d5b280ac1f220553cc2867c035bf4662c4e88f Reviewed-on: https://chromium-review.googlesource.com/1127784 Commit-Queue: Peter Beverloo <peter@chromium.org> Reviewed-by: Michael van Ouwerkerk <mvanouwerkerk@chromium.org> Cr-Commit-Position: refs/heads/master@{#573002}
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 .