<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[185636] trunk/Source/WebKit</title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/185636">185636</a></dd>
<dt>Author</dt> <dd>commit-queue@webkit.org</dd>
<dt>Date</dt> <dd>2015-06-16 20:30:51 -0700 (Tue, 16 Jun 2015)</dd>
</dl>
<h3>Log Message</h3>
<pre>[Win] Implement WebViewGroup to support WebView::addxxxToGroup().
https://bugs.webkit.org/show_bug.cgi?id=145908
Patch by Hyungwook Lee <hyungwook.lee@navercorp.com> on 2015-06-16
Reviewed by Brent Fulgham.
Make WebViewGroup class sharing on Mac and Win port.
Source/WebKit:
* WebCoreSupport: Added.
* WebCoreSupport/WebViewGroup.cpp: Copied from Source/WebKit/mac/WebCoreSupport/WebViewGroup.mm.
* WebCoreSupport/WebViewGroup.h: Copied from Source/WebKit/mac/WebCoreSupport/WebViewGroup.h.
* WebKit.vcxproj/WebKit/WebKit.vcxproj:
* WebKit.vcxproj/WebKit/WebKit.vcxproj.filters:
* WebKit.vcxproj/WebKit/WebKitCommon.props:
* WebKit.xcodeproj/project.pbxproj:
Source/WebKit/mac:
* WebCoreSupport/WebViewGroup.h: Removed.
* WebCoreSupport/WebViewGroup.mm: Removed.
Source/WebKit/win:
* WebCoreSupport/WebVisitedLinkStore.cpp:
(visitedLinkStores):
(WebVisitedLinkStore::create):
(WebVisitedLinkStore::WebVisitedLinkStore):
(WebVisitedLinkStore::~WebVisitedLinkStore):
(WebVisitedLinkStore::setShouldTrackVisitedLinks):
(WebVisitedLinkStore::removeAllVisitedLinks):
(WebVisitedLinkStore::singleton): Deleted.
* WebCoreSupport/WebVisitedLinkStore.h:
* WebView.cpp:
(WebView::~WebView):
(WebView::initWithFrame):
(WebView::setGroupName):
(WebView::addVisitedLinks):
* WebView.h:</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebKitChangeLog">trunk/Source/WebKit/ChangeLog</a></li>
<li><a href="#trunkSourceWebKitWebKitvcxprojWebKitWebKitvcxproj">trunk/Source/WebKit/WebKit.vcxproj/WebKit/WebKit.vcxproj</a></li>
<li><a href="#trunkSourceWebKitWebKitvcxprojWebKitWebKitvcxprojfilters">trunk/Source/WebKit/WebKit.vcxproj/WebKit/WebKit.vcxproj.filters</a></li>
<li><a href="#trunkSourceWebKitWebKitvcxprojWebKitWebKitCommonprops">trunk/Source/WebKit/WebKit.vcxproj/WebKit/WebKitCommon.props</a></li>
<li><a href="#trunkSourceWebKitWebKitxcodeprojprojectpbxproj">trunk/Source/WebKit/WebKit.xcodeproj/project.pbxproj</a></li>
<li><a href="#trunkSourceWebKitmacChangeLog">trunk/Source/WebKit/mac/ChangeLog</a></li>
<li><a href="#trunkSourceWebKitwinChangeLog">trunk/Source/WebKit/win/ChangeLog</a></li>
<li><a href="#trunkSourceWebKitwinWebCoreSupportWebVisitedLinkStorecpp">trunk/Source/WebKit/win/WebCoreSupport/WebVisitedLinkStore.cpp</a></li>
<li><a href="#trunkSourceWebKitwinWebCoreSupportWebVisitedLinkStoreh">trunk/Source/WebKit/win/WebCoreSupport/WebVisitedLinkStore.h</a></li>
<li><a href="#trunkSourceWebKitwinWebViewcpp">trunk/Source/WebKit/win/WebView.cpp</a></li>
<li><a href="#trunkSourceWebKitwinWebViewh">trunk/Source/WebKit/win/WebView.h</a></li>
</ul>
<h3>Added Paths</h3>
<ul>
<li>trunk/Source/WebKit/WebCoreSupport/</li>
<li><a href="#trunkSourceWebKitWebCoreSupportWebViewGroupcpp">trunk/Source/WebKit/WebCoreSupport/WebViewGroup.cpp</a></li>
<li><a href="#trunkSourceWebKitWebCoreSupportWebViewGrouph">trunk/Source/WebKit/WebCoreSupport/WebViewGroup.h</a></li>
</ul>
<h3>Removed Paths</h3>
<ul>
<li><a href="#trunkSourceWebKitmacWebCoreSupportWebViewGrouph">trunk/Source/WebKit/mac/WebCoreSupport/WebViewGroup.h</a></li>
<li><a href="#trunkSourceWebKitmacWebCoreSupportWebViewGroupmm">trunk/Source/WebKit/mac/WebCoreSupport/WebViewGroup.mm</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebKitChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/ChangeLog (185635 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/ChangeLog        2015-06-17 02:54:34 UTC (rev 185635)
+++ trunk/Source/WebKit/ChangeLog        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -1,3 +1,20 @@
</span><ins>+2015-06-16 Hyungwook Lee <hyungwook.lee@navercorp.com>
+
+ [Win] Implement WebViewGroup to support WebView::addxxxToGroup().
+ https://bugs.webkit.org/show_bug.cgi?id=145908
+
+ Reviewed by Brent Fulgham.
+
+ Make WebViewGroup class sharing on Mac and Win port.
+
+ * WebCoreSupport: Added.
+ * WebCoreSupport/WebViewGroup.cpp: Copied from Source/WebKit/mac/WebCoreSupport/WebViewGroup.mm.
+ * WebCoreSupport/WebViewGroup.h: Copied from Source/WebKit/mac/WebCoreSupport/WebViewGroup.h.
+ * WebKit.vcxproj/WebKit/WebKit.vcxproj:
+ * WebKit.vcxproj/WebKit/WebKit.vcxproj.filters:
+ * WebKit.vcxproj/WebKit/WebKitCommon.props:
+ * WebKit.xcodeproj/project.pbxproj:
+
</ins><span class="cx"> 2015-06-09 Csaba Osztrogonác <ossy@webkit.org>
</span><span class="cx">
</span><span class="cx"> [cmake] Fix the style issues in cmake project files
</span></span></pre></div>
<a id="trunkSourceWebKitWebCoreSupportWebViewGroupcppfromrev185635trunkSourceWebKitmacWebCoreSupportWebViewGroupmm"></a>
<div class="copfile"><h4>Copied: trunk/Source/WebKit/WebCoreSupport/WebViewGroup.cpp (from rev 185635, trunk/Source/WebKit/mac/WebCoreSupport/WebViewGroup.mm) (0 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/WebCoreSupport/WebViewGroup.cpp         (rev 0)
+++ trunk/Source/WebKit/WebCoreSupport/WebViewGroup.cpp        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -0,0 +1,100 @@
</span><ins>+/*
+ * Copyright (C) 2014 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 "WebViewGroup.h"
+
+#include "WebStorageNamespaceProvider.h"
+#include "WebView.h"
+#include "WebVisitedLinkStore.h"
+#include <WebCore/UserContentController.h>
+#include <wtf/NeverDestroyed.h>
+#include <wtf/text/StringHash.h>
+
+using namespace WebCore;
+
+// Any named groups will live for the lifetime of the process, thanks to the reference held by the RefPtr.
+static HashMap<String, RefPtr<WebViewGroup>>& webViewGroups()
+{
+ static NeverDestroyed<HashMap<String, RefPtr<WebViewGroup>>> webViewGroups;
+
+ return webViewGroups;
+}
+
+RefPtr<WebViewGroup> WebViewGroup::getOrCreate(const String& name, const String& localStorageDatabasePath)
+{
+ if (name.isEmpty())
+ return adoptRef(new WebViewGroup(String(), localStorageDatabasePath));
+
+ auto& webViewGroup = webViewGroups().add(name, nullptr).iterator->value;
+ if (!webViewGroup)
+ webViewGroup = adoptRef(new WebViewGroup(name, localStorageDatabasePath));
+ else if (!webViewGroup->m_storageNamespaceProvider && webViewGroup->m_localStorageDatabasePath.isEmpty() && !localStorageDatabasePath.isEmpty())
+ webViewGroup->m_localStorageDatabasePath = localStorageDatabasePath;
+
+ return webViewGroup;
+}
+
+WebViewGroup* WebViewGroup::get(const String& name)
+{
+ ASSERT(!name.isEmpty());
+
+ return webViewGroups().get(name);
+}
+
+WebViewGroup::WebViewGroup(const String& name, const String& localStorageDatabasePath)
+ : m_name(name)
+ , m_localStorageDatabasePath(localStorageDatabasePath)
+ , m_userContentController(UserContentController::create())
+ , m_visitedLinkStore(WebVisitedLinkStore::create())
+{
+}
+
+WebViewGroup::~WebViewGroup()
+{
+ ASSERT(m_name.isEmpty());
+ ASSERT(m_webViews.isEmpty());
+}
+
+void WebViewGroup::addWebView(WebView *webView)
+{
+ ASSERT(!m_webViews.contains(webView));
+
+ m_webViews.add(webView);
+}
+
+void WebViewGroup::removeWebView(WebView *webView)
+{
+ ASSERT(m_webViews.contains(webView));
+
+ m_webViews.remove(webView);
+}
+
+StorageNamespaceProvider& WebViewGroup::storageNamespaceProvider()
+{
+ if (!m_storageNamespaceProvider)
+ m_storageNamespaceProvider = WebStorageNamespaceProvider::create(m_localStorageDatabasePath);
+
+ return *m_storageNamespaceProvider;
+}
</ins></span></pre></div>
<a id="trunkSourceWebKitWebCoreSupportWebViewGrouphfromrev185635trunkSourceWebKitmacWebCoreSupportWebViewGrouph"></a>
<div class="copfile"><h4>Copied: trunk/Source/WebKit/WebCoreSupport/WebViewGroup.h (from rev 185635, trunk/Source/WebKit/mac/WebCoreSupport/WebViewGroup.h) (0 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/WebCoreSupport/WebViewGroup.h         (rev 0)
+++ trunk/Source/WebKit/WebCoreSupport/WebViewGroup.h        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -0,0 +1,64 @@
</span><ins>+/*
+ * Copyright (C) 2014 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 <wtf/HashSet.h>
+#include <wtf/RefCounted.h>
+#include <wtf/text/WTFString.h>
+
+namespace WebCore {
+class StorageNamespaceProvider;
+class UserContentController;
+}
+
+class WebVisitedLinkStore;
+
+OBJC_CLASS WebView;
+
+class WebViewGroup : public RefCounted<WebViewGroup> {
+public:
+ static RefPtr<WebViewGroup> getOrCreate(const String& name, const String& localStorageDatabasePath);
+ ~WebViewGroup();
+
+ static WebViewGroup* get(const String& name);
+
+ void addWebView(WebView *);
+ void removeWebView(WebView *);
+
+ WebCore::StorageNamespaceProvider& storageNamespaceProvider();
+ WebCore::UserContentController& userContentController() { return m_userContentController.get(); }
+ WebVisitedLinkStore& visitedLinkStore() { return m_visitedLinkStore.get(); }
+
+private:
+ WebViewGroup(const String& name, const String& localStorageDatabasePath);
+
+ String m_name;
+ HashSet<WebView *> m_webViews;
+
+ String m_localStorageDatabasePath;
+ RefPtr<WebCore::StorageNamespaceProvider> m_storageNamespaceProvider;
+
+ Ref<WebCore::UserContentController> m_userContentController;
+ Ref<WebVisitedLinkStore> m_visitedLinkStore;
+};
</ins></span></pre></div>
<a id="trunkSourceWebKitWebKitvcxprojWebKitWebKitvcxproj"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/WebKit.vcxproj/WebKit/WebKit.vcxproj (185635 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/WebKit.vcxproj/WebKit/WebKit.vcxproj        2015-06-17 02:54:34 UTC (rev 185635)
+++ trunk/Source/WebKit/WebKit.vcxproj/WebKit/WebKit.vcxproj        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -297,6 +297,7 @@
</span><span class="cx"> <ClCompile Include="..\..\Storage\WebDatabaseProvider.cpp" />
</span><span class="cx"> <ClCompile Include="..\..\Storage\WebStorageNamespaceProvider.cpp" />
</span><span class="cx"> <ClCompile Include="..\..\cf\WebCoreSupport\WebInspectorClientCF.cpp" />
</span><ins>+ <ClCompile Include="..\..\WebCoreSupport\WebViewGroup.cpp" />
</ins><span class="cx"> <ClCompile Include="..\..\win\Plugins\npapi.cpp" />
</span><span class="cx"> <ClCompile Include="..\..\win\Plugins\PluginDatabase.cpp" />
</span><span class="cx"> <ClCompile Include="..\..\win\Plugins\PluginDebug.cpp" />
</span><span class="lines">@@ -450,6 +451,7 @@
</span><span class="cx"> <ClInclude Include="..\..\Storage\StorageTrackerClient.h" />
</span><span class="cx"> <ClInclude Include="..\..\Storage\WebDatabaseProvider.h" />
</span><span class="cx"> <ClInclude Include="..\..\Storage\WebStorageNamespaceProvider.h" />
</span><ins>+ <ClInclude Include="..\..\WebCoreSupport\WebViewGroup.h" />
</ins><span class="cx"> <ClInclude Include="..\..\win\Plugins\PluginDatabase.h" />
</span><span class="cx"> <ClInclude Include="..\..\win\Plugins\PluginDebug.h" />
</span><span class="cx"> <ClInclude Include="..\..\win\Plugins\PluginPackage.h" />
</span></span></pre></div>
<a id="trunkSourceWebKitWebKitvcxprojWebKitWebKitvcxprojfilters"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/WebKit.vcxproj/WebKit/WebKit.vcxproj.filters (185635 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/WebKit.vcxproj/WebKit/WebKit.vcxproj.filters        2015-06-17 02:54:34 UTC (rev 185635)
+++ trunk/Source/WebKit/WebKit.vcxproj/WebKit/WebKit.vcxproj.filters        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -333,6 +333,9 @@
</span><span class="cx"> <ClCompile Include="..\..\win\WebKitMessageLoop.cpp">
</span><span class="cx"> <Filter>Sources</Filter>
</span><span class="cx"> </ClCompile>
</span><ins>+ <ClCompile Include="..\..\WebCoreSupport\WebViewGroup.cpp">
+ <Filter>Sources</Filter>
+ </ClCompile>
</ins><span class="cx"> </ItemGroup>
</span><span class="cx"> <ItemGroup>
</span><span class="cx"> <ClInclude Include="..\..\win\WebCoreSupport\EmbeddedWidget.h">
</span><span class="lines">@@ -654,6 +657,9 @@
</span><span class="cx"> <ClInclude Include="..\..\win\WebKitMessageLoop.h">
</span><span class="cx"> <Filter>Header Files</Filter>
</span><span class="cx"> </ClInclude>
</span><ins>+ <ClInclude Include="..\..\WebCoreSupport\WebViewGroup.h">
+ <Filter>Header Files</Filter>
+ </ClInclude>
</ins><span class="cx"> </ItemGroup>
</span><span class="cx"> <ItemGroup>
</span><span class="cx"> <None Include="WebKitPostBuild.cmd" />
</span><span class="lines">@@ -746,4 +752,4 @@
</span><span class="cx"> <Filter>Sources\Plugins</Filter>
</span><span class="cx"> </MASM>
</span><span class="cx"> </ItemGroup>
</span><del>-</Project>
</del><ins>+</Project>
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkSourceWebKitWebKitvcxprojWebKitWebKitCommonprops"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/WebKit.vcxproj/WebKit/WebKitCommon.props (185635 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/WebKit.vcxproj/WebKit/WebKitCommon.props        2015-06-17 02:54:34 UTC (rev 185635)
+++ trunk/Source/WebKit/WebKit.vcxproj/WebKit/WebKitCommon.props        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -5,7 +5,7 @@
</span><span class="cx"> </PropertyGroup>
</span><span class="cx"> <ItemDefinitionGroup>
</span><span class="cx"> <ClCompile>
</span><del>- <AdditionalIncludeDirectories>$(ProjectDir);$(ProjectDir)\..\..\win;$(ProjectDir)\..\..\win\Plugins;$(ProjectDir)\..\..\win\WebCoreSupport;$(ProjectDir)\..\..\Storage;$(ConfigurationBuildDir)\include\WebKit;$(ConfigurationBuildDir)\Include;$(ConfigurationBuildDir)\Include\private;$(ConfigurationBuildDir)\Include\WebCore;$(ConfigurationBuildDir)\Include\WebCore\ForwardingHeaders;$(ConfigurationBuildDir)\Include\JavaScriptCore;$(ConfigurationBuildDir)\Include\private\JavaScriptCore;$(ConfigurationBuildDir)\obj$(PlatformArchitecture)\WebKit\DerivedSources;$(WebKit_Libraries)\Include;$(WebKit_Libraries)\Include\private;$(WebKit_Libraries)\Include\WebCore;$(WebKit_Libraries)\Include\WebCore\ForwardingHeaders;$(WebKit_Libraries)\include\sqlite;$(WebKit_Libraries)\Include\JavaScriptCore;$(WebKit_Libraries)\Include\private\JavaScriptCore;$(IntDir)include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</del><ins>+ <AdditionalIncludeDirectories>$(ProjectDir);$(ProjectDir)\..\..\win;$(ProjectDir)\..\..\win\Plugins;$(ProjectDir)\..\..\win\WebCoreSupport;$(ProjectDir)\..\..\Storage;$(ProjectDir)\..\..\WebCoreSupport;$(ConfigurationBuildDir)\include\WebKit;$(ConfigurationBuildDir)\Include;$(ConfigurationBuildDir)\Include\private;$(ConfigurationBuildDir)\Include\WebCore;$(ConfigurationBuildDir)\Include\WebCore\ForwardingHeaders;$(ConfigurationBuildDir)\Include\JavaScriptCore;$(ConfigurationBuildDir)\Include\private\JavaScriptCore;$(ConfigurationBuildDir)\obj$(PlatformArchitecture)\WebKit\DerivedSources;$(WebKit_Libraries)\Include;$(WebKit_Libraries)\Include\private;$(WebKit_Libraries)\Include\WebCore;$(WebKit_Libraries)\Include\WebCore\ForwardingHeaders;$(WebKit_Libraries)\include\sqlite;$(WebKit_Libraries)\Include\JavaScriptCore;$(WebKit_Libraries)\Include\private\JavaScriptCore;$(IntDir)include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ins><span class="cx"> <PreprocessorDefinitions>WEBKIT_EXPORTS;FRAMEWORK_NAME=WebKit;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</span><span class="cx"> <PrecompiledHeader>Use</PrecompiledHeader>
</span><span class="cx"> <PrecompiledHeaderFile>WebKitPrefix.h</PrecompiledHeaderFile>
</span><span class="lines">@@ -17,4 +17,4 @@
</span><span class="cx"> <DelayLoadDLLs>usp10.dll;comctl32.dll;version.dll;iphlpapi.dll;%(DelayLoadDLLs)</DelayLoadDLLs>
</span><span class="cx"> </Link>
</span><span class="cx"> </ItemDefinitionGroup>
</span><del>-</Project>
</del><ins>+</Project>
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkSourceWebKitWebKitxcodeprojprojectpbxproj"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/WebKit.xcodeproj/project.pbxproj (185635 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/WebKit.xcodeproj/project.pbxproj        2015-06-17 02:54:34 UTC (rev 185635)
+++ trunk/Source/WebKit/WebKit.xcodeproj/project.pbxproj        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -19,6 +19,8 @@
</span><span class="cx">                 0AB752380FA2E4DB00D7CBB1 /* WebNetscapeContainerCheckContextInfo.mm in Sources */ = {isa = PBXBuildFile; fileRef = 0AB752360FA2E4DB00D7CBB1 /* WebNetscapeContainerCheckContextInfo.mm */; };
</span><span class="cx">                 0AEBFF630F9FA8BE000D486B /* WebNetscapeContainerCheckPrivate.h in Headers */ = {isa = PBXBuildFile; fileRef = 0AEBFF610F9FA8BE000D486B /* WebNetscapeContainerCheckPrivate.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="cx">                 0AEBFF640F9FA8BE000D486B /* WebNetscapeContainerCheckPrivate.mm in Sources */ = {isa = PBXBuildFile; fileRef = 0AEBFF620F9FA8BE000D486B /* WebNetscapeContainerCheckPrivate.mm */; };
</span><ins>+                1430C12C1B2C5DF700DEA01D /* WebViewGroup.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1430C12A1B2C5DF700DEA01D /* WebViewGroup.cpp */; };
+                1430C12D1B2C5DF700DEA01D /* WebViewGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = 1430C12B1B2C5DF700DEA01D /* WebViewGroup.h */; };
</ins><span class="cx">                 14D8252F0AF955090004F057 /* WebChromeClient.h in Headers */ = {isa = PBXBuildFile; fileRef = 14D8252D0AF955090004F057 /* WebChromeClient.h */; };
</span><span class="cx">                 14D825300AF955090004F057 /* WebChromeClient.mm in Sources */ = {isa = PBXBuildFile; fileRef = 14D8252E0AF955090004F057 /* WebChromeClient.mm */; };
</span><span class="cx">                 1A2DBE9F0F251E3A0036F8A6 /* ProxyInstance.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A2DBE9D0F251E3A0036F8A6 /* ProxyInstance.h */; };
</span><span class="lines">@@ -76,8 +78,6 @@
</span><span class="cx">                 1AAF5D0F0EDDE7A7008D883D /* WebKitPluginAgent.defs in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF588A0EDCCEA3008D883D /* WebKitPluginAgent.defs */; };
</span><span class="cx">                 1AAF5FBF0EDE3A92008D883D /* WebHostedNetscapePluginView.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AAF5FBD0EDE3A92008D883D /* WebHostedNetscapePluginView.h */; };
</span><span class="cx">                 1AAF5FC00EDE3A92008D883D /* WebHostedNetscapePluginView.mm in Sources */ = {isa = PBXBuildFile; fileRef = 1AAF5FBE0EDE3A92008D883D /* WebHostedNetscapePluginView.mm */; };
</span><del>-                1AB1DAC118BC0232004B6A9F /* WebViewGroup.mm in Sources */ = {isa = PBXBuildFile; fileRef = 1AB1DABF18BC0232004B6A9F /* WebViewGroup.mm */; };
-                1AB1DAC218BC0232004B6A9F /* WebViewGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AB1DAC018BC0232004B6A9F /* WebViewGroup.h */; };
</del><span class="cx">                 1AC7176E1A26568A002E3115 /* WebVisitedLinkStore.mm in Sources */ = {isa = PBXBuildFile; fileRef = 1AC7176C1A26568A002E3115 /* WebVisitedLinkStore.mm */; };
</span><span class="cx">                 1AC7176F1A26568A002E3115 /* WebVisitedLinkStore.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AC7176D1A26568A002E3115 /* WebVisitedLinkStore.h */; };
</span><span class="cx">                 1AEA66D40DC6B1FF003D12BF /* WebNetscapePluginEventHandler.h in Headers */ = {isa = PBXBuildFile; fileRef = 1AEA66D20DC6B1FF003D12BF /* WebNetscapePluginEventHandler.h */; };
</span><span class="lines">@@ -475,6 +475,8 @@
</span><span class="cx">                 0AB752360FA2E4DB00D7CBB1 /* WebNetscapeContainerCheckContextInfo.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebNetscapeContainerCheckContextInfo.mm; sourceTree = "<group>"; };
</span><span class="cx">                 0AEBFF610F9FA8BE000D486B /* WebNetscapeContainerCheckPrivate.h */ = {isa = PBXFileReference; explicitFileType = sourcecode.c.h; fileEncoding = 4; path = WebNetscapeContainerCheckPrivate.h; sourceTree = "<group>"; };
</span><span class="cx">                 0AEBFF620F9FA8BE000D486B /* WebNetscapeContainerCheckPrivate.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebNetscapeContainerCheckPrivate.mm; sourceTree = "<group>"; };
</span><ins>+                1430C12A1B2C5DF700DEA01D /* WebViewGroup.cpp */ = {isa = PBXFileReference; explicitFileType = sourcecode.cpp.objcpp; fileEncoding = 4; name = WebViewGroup.cpp; path = WebCoreSupport/WebViewGroup.cpp; sourceTree = SOURCE_ROOT; };
+                1430C12B1B2C5DF700DEA01D /* WebViewGroup.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = WebViewGroup.h; path = WebCoreSupport/WebViewGroup.h; sourceTree = SOURCE_ROOT; };
</ins><span class="cx">                 14D8252D0AF955090004F057 /* WebChromeClient.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = WebChromeClient.h; sourceTree = "<group>"; };
</span><span class="cx">                 14D8252E0AF955090004F057 /* WebChromeClient.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebChromeClient.mm; sourceTree = "<group>"; };
</span><span class="cx">                 1A2DBE9D0F251E3A0036F8A6 /* ProxyInstance.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ProxyInstance.h; sourceTree = "<group>"; };
</span><span class="lines">@@ -529,8 +531,6 @@
</span><span class="cx">                 1AAF5D080EDDE71D008D883D /* WebKitPluginHostTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebKitPluginHostTypes.h; sourceTree = "<group>"; };
</span><span class="cx">                 1AAF5FBD0EDE3A92008D883D /* WebHostedNetscapePluginView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebHostedNetscapePluginView.h; sourceTree = "<group>"; };
</span><span class="cx">                 1AAF5FBE0EDE3A92008D883D /* WebHostedNetscapePluginView.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebHostedNetscapePluginView.mm; sourceTree = "<group>"; };
</span><del>-                1AB1DABF18BC0232004B6A9F /* WebViewGroup.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebViewGroup.mm; sourceTree = "<group>"; };
-                1AB1DAC018BC0232004B6A9F /* WebViewGroup.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebViewGroup.h; sourceTree = "<group>"; };
</del><span class="cx">                 1AC7176C1A26568A002E3115 /* WebVisitedLinkStore.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebVisitedLinkStore.mm; sourceTree = "<group>"; };
</span><span class="cx">                 1AC7176D1A26568A002E3115 /* WebVisitedLinkStore.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebVisitedLinkStore.h; sourceTree = "<group>"; };
</span><span class="cx">                 1AEA66D20DC6B1FF003D12BF /* WebNetscapePluginEventHandler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebNetscapePluginEventHandler.h; sourceTree = "<group>"; };
</span><span class="lines">@@ -1607,8 +1607,8 @@
</span><span class="cx">                                 2DD632C119E5D1F0002E9C7B /* WebSelectionServiceController.mm */,
</span><span class="cx">                                 93EB178E09F88D510091F8FF /* WebSystemInterface.h */,
</span><span class="cx">                                 93EB178C09F88D460091F8FF /* WebSystemInterface.mm */,
</span><del>-                                1AB1DAC018BC0232004B6A9F /* WebViewGroup.h */,
-                                1AB1DABF18BC0232004B6A9F /* WebViewGroup.mm */,
</del><ins>+                                1430C12A1B2C5DF700DEA01D /* WebViewGroup.cpp */,
+                                1430C12B1B2C5DF700DEA01D /* WebViewGroup.h */,
</ins><span class="cx">                                 1AC7176D1A26568A002E3115 /* WebVisitedLinkStore.h */,
</span><span class="cx">                                 1AC7176C1A26568A002E3115 /* WebVisitedLinkStore.mm */,
</span><span class="cx">                         );
</span><span class="lines">@@ -1746,7 +1746,6 @@
</span><span class="cx">                                 939810490824BF01008DF038 /* WebClipView.h in Headers */,
</span><span class="cx">                                 065AD5A30B0C32C7005A2B1D /* WebContextMenuClient.h in Headers */,
</span><span class="cx">                                 939810160824BF01008DF038 /* WebCoreStatistics.h in Headers */,
</span><del>-                                1AB1DAC218BC0232004B6A9F /* WebViewGroup.h in Headers */,
</del><span class="cx">                                 93E2A1A4123B0B3C009FE12A /* WebDashboardRegion.h in Headers */,
</span><span class="cx">                                 511F3FD70CECC88F00852565 /* WebDatabaseManagerClient.h in Headers */,
</span><span class="cx">                                 51AEDEF10CECF45700854328 /* WebDatabaseManagerInternal.h in Headers */,
</span><span class="lines">@@ -1815,6 +1814,7 @@
</span><span class="cx">                                 939810140824BF01008DF038 /* WebHistoryPrivate.h in Headers */,
</span><span class="cx">                                 1AAF5FBF0EDE3A92008D883D /* WebHostedNetscapePluginView.h in Headers */,
</span><span class="cx">                                 939810550824BF01008DF038 /* WebHTMLRepresentation.h in Headers */,
</span><ins>+                                1430C12D1B2C5DF700DEA01D /* WebViewGroup.h in Headers */,
</ins><span class="cx">                                 939810560824BF01008DF038 /* WebHTMLRepresentationPrivate.h in Headers */,
</span><span class="cx">                                 939810570824BF01008DF038 /* WebHTMLView.h in Headers */,
</span><span class="cx">                                 1A6B313D1A51F3A900422975 /* StorageTrackerClient.h in Headers */,
</span><span class="lines">@@ -2334,9 +2334,9 @@
</span><span class="cx">                                 1A6B31351A51F3A900422975 /* StorageNamespaceImpl.cpp in Sources */,
</span><span class="cx">                                 F834AAD80E64B1C700E2737C /* WebTextIterator.mm in Sources */,
</span><span class="cx">                                 A10C1D1D18202F9C0036883A /* WebDefaultResourceLoadDelegate.m in Sources */,
</span><ins>+                                1430C12C1B2C5DF700DEA01D /* WebViewGroup.cpp in Sources */,
</ins><span class="cx">                                 939810BE0824BF01008DF038 /* WebURLsWithTitles.m in Sources */,
</span><span class="cx">                                 C0C5B3EF1177A4A0002B0AEF /* WebUserContentURLPattern.mm in Sources */,
</span><del>-                                1AB1DAC118BC0232004B6A9F /* WebViewGroup.mm in Sources */,
</del><span class="cx">                                 939811070824BF01008DF038 /* WebView.mm in Sources */,
</span><span class="cx">                                 1A6B313B1A51F3A900422975 /* StorageTracker.cpp in Sources */,
</span><span class="cx">                                 BC2E464E0FD8A96800A9D9DE /* WebViewData.mm in Sources */,
</span></span></pre></div>
<a id="trunkSourceWebKitmacChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/mac/ChangeLog (185635 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/mac/ChangeLog        2015-06-17 02:54:34 UTC (rev 185635)
+++ trunk/Source/WebKit/mac/ChangeLog        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -1,3 +1,15 @@
</span><ins>+2015-06-16 Hyungwook Lee <hyungwook.lee@navercorp.com>
+
+ [Win] Implement WebViewGroup to support WebView::addxxxToGroup().
+ https://bugs.webkit.org/show_bug.cgi?id=145908
+
+ Reviewed by Brent Fulgham.
+
+ Make WebViewGroup class sharing on Mac and Win port.
+
+ * WebCoreSupport/WebViewGroup.h: Removed.
+ * WebCoreSupport/WebViewGroup.mm: Removed.
+
</ins><span class="cx"> 2015-06-13 Chris Dumez <cdumez@apple.com>
</span><span class="cx">
</span><span class="cx"> [WK2] API::Navigation objects are leaked on history navigation to HistoryItems in PageCache
</span></span></pre></div>
<a id="trunkSourceWebKitmacWebCoreSupportWebViewGrouph"></a>
<div class="delfile"><h4>Deleted: trunk/Source/WebKit/mac/WebCoreSupport/WebViewGroup.h (185635 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/mac/WebCoreSupport/WebViewGroup.h        2015-06-17 02:54:34 UTC (rev 185635)
+++ trunk/Source/WebKit/mac/WebCoreSupport/WebViewGroup.h        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -1,64 +0,0 @@
</span><del>-/*
- * Copyright (C) 2014 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 <wtf/HashSet.h>
-#include <wtf/RefCounted.h>
-#include <wtf/text/WTFString.h>
-
-namespace WebCore {
-class StorageNamespaceProvider;
-class UserContentController;
-}
-
-class WebVisitedLinkStore;
-
-@class WebView;
-
-class WebViewGroup : public RefCounted<WebViewGroup> {
-public:
- static RefPtr<WebViewGroup> getOrCreate(const String& name, const String& localStorageDatabasePath);
- ~WebViewGroup();
-
- static WebViewGroup* get(const String& name);
-
- void addWebView(WebView *);
- void removeWebView(WebView *);
-
- WebCore::StorageNamespaceProvider& storageNamespaceProvider();
- WebCore::UserContentController& userContentController() { return m_userContentController.get(); }
- WebVisitedLinkStore& visitedLinkStore() { return m_visitedLinkStore.get(); }
-
-private:
- WebViewGroup(const String& name, const String& localStorageDatabasePath);
-
- String m_name;
- HashSet<WebView *> m_webViews;
-
- String m_localStorageDatabasePath;
- RefPtr<WebCore::StorageNamespaceProvider> m_storageNamespaceProvider;
-
- Ref<WebCore::UserContentController> m_userContentController;
- Ref<WebVisitedLinkStore> m_visitedLinkStore;
-};
</del></span></pre></div>
<a id="trunkSourceWebKitmacWebCoreSupportWebViewGroupmm"></a>
<div class="delfile"><h4>Deleted: trunk/Source/WebKit/mac/WebCoreSupport/WebViewGroup.mm (185635 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/mac/WebCoreSupport/WebViewGroup.mm        2015-06-17 02:54:34 UTC (rev 185635)
+++ trunk/Source/WebKit/mac/WebCoreSupport/WebViewGroup.mm        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -1,100 +0,0 @@
</span><del>-/*
- * Copyright (C) 2014 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.
- */
-
-#import "WebViewGroup.h"
-
-#import "WebStorageNamespaceProvider.h"
-#import "WebView.h"
-#import "WebVisitedLinkStore.h"
-#import <WebCore/UserContentController.h>
-#import <wtf/NeverDestroyed.h>
-#import <wtf/text/StringHash.h>
-
-using namespace WebCore;
-
-// Any named groups will live for the lifetime of the process, thanks to the reference held by the RefPtr.
-static HashMap<String, RefPtr<WebViewGroup>>& webViewGroups()
-{
- static NeverDestroyed<HashMap<String, RefPtr<WebViewGroup>>> webViewGroups;
-
- return webViewGroups;
-}
-
-RefPtr<WebViewGroup> WebViewGroup::getOrCreate(const String& name, const String& localStorageDatabasePath)
-{
- if (name.isEmpty())
- return adoptRef(new WebViewGroup(String(), localStorageDatabasePath));
-
- auto& webViewGroup = webViewGroups().add(name, nullptr).iterator->value;
- if (!webViewGroup)
- webViewGroup = adoptRef(new WebViewGroup(name, localStorageDatabasePath));
- else if (!webViewGroup->m_storageNamespaceProvider && webViewGroup->m_localStorageDatabasePath.isEmpty() && !localStorageDatabasePath.isEmpty())
- webViewGroup->m_localStorageDatabasePath = localStorageDatabasePath;
-
- return webViewGroup;
-}
-
-WebViewGroup* WebViewGroup::get(const String& name)
-{
- ASSERT(!name.isEmpty());
-
- return webViewGroups().get(name);
-}
-
-WebViewGroup::WebViewGroup(const String& name, const String& localStorageDatabasePath)
- : m_name(name)
- , m_localStorageDatabasePath(localStorageDatabasePath)
- , m_userContentController(UserContentController::create())
- , m_visitedLinkStore(WebVisitedLinkStore::create())
-{
-}
-
-WebViewGroup::~WebViewGroup()
-{
- ASSERT(m_name.isEmpty());
- ASSERT(m_webViews.isEmpty());
-}
-
-void WebViewGroup::addWebView(WebView *webView)
-{
- ASSERT(!m_webViews.contains(webView));
-
- m_webViews.add(webView);
-}
-
-void WebViewGroup::removeWebView(WebView *webView)
-{
- ASSERT(m_webViews.contains(webView));
-
- m_webViews.remove(webView);
-}
-
-StorageNamespaceProvider& WebViewGroup::storageNamespaceProvider()
-{
- if (!m_storageNamespaceProvider)
- m_storageNamespaceProvider = WebStorageNamespaceProvider::create(m_localStorageDatabasePath);
-
- return *m_storageNamespaceProvider;
-}
</del></span></pre></div>
<a id="trunkSourceWebKitwinChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/win/ChangeLog (185635 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/win/ChangeLog        2015-06-17 02:54:34 UTC (rev 185635)
+++ trunk/Source/WebKit/win/ChangeLog        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -1,3 +1,28 @@
</span><ins>+2015-06-16 Hyungwook Lee <hyungwook.lee@navercorp.com>
+
+ [Win] Implement WebViewGroup to support WebView::addxxxToGroup().
+ https://bugs.webkit.org/show_bug.cgi?id=145908
+
+ Reviewed by Brent Fulgham.
+
+ Make WebViewGroup class sharing on Mac and Win port.
+
+ * WebCoreSupport/WebVisitedLinkStore.cpp:
+ (visitedLinkStores):
+ (WebVisitedLinkStore::create):
+ (WebVisitedLinkStore::WebVisitedLinkStore):
+ (WebVisitedLinkStore::~WebVisitedLinkStore):
+ (WebVisitedLinkStore::setShouldTrackVisitedLinks):
+ (WebVisitedLinkStore::removeAllVisitedLinks):
+ (WebVisitedLinkStore::singleton): Deleted.
+ * WebCoreSupport/WebVisitedLinkStore.h:
+ * WebView.cpp:
+ (WebView::~WebView):
+ (WebView::initWithFrame):
+ (WebView::setGroupName):
+ (WebView::addVisitedLinks):
+ * WebView.h:
+
</ins><span class="cx"> 2015-06-13 Chris Dumez <cdumez@apple.com>
</span><span class="cx">
</span><span class="cx"> [WK2] API::Navigation objects are leaked on history navigation to HistoryItems in PageCache
</span></span></pre></div>
<a id="trunkSourceWebKitwinWebCoreSupportWebVisitedLinkStorecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/win/WebCoreSupport/WebVisitedLinkStore.cpp (185635 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/win/WebCoreSupport/WebVisitedLinkStore.cpp        2015-06-17 02:54:34 UTC (rev 185635)
+++ trunk/Source/WebKit/win/WebCoreSupport/WebVisitedLinkStore.cpp        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -34,20 +34,27 @@
</span><span class="cx">
</span><span class="cx"> static bool s_shouldTrackVisitedLinks;
</span><span class="cx">
</span><del>-WebVisitedLinkStore& WebVisitedLinkStore::singleton()
</del><ins>+static HashSet<WebVisitedLinkStore*>& visitedLinkStores()
</ins><span class="cx"> {
</span><del>- static WebVisitedLinkStore& visitedLinkStore = *adoptRef(new WebVisitedLinkStore).leakRef();
-
- return visitedLinkStore;
</del><ins>+ static NeverDestroyed<HashSet<WebVisitedLinkStore*>> visitedLinkStores;
+
+ return visitedLinkStores;
</ins><span class="cx"> }
</span><span class="cx">
</span><ins>+Ref<WebVisitedLinkStore> WebVisitedLinkStore::create()
+{
+ return adoptRef(*new WebVisitedLinkStore);
+}
+
</ins><span class="cx"> WebVisitedLinkStore::WebVisitedLinkStore()
</span><span class="cx"> : m_visitedLinksPopulated(false)
</span><span class="cx"> {
</span><ins>+ visitedLinkStores().add(this);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> WebVisitedLinkStore::~WebVisitedLinkStore()
</span><span class="cx"> {
</span><ins>+ visitedLinkStores().remove(this);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> void WebVisitedLinkStore::setShouldTrackVisitedLinks(bool shouldTrackVisitedLinks)
</span><span class="lines">@@ -62,7 +69,8 @@
</span><span class="cx">
</span><span class="cx"> void WebVisitedLinkStore::removeAllVisitedLinks()
</span><span class="cx"> {
</span><del>- WebVisitedLinkStore::singleton().removeVisitedLinkHashes();
</del><ins>+ for (auto& visitedLinkStore : visitedLinkStores())
+ visitedLinkStore->removeVisitedLinkHashes();
</ins><span class="cx"> PageCache::singleton().markPagesForVisitedLinkStyleRecalc();
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebKitwinWebCoreSupportWebVisitedLinkStoreh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/win/WebCoreSupport/WebVisitedLinkStore.h (185635 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/win/WebCoreSupport/WebVisitedLinkStore.h        2015-06-17 02:54:34 UTC (rev 185635)
+++ trunk/Source/WebKit/win/WebCoreSupport/WebVisitedLinkStore.h        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -32,8 +32,7 @@
</span><span class="cx">
</span><span class="cx"> class WebVisitedLinkStore final : public WebCore::VisitedLinkStore {
</span><span class="cx"> public:
</span><del>- static WebVisitedLinkStore& singleton();
- WebVisitedLinkStore();
</del><ins>+ static Ref<WebVisitedLinkStore> create();
</ins><span class="cx"> virtual ~WebVisitedLinkStore();
</span><span class="cx">
</span><span class="cx"> static void setShouldTrackVisitedLinks(bool);
</span><span class="lines">@@ -42,6 +41,8 @@
</span><span class="cx"> void addVisitedLink(const String& urlString);
</span><span class="cx">
</span><span class="cx"> private:
</span><ins>+ WebVisitedLinkStore();
+
</ins><span class="cx"> virtual bool isLinkVisited(WebCore::Page&, WebCore::LinkHash, const WebCore::URL& baseURL, const AtomicString& attributeURL) override;
</span><span class="cx"> virtual void addVisitedLink(WebCore::Page&, WebCore::LinkHash) override;
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebKitwinWebViewcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/win/WebView.cpp (185635 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/win/WebView.cpp        2015-06-17 02:54:34 UTC (rev 185635)
+++ trunk/Source/WebKit/win/WebView.cpp        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -69,6 +69,7 @@
</span><span class="cx"> #include "WebPreferences.h"
</span><span class="cx"> #include "WebScriptWorld.h"
</span><span class="cx"> #include "WebStorageNamespaceProvider.h"
</span><ins>+#include "WebViewGroup.h"
</ins><span class="cx"> #include "WebVisitedLinkStore.h"
</span><span class="cx"> #include "resource.h"
</span><span class="cx"> #include <JavaScriptCore/APICast.h>
</span><span class="lines">@@ -152,6 +153,7 @@
</span><span class="cx"> #include <WebCore/SecurityPolicy.h>
</span><span class="cx"> #include <WebCore/Settings.h>
</span><span class="cx"> #include <WebCore/SystemInfo.h>
</span><ins>+#include <WebCore/UserContentController.h>
</ins><span class="cx"> #include <WebCore/WindowMessageBroadcaster.h>
</span><span class="cx"> #include <WebCore/WindowsTouch.h>
</span><span class="cx"> #include <bindings/ScriptValue.h>
</span><span class="lines">@@ -457,6 +459,8 @@
</span><span class="cx"> ASSERT(!m_layerTreeHost);
</span><span class="cx"> #endif
</span><span class="cx">
</span><ins>+ m_webViewGroup->removeWebView(this);
+
</ins><span class="cx"> WebViewCount--;
</span><span class="cx"> gClassCount--;
</span><span class="cx"> gClassNameCount().remove("WebView");
</span><span class="lines">@@ -2818,6 +2822,9 @@
</span><span class="cx">
</span><span class="cx"> m_inspectorClient = new WebInspectorClient(this);
</span><span class="cx">
</span><ins>+ m_webViewGroup = WebViewGroup::getOrCreate(groupName, localStorageDatabasePath(m_preferences.get()));
+ m_webViewGroup->addWebView(this);
+
</ins><span class="cx"> PageConfiguration configuration;
</span><span class="cx"> configuration.chromeClient = new WebChromeClient(this);
</span><span class="cx"> configuration.contextMenuClient = new WebContextMenuClient(this);
</span><span class="lines">@@ -2826,9 +2833,10 @@
</span><span class="cx"> configuration.inspectorClient = m_inspectorClient;
</span><span class="cx"> configuration.loaderClientForMainFrame = new WebFrameLoaderClient;
</span><span class="cx"> configuration.databaseProvider = &WebDatabaseProvider::singleton();
</span><del>- configuration.storageNamespaceProvider = WebStorageNamespaceProvider::create(localStorageDatabasePath(m_preferences.get()));
</del><ins>+ configuration.storageNamespaceProvider = &m_webViewGroup->storageNamespaceProvider();
</ins><span class="cx"> configuration.progressTrackerClient = static_cast<WebFrameLoaderClient*>(configuration.loaderClientForMainFrame);
</span><del>- configuration.visitedLinkStore = &WebVisitedLinkStore::singleton();
</del><ins>+ configuration.userContentController = &m_webViewGroup->userContentController();
+ configuration.visitedLinkStore = &m_webViewGroup->visitedLinkStore();
</ins><span class="cx">
</span><span class="cx"> m_page = new Page(configuration);
</span><span class="cx"> provideGeolocationTo(m_page, new WebGeolocationClient(this));
</span><span class="lines">@@ -3695,8 +3703,17 @@
</span><span class="cx"> HRESULT STDMETHODCALLTYPE WebView::setGroupName(
</span><span class="cx"> /* [in] */ BSTR groupName)
</span><span class="cx"> {
</span><ins>+ if (m_webViewGroup)
+ m_webViewGroup->removeWebView(this);
+
+ m_webViewGroup = WebViewGroup::getOrCreate(groupName, localStorageDatabasePath(m_preferences.get()));
+ m_webViewGroup->addWebView(this);
+
</ins><span class="cx"> if (!m_page)
</span><span class="cx"> return S_OK;
</span><ins>+
+ m_page->setUserContentController(&m_webViewGroup->userContentController());
+ m_page->setVisitedLinkStore(m_webViewGroup->visitedLinkStore());
</ins><span class="cx"> m_page->setGroupName(toString(groupName));
</span><span class="cx"> return S_OK;
</span><span class="cx"> }
</span><span class="lines">@@ -6503,7 +6520,7 @@
</span><span class="cx">
</span><span class="cx"> HRESULT WebView::addVisitedLinks(BSTR* visitedURLs, unsigned visitedURLCount)
</span><span class="cx"> {
</span><del>- auto& visitedLinkStore = WebVisitedLinkStore::singleton();
</del><ins>+ auto& visitedLinkStore = m_webViewGroup->visitedLinkStore();
</ins><span class="cx"> PageGroup& group = core(this)->group();
</span><span class="cx">
</span><span class="cx"> for (unsigned i = 0; i < visitedURLCount; ++i) {
</span></span></pre></div>
<a id="trunkSourceWebKitwinWebViewh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit/win/WebView.h (185635 => 185636)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit/win/WebView.h        2015-06-17 02:54:34 UTC (rev 185635)
+++ trunk/Source/WebKit/win/WebView.h        2015-06-17 03:30:51 UTC (rev 185636)
</span><span class="lines">@@ -70,6 +70,7 @@
</span><span class="cx"> #if USE(TEXTURE_MAPPER_GL)
</span><span class="cx"> class AcceleratedCompositingContext;
</span><span class="cx"> #endif
</span><ins>+class WebViewGroup;
</ins><span class="cx">
</span><span class="cx"> WebView* kit(WebCore::Page*);
</span><span class="cx"> WebCore::Page* core(IWebView*);
</span><span class="lines">@@ -1159,6 +1160,8 @@
</span><span class="cx"> std::unique_ptr<WebCore::FullScreenController> m_fullscreenController;
</span><span class="cx"> WebCore::IntPoint m_scrollPosition;
</span><span class="cx"> #endif
</span><ins>+
+ RefPtr<WebViewGroup> m_webViewGroup;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> #endif
</span></span></pre>
</div>
</div>
</body>
</html>