Upstream version 5.34.104.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / Source / web / WebHelperPluginImpl.cpp
index 163e40b..a63f4ca 100644 (file)
@@ -40,7 +40,7 @@
 #include "WebViewClient.h"
 #include "WebViewImpl.h"
 #include "WebWidgetClient.h"
-#include "core/dom/NodeList.h"
+#include "core/html/HTMLCollection.h"
 #include "core/html/HTMLPlugInElement.h"
 #include "core/loader/EmptyClients.h"
 #include "core/loader/FrameLoadRequest.h"
@@ -56,7 +56,7 @@ namespace blink {
 static const char documentStartLiteral[] = "<!DOCTYPE html><head><meta charset='UTF-8'></head><body>\n<object type=\"";
 static const char documentEndLiteral[] = "\"></object></body>\n";
 
-static void writeDocument(const String& pluginType, const WebURL& url, WebCore::FrameLoader& loader)
+static void writeDocument(const WebString& pluginType, const WebURL& url, WebCore::FrameLoader& loader)
 {
     RefPtr<SharedBuffer> data = SharedBuffer::create();
     data->append(documentStartLiteral, sizeof(documentStartLiteral) - 1);
@@ -180,13 +180,13 @@ WebPlugin* WebHelperPluginImpl::getPlugin()
 {
     ASSERT(m_page);
 
-    RefPtr<NodeList> objectElements = m_page->mainFrame()->document()->getElementsByTagName(WebCore::HTMLNames::objectTag.localName());
+    RefPtr<HTMLCollection> objectElements = m_page->mainFrame()->document()->getElementsByTagName(WebCore::HTMLNames::objectTag.localName());
     ASSERT(objectElements && objectElements->length() == 1);
     if (!objectElements || objectElements->length() < 1)
         return 0;
-    Node* node = objectElements->item(0);
-    ASSERT(node->hasTagName(WebCore::HTMLNames::objectTag));
-    WebCore::Widget* widget = toHTMLPlugInElement(node)->pluginWidget();
+    Element* element = objectElements->item(0);
+    ASSERT(element->hasTagName(WebCore::HTMLNames::objectTag));
+    WebCore::Widget* widget = toHTMLPlugInElement(element)->pluginWidget();
     if (!widget)
         return 0;
     WebPlugin* plugin = toWebPluginContainerImpl(widget)->plugin();
@@ -200,7 +200,7 @@ WebPlugin* WebHelperPluginImpl::getPlugin()
     return plugin;
 }
 
-bool WebHelperPluginImpl::initializePage(const String& pluginType, const WebDocument& hostDocument)
+bool WebHelperPluginImpl::initializePage(const WebString& pluginType, const WebDocument& hostDocument)
 {
     Page::PageClients pageClients;
     fillWithEmptyClients(pageClients);
@@ -208,7 +208,7 @@ bool WebHelperPluginImpl::initializePage(const String& pluginType, const WebDocu
     pageClients.chromeClient = m_chromeClient.get();
 
     m_page = adoptPtr(new Page(pageClients));
-    ASSERT(!m_page->settings().isScriptEnabled());
+    ASSERT(!m_page->settings().scriptEnabled());
     m_page->settings().setPluginsEnabled(true);
 
     m_webView->client()->initializeHelperPluginWebFrame(this);