Commit 1597b469 authored by Scott Violet's avatar Scott Violet Committed by Chromium LUCI CQ

content: update comment in UpdateBrowserControlsState

The issue is the LocalMainFrame interface is registered on the
renderer side once the LocalFrame is created. This means that if
LocalMainFrame is requested before the renderer is created, any
calls sent along the interface are effectively dropped. I tried adding
a DCHECK in GetAssociatedLocalMainFrame() that it's only called if
IsRenderFrameCreated() is true, but that hits in tests.

BUG=1154852
TEST=comment change only

Change-Id: Id602b1883c7b554f07fc50ecc78c7fa8e041602b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2585306Reviewed-by: default avatarDave Tapuska <dtapuska@chromium.org>
Commit-Queue: Scott Violet <sky@chromium.org>
Cr-Commit-Position: refs/heads/master@{#835814}
parent 56da868d
...@@ -4499,8 +4499,8 @@ void RenderFrameHostImpl::UpdateBrowserControlsState( ...@@ -4499,8 +4499,8 @@ void RenderFrameHostImpl::UpdateBrowserControlsState(
bool animate) { bool animate) {
DCHECK(frame_tree_node_->IsMainFrame()); DCHECK(frame_tree_node_->IsMainFrame());
// TODO(https://crbug.com/1154852): Don't update browser control state for a // TODO(https://crbug.com/1154852): Asking for the LocalMainFrame interface
// frame that hasn't been created yet. // before the RenderFrame is created is racy.
if (!IsRenderFrameCreated()) if (!IsRenderFrameCreated())
return; return;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment