summaryrefslogtreecommitdiff
path: root/Source/WebCore/html/HTMLPlugInElement.cpp
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@digia.com>2012-10-17 16:21:14 +0200
committerSimon Hausmann <simon.hausmann@digia.com>2012-10-17 16:21:14 +0200
commit8995b83bcbfbb68245f779b64e5517627c6cc6ea (patch)
tree17985605dab9263cc2444bd4d45f189e142cca7c /Source/WebCore/html/HTMLPlugInElement.cpp
parentb9c9652036d5e9f1e29c574f40bc73a35c81ace6 (diff)
downloadqtwebkit-8995b83bcbfbb68245f779b64e5517627c6cc6ea.tar.gz
Imported WebKit commit cf4f8fc6f19b0629f51860cb2d4b25e139d07e00 (http://svn.webkit.org/repository/webkit/trunk@131592)
New snapshot that includes the build fixes for Mac OS X 10.6 and earlier as well as the previously cherry-picked changes
Diffstat (limited to 'Source/WebCore/html/HTMLPlugInElement.cpp')
-rw-r--r--Source/WebCore/html/HTMLPlugInElement.cpp14
1 files changed, 11 insertions, 3 deletions
diff --git a/Source/WebCore/html/HTMLPlugInElement.cpp b/Source/WebCore/html/HTMLPlugInElement.cpp
index 1b5843483..9947a736e 100644
--- a/Source/WebCore/html/HTMLPlugInElement.cpp
+++ b/Source/WebCore/html/HTMLPlugInElement.cpp
@@ -35,6 +35,7 @@
#include "Page.h"
#include "PluginViewBase.h"
#include "RenderEmbeddedObject.h"
+#include "RenderSnapshottedPlugIn.h"
#include "RenderWidget.h"
#include "Settings.h"
#include "Widget.h"
@@ -55,6 +56,7 @@ HTMLPlugInElement::HTMLPlugInElement(const QualifiedName& tagName, Document* doc
, m_NPObject(0)
#endif
, m_isCapturingMouseEvents(false)
+ , m_displayState(Playing)
{
}
@@ -176,9 +178,15 @@ void HTMLPlugInElement::defaultEventHandler(Event* event)
// FIXME: Mouse down and scroll events are passed down to plug-in via custom code in EventHandler; these code paths should be united.
RenderObject* r = renderer();
- if (r && r->isEmbeddedObject() && toRenderEmbeddedObject(r)->showsUnavailablePluginIndicator()) {
- toRenderEmbeddedObject(r)->handleUnavailablePluginIndicatorEvent(event);
- return;
+ if (r && r->isEmbeddedObject()) {
+ if (toRenderEmbeddedObject(r)->showsUnavailablePluginIndicator()) {
+ toRenderEmbeddedObject(r)->handleUnavailablePluginIndicatorEvent(event);
+ return;
+ }
+ if (r->isSnapshottedPlugIn() && displayState() < Playing) {
+ toRenderSnapshottedPlugIn(r)->handleEvent(event);
+ return;
+ }
}
if (!r || !r->isWidget())