[webui][ntp] Properly reference web contents
Previously, NewTabPageHandler was a content::WebContentsObserver. However, we never associated it with a web contents. As a result, all usages of web contents in the NTP handler were in fact a nullptr. This CL fixes this by passing the correct web contents when creating the NTP handler. Additionally, it removes content::WebContentsObserver as one of the handler's interfaces as we are not observing any changes. Change-Id: I4d79b726dbc7377f29b6f0630680bb13082a3c15 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2095785 Auto-Submit: Tibor Goldschwendt <tiborg@chromium.org> Reviewed-by:Esmael Elmoslimany <aee@chromium.org> Commit-Queue: Tibor Goldschwendt <tiborg@chromium.org> Cr-Commit-Position: refs/heads/master@{#748473}
Showing
Please register or sign in to comment