diff options
| author | Ben Murdoch <benm@google.com> | 2011-05-24 11:24:40 +0100 |
|---|---|---|
| committer | Ben Murdoch <benm@google.com> | 2011-06-02 09:53:15 +0100 |
| commit | 81bc750723a18f21cd17d1b173cd2a4dda9cea6e (patch) | |
| tree | 7a9e5ed86ff429fd347a25153107221543909b19 /Source/WebCore/plugins/qt | |
| parent | 94088a6d336c1dd80a1e734af51e96abcbb689a7 (diff) | |
| download | external_webkit-81bc750723a18f21cd17d1b173cd2a4dda9cea6e.zip external_webkit-81bc750723a18f21cd17d1b173cd2a4dda9cea6e.tar.gz external_webkit-81bc750723a18f21cd17d1b173cd2a4dda9cea6e.tar.bz2 | |
Merge WebKit at r80534: Intial merge by Git
Change-Id: Ia7a83357124c9e1cdb1debf55d9661ec0bd09a61
Diffstat (limited to 'Source/WebCore/plugins/qt')
| -rw-r--r-- | Source/WebCore/plugins/qt/PluginViewQt.cpp | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/Source/WebCore/plugins/qt/PluginViewQt.cpp b/Source/WebCore/plugins/qt/PluginViewQt.cpp index 4dc4e15..611abb9 100644 --- a/Source/WebCore/plugins/qt/PluginViewQt.cpp +++ b/Source/WebCore/plugins/qt/PluginViewQt.cpp @@ -68,7 +68,9 @@ #include "Settings.h" #include "npruntime_impl.h" #include "qwebpage_p.h" +#if USE(JSC) #include "runtime_root.h" +#endif #include <QApplication> #include <QDesktopWidget> @@ -88,7 +90,9 @@ #include <runtime/JSValue.h> using JSC::ExecState; +#if USE(JSC) using JSC::Interpreter; +#endif using JSC::JSLock; using JSC::JSObject; using JSC::UString; @@ -137,6 +141,10 @@ void PluginView::updatePluginWidget() if (m_windowRect == oldWindowRect && m_clipRect == oldClipRect) return; + // The plugin had a zero width or height before but was resized, we need to show it again. + if (oldWindowRect.isEmpty()) + show(); + if (!m_isWindowed && m_windowRect.size() != oldWindowRect.size()) { #if defined(MOZ_PLATFORM_MAEMO) && (MOZ_PLATFORM_MAEMO >= 5) // On Maemo5, Flash always renders to 16-bit buffer @@ -171,7 +179,10 @@ void PluginView::updatePluginWidget() if (!m_platformLayer) { // Make sure we get repainted afterwards. This is necessary for downward // scrolling to move the plugin widget properly. - invalidate(); + // Note that we don't invalidate the frameRect() here. This is because QWebFrame::renderRelativeCoords() + // imitates ScrollView and adds the scroll offset back on to the rect we damage here (making the co-ordinates absolute + // to the frame again) before passing it to FrameView. + frameView->invalidateRect(m_windowRect); } } @@ -938,7 +949,9 @@ bool PluginView::platformStart() #endif } - show(); + // If the width and the height are not zero we show the PluginView. + if (!frameRect().isEmpty()) + show(); NPSetWindowCallbackStruct* wsi = new NPSetWindowCallbackStruct(); wsi->type = 0; |
