| Index: Source/web/WebPluginContainerImpl.cpp
|
| diff --git a/Source/web/WebPluginContainerImpl.cpp b/Source/web/WebPluginContainerImpl.cpp
|
| index c3086fcb33fb1344e82f1c65d2e99e7f44260ec6..1f77fd00662e66a03be3da8ed006a621a8fb54de 100644
|
| --- a/Source/web/WebPluginContainerImpl.cpp
|
| +++ b/Source/web/WebPluginContainerImpl.cpp
|
| @@ -267,7 +267,7 @@ void WebPluginContainerImpl::setPlugin(WebPlugin* plugin)
|
|
|
| float WebPluginContainerImpl::deviceScaleFactor()
|
| {
|
| - Page* page = m_element->document()->page();
|
| + Page* page = m_element->document().page();
|
| if (!page)
|
| return 1.0;
|
| return page->deviceScaleFactor();
|
| @@ -275,7 +275,7 @@ float WebPluginContainerImpl::deviceScaleFactor()
|
|
|
| float WebPluginContainerImpl::pageScaleFactor()
|
| {
|
| - Page* page = m_element->document()->page();
|
| + Page* page = m_element->document().page();
|
| if (!page)
|
| return 1.0;
|
| return page->pageScaleFactor();
|
| @@ -283,7 +283,7 @@ float WebPluginContainerImpl::pageScaleFactor()
|
|
|
| float WebPluginContainerImpl::pageZoomFactor()
|
| {
|
| - Frame* frame = m_element->document()->frame();
|
| + Frame* frame = m_element->document().frame();
|
| if (!frame)
|
| return 1.0;
|
| return frame->pageZoomFactor();
|
| @@ -417,7 +417,7 @@ void WebPluginContainerImpl::allowScriptObjects()
|
|
|
| void WebPluginContainerImpl::clearScriptObjects()
|
| {
|
| - Frame* frame = m_element->document()->frame();
|
| + Frame* frame = m_element->document().frame();
|
| if (!frame)
|
| return;
|
| frame->script()->cleanupScriptObjectsForPlugin(this);
|
| @@ -430,7 +430,7 @@ NPObject* WebPluginContainerImpl::scriptableObjectForElement()
|
|
|
| WebString WebPluginContainerImpl::executeScriptURL(const WebURL& url, bool popupsAllowed)
|
| {
|
| - Frame* frame = m_element->document()->frame();
|
| + Frame* frame = m_element->document().frame();
|
| if (!frame)
|
| return WebString();
|
|
|
| @@ -450,7 +450,7 @@ WebString WebPluginContainerImpl::executeScriptURL(const WebURL& url, bool popup
|
|
|
| void WebPluginContainerImpl::loadFrameRequest(const WebURLRequest& request, const WebString& target, bool notifyNeeded, void* notifyData)
|
| {
|
| - Frame* frame = m_element->document()->frame();
|
| + Frame* frame = m_element->document().frame();
|
| if (!frame || !frame->loader()->documentLoader())
|
| return; // FIXME: send a notification in this case?
|
|
|
| @@ -471,13 +471,13 @@ void WebPluginContainerImpl::loadFrameRequest(const WebURLRequest& request, cons
|
|
|
| void WebPluginContainerImpl::zoomLevelChanged(double zoomLevel)
|
| {
|
| - WebViewImpl* view = WebViewImpl::fromPage(m_element->document()->frame()->page());
|
| + WebViewImpl* view = WebViewImpl::fromPage(m_element->document().frame()->page());
|
| view->fullFramePluginZoomLevelChanged(zoomLevel);
|
| }
|
|
|
| bool WebPluginContainerImpl::isRectTopmost(const WebRect& rect)
|
| {
|
| - Frame* frame = m_element->document()->frame();
|
| + Frame* frame = m_element->document().frame();
|
| if (!frame)
|
| return false;
|
|
|
| @@ -500,9 +500,9 @@ void WebPluginContainerImpl::requestTouchEventType(TouchEventRequestType request
|
| return;
|
|
|
| if (requestType != TouchEventRequestTypeNone && m_touchEventRequestType == TouchEventRequestTypeNone)
|
| - m_element->document()->didAddTouchEventHandler(m_element);
|
| + m_element->document().didAddTouchEventHandler(m_element);
|
| else if (requestType == TouchEventRequestTypeNone && m_touchEventRequestType != TouchEventRequestTypeNone)
|
| - m_element->document()->didRemoveTouchEventHandler(m_element);
|
| + m_element->document().didRemoveTouchEventHandler(m_element);
|
| m_touchEventRequestType = requestType;
|
| }
|
|
|
| @@ -511,7 +511,7 @@ void WebPluginContainerImpl::setWantsWheelEvents(bool wantsWheelEvents)
|
| if (m_wantsWheelEvents == wantsWheelEvents)
|
| return;
|
| m_wantsWheelEvents = wantsWheelEvents;
|
| - if (Page* page = m_element->document()->page()) {
|
| + if (Page* page = m_element->document().page()) {
|
| if (ScrollingCoordinator* scrollingCoordinator = page->scrollingCoordinator()) {
|
| if (parent() && parent()->isFrameView())
|
| scrollingCoordinator->frameViewLayoutUpdated(toFrameView(parent()));
|
| @@ -608,7 +608,7 @@ void WebPluginContainerImpl::willDestroyPluginLoadObserver(WebPluginLoadObserver
|
| ScrollbarGroup* WebPluginContainerImpl::scrollbarGroup()
|
| {
|
| if (!m_scrollbarGroup)
|
| - m_scrollbarGroup = adoptPtr(new ScrollbarGroup(m_element->document()->frame()->view(), frameRect()));
|
| + m_scrollbarGroup = adoptPtr(new ScrollbarGroup(m_element->document().frame()->view(), frameRect()));
|
| return m_scrollbarGroup.get();
|
| }
|
|
|
| @@ -648,7 +648,7 @@ WebPluginContainerImpl::WebPluginContainerImpl(WebCore::HTMLPlugInElement* eleme
|
| WebPluginContainerImpl::~WebPluginContainerImpl()
|
| {
|
| if (m_touchEventRequestType != TouchEventRequestTypeNone)
|
| - m_element->document()->didRemoveTouchEventHandler(m_element);
|
| + m_element->document().didRemoveTouchEventHandler(m_element);
|
|
|
| for (size_t i = 0; i < m_pluginLoadObservers.size(); ++i)
|
| m_pluginLoadObservers[i]->clearPluginContainer();
|
| @@ -775,7 +775,7 @@ void WebPluginContainerImpl::handleKeyboardEvent(KeyboardEvent* event)
|
| }
|
|
|
| // Give the client a chance to issue edit comamnds.
|
| - WebViewImpl* view = WebViewImpl::fromPage(m_element->document()->frame()->page());
|
| + WebViewImpl* view = WebViewImpl::fromPage(m_element->document().frame()->page());
|
| if (m_webPlugin->supportsEditCommands() && view->client())
|
| view->client()->handleCurrentKeyboardEvent();
|
|
|
| @@ -882,13 +882,13 @@ WebCore::IntRect WebPluginContainerImpl::windowClipRect() const
|
| IntRect clipRect =
|
| convertToContainingWindow(IntRect(0, 0, width(), height()));
|
|
|
| - // document()->renderer() can be 0 when we receive messages from the
|
| + // document().renderer() can be 0 when we receive messages from the
|
| // plugins while we are destroying a frame.
|
| - if (m_element->renderer()->document()->renderer()) {
|
| + if (m_element->renderer()->document().renderer()) {
|
| // Take our element and get the clip rect from the enclosing layer and
|
| // frame view.
|
| clipRect.intersect(
|
| - m_element->document()->view()->windowClipRectForFrameOwner(m_element, true));
|
| + m_element->document().view()->windowClipRectForFrameOwner(m_element, true));
|
| }
|
|
|
| return clipRect;
|
|
|