Diff
Modified: trunk/Source/WebCore/ChangeLog (150699 => 150700)
--- trunk/Source/WebCore/ChangeLog 2013-05-26 02:27:32 UTC (rev 150699)
+++ trunk/Source/WebCore/ChangeLog 2013-05-26 02:48:46 UTC (rev 150700)
@@ -1,5 +1,23 @@
2013-05-25 Andreas Kling <akl...@apple.com>
+ PluginDocument::pluginNode() should be pluginElement() instead.
+ <http://webkit.org/b/116774>
+
+ Reviewed by Anders Carlsson.
+
+ Make PluginDocument hand out a HTMLPlugInElement* instead of a Node*.
+
+ * dom/Document.cpp:
+ (WebCore::eventTargetNodeForDocument):
+ * html/PluginDocument.h:
+ * html/PluginDocument.cpp:
+ (WebCore::PluginDocumentParser::createDocumentStructure):
+ (WebCore::PluginDocument::pluginWidget):
+ (WebCore::PluginDocument::setPluginElement):
+ (WebCore::PluginDocument::detach):
+
+2013-05-25 Andreas Kling <akl...@apple.com>
+
Remove Document::getFocusableNodes().
<http://webkit.org/b/116773>
Modified: trunk/Source/WebCore/WebCore.exp.in (150699 => 150700)
--- trunk/Source/WebCore/WebCore.exp.in 2013-05-26 02:27:32 UTC (rev 150699)
+++ trunk/Source/WebCore/WebCore.exp.in 2013-05-26 02:48:46 UTC (rev 150700)
@@ -329,7 +329,6 @@
__ZN7WebCore14FrameSelectionC1EPNS_5FrameE
__ZN7WebCore14LoaderStrategy21resourceLoadSchedulerEv
__ZN7WebCore14LoaderStrategy25loadResourceSynchronouslyEPNS_17NetworkingContextEmRKNS_15ResourceRequestENS_17StoredCredentialsENS_22ClientCredentialPolicyERNS_13ResourceErrorERNS_16ResourceResponseERN3WTF6VectorIcLm0ENSC_15CrashOnOverflowEEE
-__ZN7WebCore14PluginDocument10pluginNodeEv
__ZN7WebCore14PluginDocument12pluginWidgetEv
__ZN7WebCore14ResourceBuffer12createNSDataEv
__ZN7WebCore14ResourceBuffer6appendEPKcj
Modified: trunk/Source/WebCore/dom/Document.cpp (150699 => 150700)
--- trunk/Source/WebCore/dom/Document.cpp 2013-05-26 02:27:32 UTC (rev 150699)
+++ trunk/Source/WebCore/dom/Document.cpp 2013-05-26 02:48:46 UTC (rev 150700)
@@ -100,6 +100,7 @@
#include "HTMLNameCollection.h"
#include "HTMLNames.h"
#include "HTMLParserIdioms.h"
+#include "HTMLPlugInElement.h"
#include "HTMLStyleElement.h"
#include "HTMLTitleElement.h"
#include "HTTPParsers.h"
@@ -5770,7 +5771,7 @@
Node* node = doc->focusedNode();
if (!node && doc->isPluginDocument()) {
PluginDocument* pluginDocument = toPluginDocument(doc);
- node = pluginDocument->pluginNode();
+ node = pluginDocument->pluginElement();
}
if (!node && doc->isHTMLDocument())
node = doc->body();
Modified: trunk/Source/WebCore/html/PluginDocument.cpp (150699 => 150700)
--- trunk/Source/WebCore/html/PluginDocument.cpp 2013-05-26 02:27:32 UTC (rev 150699)
+++ trunk/Source/WebCore/html/PluginDocument.cpp 2013-05-26 02:48:46 UTC (rev 150700)
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2006, 2008 Apple Inc. All rights reserved.
+ * Copyright (C) 2006, 2008, 2013 Apple Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -34,7 +34,6 @@
#include "HTMLEmbedElement.h"
#include "HTMLHtmlElement.h"
#include "HTMLNames.h"
-#include "NodeList.h"
#include "Page.h"
#include "RawDataDocumentParser.h"
#include "RenderEmbeddedObject.h"
@@ -96,7 +95,7 @@
if (loader)
m_embedElement->setAttribute(typeAttr, loader->writer()->mimeType());
- toPluginDocument(document())->setPluginNode(m_embedElement);
+ toPluginDocument(document())->setPluginElement(m_embedElement);
body->appendChild(embedElement, IGNORE_EXCEPTION);
}
@@ -150,22 +149,22 @@
Widget* PluginDocument::pluginWidget()
{
- if (m_pluginNode && m_pluginNode->renderer()) {
- ASSERT(m_pluginNode->renderer()->isEmbeddedObject());
- return toRenderEmbeddedObject(m_pluginNode->renderer())->widget();
+ if (m_pluginElement && m_pluginElement->renderer()) {
+ ASSERT(m_pluginElement->renderer()->isEmbeddedObject());
+ return toRenderEmbeddedObject(m_pluginElement->renderer())->widget();
}
return 0;
}
-Node* PluginDocument::pluginNode()
+void PluginDocument::setPluginElement(PassRefPtr<HTMLPlugInElement> element)
{
- return m_pluginNode.get();
+ m_pluginElement = element;
}
void PluginDocument::detach()
{
- // Release the plugin node so that we don't have a circular reference.
- m_pluginNode = 0;
+ // Release the plugin Element so that we don't have a circular reference.
+ m_pluginElement = 0;
if (FrameLoader* loader = frame()->loader())
loader->client()->redirectDataToPlugin(0);
HTMLDocument::detach();
Modified: trunk/Source/WebCore/html/PluginDocument.h (150699 => 150700)
--- trunk/Source/WebCore/html/PluginDocument.h 2013-05-26 02:27:32 UTC (rev 150699)
+++ trunk/Source/WebCore/html/PluginDocument.h 2013-05-26 02:48:46 UTC (rev 150700)
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2006, 2008, 2009 Apple Inc. All rights reserved.
+ * Copyright (C) 2006, 2008, 2009, 2013 Apple Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -29,7 +29,7 @@
namespace WebCore {
-class Node;
+class HTMLPlugInElement;
class Widget;
class PluginDocument FINAL : public HTMLDocument {
@@ -39,10 +39,10 @@
return adoptRef(new PluginDocument(frame, url));
}
- void setPluginNode(Node* pluginNode) { m_pluginNode = pluginNode; }
+ void setPluginElement(PassRefPtr<HTMLPlugInElement>);
Widget* pluginWidget();
- Node* pluginNode();
+ HTMLPlugInElement* pluginElement() { return m_pluginElement.get(); }
virtual void detach() OVERRIDE;
@@ -58,7 +58,7 @@
void setShouldLoadPluginManually(bool loadManually) { m_shouldLoadPluginManually = loadManually; }
bool m_shouldLoadPluginManually;
- RefPtr<Node> m_pluginNode;
+ RefPtr<HTMLPlugInElement> m_pluginElement;
};
inline PluginDocument* toPluginDocument(Document* document)
Modified: trunk/Source/WebKit2/ChangeLog (150699 => 150700)
--- trunk/Source/WebKit2/ChangeLog 2013-05-26 02:27:32 UTC (rev 150699)
+++ trunk/Source/WebKit2/ChangeLog 2013-05-26 02:48:46 UTC (rev 150700)
@@ -1,3 +1,13 @@
+2013-05-25 Andreas Kling <akl...@apple.com>
+
+ PluginDocument::pluginNode() should be pluginElement() instead.
+ <http://webkit.org/b/116774>
+
+ Reviewed by Anders Carlsson.
+
+ * WebProcess/WebPage/WebPage.cpp:
+ (WebKit::WebPage::focusedPluginViewForFrame):
+
2013-05-25 Simon Fraser <simon.fra...@apple.com>
Unprefix Page Visibility API
Modified: trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp (150699 => 150700)
--- trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp 2013-05-26 02:27:32 UTC (rev 150699)
+++ trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp 2013-05-26 02:48:46 UTC (rev 150700)
@@ -744,7 +744,7 @@
PluginDocument* pluginDocument = static_cast<PluginDocument*>(frame->document());
- if (pluginDocument->focusedNode() != pluginDocument->pluginNode())
+ if (pluginDocument->focusedNode() != pluginDocument->pluginElement())
return 0;
PluginView* pluginView = static_cast<PluginView*>(pluginDocument->pluginWidget());