Chromium Code Reviews| Index: Source/core/html/HTMLFrameOwnerElement.cpp |
| diff --git a/Source/core/html/HTMLFrameOwnerElement.cpp b/Source/core/html/HTMLFrameOwnerElement.cpp |
| index 5ebb4b8f4c7bf91a31cee1f4b671af40f206152d..a28071d57451c4df16524876f76660cce4f9cd54 100644 |
| --- a/Source/core/html/HTMLFrameOwnerElement.cpp |
| +++ b/Source/core/html/HTMLFrameOwnerElement.cpp |
| @@ -51,7 +51,7 @@ RenderPart* HTMLFrameOwnerElement::renderPart() const |
| return toRenderPart(renderer()); |
| } |
| -void HTMLFrameOwnerElement::setContentFrame(LocalFrame& frame) |
| +void HTMLFrameOwnerElement::setContentFrame(Frame& frame) |
| { |
| // Make sure we will not end up with two frames referencing the same owner element. |
| ASSERT(!m_contentFrame || m_contentFrame->ownerElement() != this); |
| @@ -80,9 +80,10 @@ void HTMLFrameOwnerElement::disconnectContentFrame() |
| // unload event in the subframe which could execute script that could then |
| // reach up into this document and then attempt to look back down. We should |
| // see if this behavior is really needed as Gecko does not allow this. |
| - if (LocalFrame* frame = contentFrame()) { |
| - RefPtr<LocalFrame> protect(frame); |
| - frame->loader().frameDetached(); |
| + if (Frame* frame = contentFrame()) { |
| + RefPtr<Frame> protect(frame); |
| + if (frame->isLocalFrame()) |
| + toLocalFrame(frame)->loader().frameDetached(); |
|
dcheng
2014/03/17 18:17:44
Do we need a FIXME here? How are we planning on tr
kenrb
2014/03/18 20:01:19
I don't know exactly what attachment and detachmen
|
| frame->disconnectOwnerElement(); |
| } |
| } |
| @@ -124,8 +125,8 @@ SVGDocument* HTMLFrameOwnerElement::getSVGDocument(ExceptionState& exceptionStat |
| bool HTMLFrameOwnerElement::loadOrRedirectSubframe(const KURL& url, const AtomicString& frameName, bool lockBackForwardList) |
| { |
| RefPtr<LocalFrame> parentFrame = document().frame(); |
| - if (contentFrame()) { |
| - contentFrame()->navigationScheduler().scheduleLocationChange(&document(), url.string(), Referrer(document().outgoingReferrer(), document().referrerPolicy()), lockBackForwardList); |
| + if (contentFrame() && contentFrame()->isLocalFrame()) { |
|
dcheng
2014/03/17 18:17:44
Similar comment to my earlier comment in HTMLFrame
kenrb
2014/03/18 20:01:19
I've added a FIXME here. I don't know yet if Remot
|
| + toLocalFrame(contentFrame())->navigationScheduler().scheduleLocationChange(&document(), url.string(), Referrer(document().outgoingReferrer(), document().referrerPolicy()), lockBackForwardList); |
| return true; |
| } |