| Index: third_party/WebKit/Source/core/frame/DOMWindow.cpp
|
| diff --git a/third_party/WebKit/Source/core/frame/DOMWindow.cpp b/third_party/WebKit/Source/core/frame/DOMWindow.cpp
|
| index 3d1f12c7efdbb84f6907c18c4ecbfee3775d98b8..914aa05bd5397eeaed884cfeda28206e4d7e4ba2 100644
|
| --- a/third_party/WebKit/Source/core/frame/DOMWindow.cpp
|
| +++ b/third_party/WebKit/Source/core/frame/DOMWindow.cpp
|
| @@ -130,8 +130,22 @@ DOMWindow* DOMWindow::anonymousIndexedGetter(uint32_t index) const
|
| if (!frame())
|
| return nullptr;
|
|
|
| - Frame* child = frame()->tree().scopedChild(index);
|
| - return child ? child->domWindow() : nullptr;
|
| + Frame* childFrame = frame()->tree().scopedChild(index);
|
| + if (!childFrame)
|
| + return nullptr;
|
| +
|
| + DOMWindow* childWindow = childFrame->domWindow();
|
| + if (childWindow && childWindow->isLocalDOMWindow()) {
|
| + LocalFrame* targetFrame = blink::toLocalDOMWindow(childWindow)->frame();
|
| + if (targetFrame) {
|
| + // Notify the loader's client if the initial document has been accessed.
|
| + if (targetFrame->loader().stateMachine()->isDisplayingInitialEmptyDocument()) {
|
| + targetFrame->loader().didAccessInitialDocument();
|
| + }
|
| + }
|
| + }
|
| +
|
| + return childWindow;
|
| }
|
|
|
| bool DOMWindow::isCurrentlyDisplayedInFrame() const
|
|
|