Avoid duplicate/redundant dependents notifications
The notification of repeats could end up adding (or trying to) the begin/end sync-base times again for each repeat, meaning redundant work. Pack the relevant notification data into a struct and then pass that, allowing notifications to be better targeted. This also rename NotifyDependentsIntervalChanged(...) to NotifyDependents(...) - now taking the new struct while still being the "notifications" driver - while adding the new NotifyDependentsOnNewInterval(...) and NotifyDependentsOnRepeat(...) for the relevant notifications. The nesting level of the loop in CreateInstanceTimesFromSyncBase() is reduced. Bug: 998526 Change-Id: I1c4ffba6094261c677e912efc2b9ca0d810c1072 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1816567 Commit-Queue: Fredrik Söderquist <fs@opera.com> Reviewed-by:Stephen Chenney <schenney@chromium.org> Cr-Commit-Position: refs/heads/master@{#698755}
Showing
Please register or sign in to comment