Index: Source/web/WebViewImpl.cpp |
diff --git a/Source/web/WebViewImpl.cpp b/Source/web/WebViewImpl.cpp |
index 80ff79a1e3ec10aa6bda8e121228e161eae2d7f4..969f20ad441e0e7080850a1495e4bc075a9033e5 100644 |
--- a/Source/web/WebViewImpl.cpp |
+++ b/Source/web/WebViewImpl.cpp |
@@ -49,6 +49,7 @@ |
#include "core/frame/FrameView.h" |
#include "core/frame/LocalFrame.h" |
#include "core/frame/PinchViewport.h" |
+#include "core/frame/RemoteFrame.h" |
#include "core/frame/Settings.h" |
#include "core/frame/SmartClip.h" |
#include "core/html/HTMLInputElement.h" |
@@ -1584,6 +1585,9 @@ void WebViewImpl::resize(const WebSize& newSize) |
if (m_shouldAutoResize || m_size == newSize) |
return; |
+ if (!mainFrameImpl()) |
dcheng
2014/06/20 20:49:12
Being less familiar with the rendering paths, is t
nasko
2014/06/20 21:09:53
I'll leave that for Ken to give input on.
kenrb
2014/06/23 15:21:18
Most of the places that access the top-level Frame
|
+ return; |
+ |
FrameView* view = mainFrameImpl()->frameView(); |
if (!view) |
return; |
@@ -2106,7 +2110,11 @@ WebTextInputInfo WebViewImpl::textInputInfo() |
{ |
WebTextInputInfo info; |
- LocalFrame* focused = toLocalFrame(focusedWebCoreFrame()); |
+ Frame* focusedFrame = focusedWebCoreFrame(); |
+ if (focusedFrame->isRemoteFrame()) |
+ return info; |
+ |
+ LocalFrame* focused = toLocalFrame(focusedFrame); |
if (!focused) |
return info; |
@@ -2521,7 +2529,10 @@ WebFrame* WebViewImpl::findFrameByName( |
WebFrame* WebViewImpl::focusedFrame() |
{ |
- return WebLocalFrameImpl::fromFrame(toLocalFrame(focusedWebCoreFrame())); |
+ Frame* frame = focusedWebCoreFrame(); |
+ if (frame->isRemoteFrame()) |
dcheng
2014/06/20 20:49:12
You can use WebFrame::fromFrame now, so you don't
nasko
2014/06/20 21:09:53
Yay! ?!
|
+ return WebRemoteFrameImpl::fromFrame(toRemoteFrame(*frame)); |
+ return WebLocalFrameImpl::fromFrame(toLocalFrame(frame)); |
} |
void WebViewImpl::setFocusedFrame(WebFrame* frame) |