diff options
author | Ben Murdoch <benm@google.com> | 2010-07-22 15:37:06 +0100 |
---|---|---|
committer | Ben Murdoch <benm@google.com> | 2010-07-27 10:20:25 +0100 |
commit | 967717af5423377c967781471ee106e2bb4e11c8 (patch) | |
tree | 1e701dc0a12f7f07cce1df4a7681717de77a211b /WebCore/plugins | |
parent | dcc30a9fca45f634b1d3a12b276d3a0ccce99fc3 (diff) | |
download | external_webkit-967717af5423377c967781471ee106e2bb4e11c8.zip external_webkit-967717af5423377c967781471ee106e2bb4e11c8.tar.gz external_webkit-967717af5423377c967781471ee106e2bb4e11c8.tar.bz2 |
Merge WebKit at r63859 : Initial merge by git.
Change-Id: Ie8096c63ec7c991c9a9cba8bdd9c3b74a3b8ed62
Diffstat (limited to 'WebCore/plugins')
-rw-r--r-- | WebCore/plugins/PluginStream.cpp | 2 | ||||
-rw-r--r-- | WebCore/plugins/PluginViewBase.h (renamed from WebCore/plugins/PluginWidget.h) | 21 | ||||
-rw-r--r-- | WebCore/plugins/mac/PluginWidgetMac.mm | 49 | ||||
-rw-r--r-- | WebCore/plugins/win/PluginViewWin.cpp | 6 |
4 files changed, 14 insertions, 64 deletions
diff --git a/WebCore/plugins/PluginStream.cpp b/WebCore/plugins/PluginStream.cpp index bdf7a40..8d7a561 100644 --- a/WebCore/plugins/PluginStream.cpp +++ b/WebCore/plugins/PluginStream.cpp @@ -366,6 +366,8 @@ void PluginStream::deliverData() deliveryBytes = m_pluginFuncs->write(m_instance, &m_stream, m_offset, dataLength, (void*)data); if (deliveryBytes < 0) { LOG_PLUGIN_NET_ERROR(); + if (m_loader) + m_loader->setDefersLoading(false); cancelAndDestroyStream(NPRES_NETWORK_ERR); return; } diff --git a/WebCore/plugins/PluginWidget.h b/WebCore/plugins/PluginViewBase.h index 7a76fc1..9d3f463 100644 --- a/WebCore/plugins/PluginWidget.h +++ b/WebCore/plugins/PluginViewBase.h @@ -30,26 +30,21 @@ namespace WebCore { -class PluginWidget : public Widget { - +// PluginViewBase is a widget that all plug-in views inherit from, both in Webkit and WebKit2. +// It's intended as a stopgap measure until we can merge all plug-in views into a single plug-in view. +class PluginViewBase : public Widget { public: - PluginWidget(PlatformWidget widget = 0) : Widget(widget) { } #if USE(ACCELERATED_COMPOSITING) - PlatformLayer* platformLayer() const; + virtual PlatformLayer* platformLayer() const { return 0; } #endif + +protected: + PluginViewBase(PlatformWidget widget) : Widget(widget) { } private: - virtual void invalidateRect(const IntRect&); - virtual bool isPluginWidget() const { return true; } + virtual bool isPluginViewBase() const { return true; } }; -#if USE(ACCELERATED_COMPOSITING) && !PLATFORM(MAC) -inline PlatformLayer* PluginWidget::platformLayer() const -{ - return 0; -} -#endif - } // namespace WebCore #endif // PluginWidget_h diff --git a/WebCore/plugins/mac/PluginWidgetMac.mm b/WebCore/plugins/mac/PluginWidgetMac.mm deleted file mode 100644 index f407928..0000000 --- a/WebCore/plugins/mac/PluginWidgetMac.mm +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Copyright (C) 2010 Apple Inc. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' AND ANY - * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS - * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ - -#include "config.h" -#include "PluginWidget.h" - -#if USE(ACCELERATED_COMPOSITING) -@interface NSView (WebKitSecretsWebCoreKnowsAbout) -- (CALayer *)pluginLayer; -@end -#endif -namespace WebCore { - -void PluginWidget::invalidateRect(const IntRect& rect) -{ - [platformWidget() setNeedsDisplayInRect:rect]; -} - -#if USE(ACCELERATED_COMPOSITING) -PlatformLayer* PluginWidget::platformLayer() const -{ - if (![platformWidget() respondsToSelector:@selector(pluginLayer)]) - return 0; - - return [platformWidget() pluginLayer]; -} -#endif -} // namespace WebCore diff --git a/WebCore/plugins/win/PluginViewWin.cpp b/WebCore/plugins/win/PluginViewWin.cpp index 1765939..8dbb04b 100644 --- a/WebCore/plugins/win/PluginViewWin.cpp +++ b/WebCore/plugins/win/PluginViewWin.cpp @@ -30,6 +30,8 @@ #include "BitmapImage.h" #include "Bridge.h" +#include "Chrome.h" +#include "ChromeClient.h" #include "Document.h" #include "DocumentLoader.h" #include "Element.h" @@ -656,7 +658,6 @@ void PluginView::handleKeyboardEvent(KeyboardEvent* event) } #if !OS(WINCE) -extern HCURSOR lastSetCursor; extern bool ignoreNextSetCursor; #endif @@ -727,7 +728,8 @@ void PluginView::handleMouseEvent(MouseEvent* event) // Currently, Widget::setCursor is always called after this function in EventHandler.cpp // and since we don't want that we set ignoreNextSetCursor to true here to prevent that. ignoreNextSetCursor = true; - lastSetCursor = ::GetCursor(); + if (Page* page = m_parentFrame->page()) + page->chrome()->client()->setLastSetCursorToCurrentCursor(); #endif } |