Convert global MutationObserver data to per-agent
Convert the global MutationObserver data, active_mutation_observers, suspended_mutation_observers, and active_slot_change_list to per agent. Introduces the MutationObserverNotifier class which is created for every WindowAgent. MutationObserverNotifier now manages active_mutation_observers, suspended_mutation_observers, and active_slot_change_list. Also the Document's agent is now set using the ContextDocument frame's WindowAgentFactory. This is because some Documents such as those created with DOMImplementation.createHTMLDocument do not have a frame. Some Documents created in unit tests have neither a ContextDocument nor a frame so we assign a new WindowAgent. In theory agent's are tied to ExecutionContexts, and these Documents that do not have an ExecutionContext should not have their own WindowAgent. Bug: 961186 Change-Id: Ie36a64791a3e1b424bcbf248b083fdf1bf5d465d Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1655412 Commit-Queue: Keishi Hattori <keishi@chromium.org> Reviewed-by:Dave Tapuska <dtapuska@chromium.org> Reviewed-by:
Kouhei Ueno <kouhei@chromium.org> Reviewed-by:
Yuta Kitamura <yutak@chromium.org> Reviewed-by:
Hayato Ito <hayato@chromium.org> Reviewed-by:
Kentaro Hara <haraken@chromium.org> Cr-Commit-Position: refs/heads/master@{#669571}
Showing
Please register or sign in to comment