[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-10851-g50815da
weinig at apple.com
weinig at apple.com
Wed Dec 22 18:34:16 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit 9359007a4e1c6a60605e56e11464d734123e7733
Author: weinig at apple.com <weinig at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Tue Dec 14 00:55:54 2010 +0000
Remove associated page concept from WKView constructor
https://bugs.webkit.org/show_bug.cgi?id=50983
Reviewed by Anders Carlsson.
Step 2: Remove WebPageNamespace. It no longer does anything.
* Shared/APIObject.h:
* UIProcess/API/C/WKPage.h:
* UIProcess/API/mac/WKView.mm:
(-[WKView initWithFrame:contextRef:pageGroupRef:]):
* UIProcess/API/qt/qgraphicswkview.cpp:
* UIProcess/API/qt/qwkcontext.cpp:
(QWKContext::QWKContext):
* UIProcess/API/qt/qwkcontext_p.h:
* UIProcess/API/qt/qwkpage.cpp:
(QWKPagePrivate::QWKPagePrivate):
* UIProcess/API/qt/qwkpage_p.h:
* UIProcess/WebContext.cpp:
(WebKit::WebContext::WebContext):
(WebKit::WebContext::~WebContext):
(WebKit::WebContext::createWebPage):
* UIProcess/WebContext.h:
* UIProcess/WebPageNamespace.cpp: Removed.
* UIProcess/WebPageNamespace.h: Removed.
* UIProcess/WebPageProxy.cpp:
* UIProcess/WebPageProxy.h:
(WebKit::WebPageProxy::context):
* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::createWebPage):
* UIProcess/WebProcessProxy.h:
* UIProcess/win/WebView.cpp:
(WebKit::WebView::WebView):
* UIProcess/win/WebView.h:
* WebKit2.pro:
* WebKit2.xcodeproj/project.pbxproj:
* win/WebKit2.vcproj:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@73986 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebKit2/ChangeLog b/WebKit2/ChangeLog
index 19e4748..ad1af51 100644
--- a/WebKit2/ChangeLog
+++ b/WebKit2/ChangeLog
@@ -1,5 +1,45 @@
2010-12-13 Sam Weinig <sam at webkit.org>
+ Reviewed by Anders Carlsson.
+
+ Remove associated page concept from WKView constructor
+ https://bugs.webkit.org/show_bug.cgi?id=50983
+
+ Step 2: Remove WebPageNamespace. It no longer does anything.
+
+ * Shared/APIObject.h:
+ * UIProcess/API/C/WKPage.h:
+ * UIProcess/API/mac/WKView.mm:
+ (-[WKView initWithFrame:contextRef:pageGroupRef:]):
+ * UIProcess/API/qt/qgraphicswkview.cpp:
+ * UIProcess/API/qt/qwkcontext.cpp:
+ (QWKContext::QWKContext):
+ * UIProcess/API/qt/qwkcontext_p.h:
+ * UIProcess/API/qt/qwkpage.cpp:
+ (QWKPagePrivate::QWKPagePrivate):
+ * UIProcess/API/qt/qwkpage_p.h:
+ * UIProcess/WebContext.cpp:
+ (WebKit::WebContext::WebContext):
+ (WebKit::WebContext::~WebContext):
+ (WebKit::WebContext::createWebPage):
+ * UIProcess/WebContext.h:
+ * UIProcess/WebPageNamespace.cpp: Removed.
+ * UIProcess/WebPageNamespace.h: Removed.
+ * UIProcess/WebPageProxy.cpp:
+ * UIProcess/WebPageProxy.h:
+ (WebKit::WebPageProxy::context):
+ * UIProcess/WebProcessProxy.cpp:
+ (WebKit::WebProcessProxy::createWebPage):
+ * UIProcess/WebProcessProxy.h:
+ * UIProcess/win/WebView.cpp:
+ (WebKit::WebView::WebView):
+ * UIProcess/win/WebView.h:
+ * WebKit2.pro:
+ * WebKit2.xcodeproj/project.pbxproj:
+ * win/WebKit2.vcproj:
+
+2010-12-13 Sam Weinig <sam at webkit.org>
+
Fix windows build.
* UIProcess/win/WebView.h:
diff --git a/WebKit2/Shared/APIObject.h b/WebKit2/Shared/APIObject.h
index 11cc0d9..52b7a57 100644
--- a/WebKit2/Shared/APIObject.h
+++ b/WebKit2/Shared/APIObject.h
@@ -71,7 +71,6 @@ public:
TypeNavigationData,
TypePage,
TypePageGroup,
- TypePageNamespace,
TypePreferences,
// Bundle types
diff --git a/WebKit2/UIProcess/API/C/WKPage.h b/WebKit2/UIProcess/API/C/WKPage.h
index 07ae075..13844f1 100644
--- a/WebKit2/UIProcess/API/C/WKPage.h
+++ b/WebKit2/UIProcess/API/C/WKPage.h
@@ -64,7 +64,7 @@ typedef void (*WKPageDidStartProgressCallback)(WKPageRef page, const void *clien
typedef void (*WKPageDidChangeProgressCallback)(WKPageRef page, const void *clientInfo);
typedef void (*WKPageDidFinishProgressCallback)(WKPageRef page, const void *clientInfo);
-// WebPageNamespace Client
+// WebProcess Client
// FIXME: These three functions should not be part of this client.
typedef void (*WKPageProcessDidBecomeUnresponsiveCallback)(WKPageRef page, const void *clientInfo);
typedef void (*WKPageProcessDidBecomeResponsiveCallback)(WKPageRef page, const void *clientInfo);
diff --git a/WebKit2/UIProcess/API/mac/WKView.mm b/WebKit2/UIProcess/API/mac/WKView.mm
index ef16f40..42439ed 100644
--- a/WebKit2/UIProcess/API/mac/WKView.mm
+++ b/WebKit2/UIProcess/API/mac/WKView.mm
@@ -41,7 +41,6 @@
#import "WebContext.h"
#import "WebEventFactory.h"
#import "WebPage.h"
-#import "WebPageNamespace.h"
#import "WebPageProxy.h"
#import "WebProcessManager.h"
#import "WebProcessProxy.h"
@@ -158,7 +157,7 @@ struct EditCommandState {
_data = [[WKViewData alloc] init];
_data->_pageClient = PageClientImpl::create(self);
- _data->_page = toImpl(contextRef)->sharedPageNamespace()->createWebPage(toImpl(pageGroupRef));
+ _data->_page = toImpl(contextRef)->createWebPage(toImpl(pageGroupRef));
_data->_page->setPageClient(_data->_pageClient.get());
_data->_page->setDrawingArea(ChunkedUpdateDrawingAreaProxy::create(self));
_data->_page->initializeWebPage(IntSize(frame.size));
diff --git a/WebKit2/UIProcess/API/qt/qgraphicswkview.cpp b/WebKit2/UIProcess/API/qt/qgraphicswkview.cpp
index 8e818fa..ff73440 100644
--- a/WebKit2/UIProcess/API/qt/qgraphicswkview.cpp
+++ b/WebKit2/UIProcess/API/qt/qgraphicswkview.cpp
@@ -26,7 +26,6 @@
#include "TiledDrawingAreaProxy.h"
#include "UpdateChunk.h"
#include "WKAPICast.h"
-#include "WebPageNamespace.h"
#include "qwkpage.h"
#include "qwkpage_p.h"
#include <QCursor>
diff --git a/WebKit2/UIProcess/API/qt/qwkcontext.cpp b/WebKit2/UIProcess/API/qt/qwkcontext.cpp
index 889464f..b17c100 100644
--- a/WebKit2/UIProcess/API/qt/qwkcontext.cpp
+++ b/WebKit2/UIProcess/API/qt/qwkcontext.cpp
@@ -50,7 +50,6 @@ QWKContext::QWKContext(QObject* parent)
, d(new QWKContextPrivate(this))
{
d->context = WebContext::create(String());
- d->pageNamespace = d->context->sharedPageNamespace();
}
QWKContext::QWKContext(WKContextRef contextRef, QObject* parent)
@@ -58,7 +57,6 @@ QWKContext::QWKContext(WKContextRef contextRef, QObject* parent)
, d(new QWKContextPrivate(this))
{
d->context = toImpl(contextRef);
- d->pageNamespace = d->context->sharedPageNamespace();
}
QWKContext::~QWKContext()
diff --git a/WebKit2/UIProcess/API/qt/qwkcontext_p.h b/WebKit2/UIProcess/API/qt/qwkcontext_p.h
index 23be438..625e87c 100644
--- a/WebKit2/UIProcess/API/qt/qwkcontext_p.h
+++ b/WebKit2/UIProcess/API/qt/qwkcontext_p.h
@@ -22,7 +22,6 @@
#define qwkcontext_p_h
#include "WebContext.h"
-#include "WebPageNamespace.h"
#include <wtf/RefPtr.h>
class QWKContextPrivate {
@@ -33,7 +32,6 @@ public:
QWKContext* q;
RefPtr<WebKit::WebContext> context;
- RefPtr<WebKit::WebPageNamespace> pageNamespace;
};
#endif /* qkcontext_p_h */
diff --git a/WebKit2/UIProcess/API/qt/qwkpage.cpp b/WebKit2/UIProcess/API/qt/qwkpage.cpp
index d6a7c83..f445d2f 100644
--- a/WebKit2/UIProcess/API/qt/qwkpage.cpp
+++ b/WebKit2/UIProcess/API/qt/qwkpage.cpp
@@ -60,7 +60,7 @@ QWKPagePrivate::QWKPagePrivate(QWKPage* qq, QWKContext* c)
, createNewPageFn(0)
{
memset(actions, 0, sizeof(actions));
- page = context->d->pageNamespace->createWebPage(0);
+ page = context->d->context->createWebPage(0);
page->setPageClient(this);
history = QWKHistoryPrivate::createHistory(page->backForwardList());
}
diff --git a/WebKit2/UIProcess/API/qt/qwkpage_p.h b/WebKit2/UIProcess/API/qt/qwkpage_p.h
index ea854c8..a06019c 100644
--- a/WebKit2/UIProcess/API/qt/qwkpage_p.h
+++ b/WebKit2/UIProcess/API/qt/qwkpage_p.h
@@ -24,7 +24,6 @@
#include "DrawingAreaProxy.h"
#include "PageClient.h"
#include "qwkpage.h"
-#include "WebPageNamespace.h"
#include "WebPageProxy.h"
#include <wtf/PassOwnPtr.h>
#include <wtf/RefPtr.h>
diff --git a/WebKit2/UIProcess/WebContext.cpp b/WebKit2/UIProcess/WebContext.cpp
index 6a15c11..4db02df 100644
--- a/WebKit2/UIProcess/WebContext.cpp
+++ b/WebKit2/UIProcess/WebContext.cpp
@@ -35,7 +35,6 @@
#include "WebCoreArgumentCoders.h"
#include "WebDatabaseManagerProxy.h"
#include "WebPageGroup.h"
-#include "WebPageNamespace.h"
#include "WebProcessCreationParameters.h"
#include "WebProcessManager.h"
#include "WebProcessMessages.h"
@@ -79,7 +78,6 @@ PassRefPtr<WebContext> WebContext::create(const String& injectedBundlePath)
WebContext::WebContext(ProcessModel processModel, const String& injectedBundlePath)
: m_processModel(processModel)
- , m_sharedNamespace(0)
, m_defaultPageGroup(WebPageGroup::create())
, m_injectedBundlePath(injectedBundlePath)
, m_visitedLinkProvider(this)
@@ -100,11 +98,10 @@ WebContext::WebContext(ProcessModel processModel, const String& injectedBundlePa
WebContext::~WebContext()
{
- ASSERT(m_pageNamespaces.isEmpty());
removeLanguageChangeObserver(this);
WebProcessManager::shared().contextWasDestroyed(this);
-
+
#ifndef NDEBUG
webContextCounter.decrement();
#endif
@@ -214,14 +211,14 @@ void WebContext::processDidClose(WebProcessProxy* process)
m_process = 0;
}
-WebPageProxy* WebContext::createWebPage(WebPageNamespace* pageNamespace, WebPageGroup* pageGroup)
+WebPageProxy* WebContext::createWebPage(WebPageGroup* pageGroup)
{
ensureWebProcess();
if (!pageGroup)
pageGroup = m_defaultPageGroup.get();
- return m_process->createWebPage(pageNamespace, pageGroup);
+ return m_process->createWebPage(this, pageGroup);
}
void WebContext::relaunchProcessIfNecessary()
@@ -229,29 +226,6 @@ void WebContext::relaunchProcessIfNecessary()
ensureWebProcess();
}
-WebPageNamespace* WebContext::sharedPageNamespace()
-{
- if (!m_sharedNamespace)
- m_sharedNamespace = createPageNamespace();
- return m_sharedNamespace.get();
-}
-
-PassRefPtr<WebPageNamespace> WebContext::createPageNamespace()
-{
- RefPtr<WebPageNamespace> pageNamespace = WebPageNamespace::create(this);
- m_pageNamespaces.add(pageNamespace.get());
- return pageNamespace.release();
-}
-
-void WebContext::pageNamespaceWasDestroyed(WebPageNamespace* pageNamespace)
-{
- if (pageNamespace == m_sharedNamespace)
- m_sharedNamespace = 0;
-
- ASSERT(m_pageNamespaces.contains(pageNamespace));
- m_pageNamespaces.remove(pageNamespace);
-}
-
void WebContext::postMessageToInjectedBundle(const String& messageName, APIObject* messageBody)
{
if (!m_process || !m_process->canSendMessage()) {
diff --git a/WebKit2/UIProcess/WebContext.h b/WebKit2/UIProcess/WebContext.h
index 02f1c48..70b42f2 100644
--- a/WebKit2/UIProcess/WebContext.h
+++ b/WebKit2/UIProcess/WebContext.h
@@ -47,7 +47,6 @@ namespace WebKit {
class DownloadProxy;
class WebDatabaseManagerProxy;
class WebPageGroup;
-class WebPageNamespace;
class WebPageProxy;
struct WebProcessCreationParameters;
@@ -71,14 +70,10 @@ public:
void processDidFinishLaunching(WebProcessProxy*);
void processDidClose(WebProcessProxy*);
- WebPageProxy* createWebPage(WebPageNamespace*, WebPageGroup* = 0);
+ WebPageProxy* createWebPage(WebPageGroup* = 0);
void relaunchProcessIfNecessary();
- WebPageNamespace* sharedPageNamespace();
- PassRefPtr<WebPageNamespace> createPageNamespace();
- void pageNamespaceWasDestroyed(WebPageNamespace*);
-
const String& injectedBundlePath() const { return m_injectedBundlePath; }
void setInjectedBundleInitializationUserData(PassRefPtr<APIObject> userData) { m_injectedBundleInitializationUserData = userData; }
@@ -163,9 +158,6 @@ private:
// FIXME: In the future, this should be one or more WebProcessProxies.
RefPtr<WebProcessProxy> m_process;
- RefPtr<WebPageNamespace> m_sharedNamespace;
- HashSet<WebPageNamespace*> m_pageNamespaces;
-
RefPtr<WebPageGroup> m_defaultPageGroup;
RefPtr<APIObject> m_injectedBundleInitializationUserData;
diff --git a/WebKit2/UIProcess/WebPageNamespace.cpp b/WebKit2/UIProcess/WebPageNamespace.cpp
deleted file mode 100644
index 9b2d7b3..0000000
--- a/WebKit2/UIProcess/WebPageNamespace.cpp
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright (C) 2010 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 "WebPageNamespace.h"
-
-#include "WKContextPrivate.h"
-#include "WebProcessManager.h"
-#include "WebProcessProxy.h"
-
-#ifndef NDEBUG
-#include <wtf/RefCountedLeakCounter.h>
-#endif
-
-namespace WebKit {
-
-#ifndef NDEBUG
-static WTF::RefCountedLeakCounter webPageNamespaceCounter("WebPageNamespace");
-#endif
-
-WebPageNamespace::WebPageNamespace(WebContext* context)
- : m_context(context)
-{
-#ifndef NDEBUG
- webPageNamespaceCounter.increment();
-#endif
-}
-
-WebPageNamespace::~WebPageNamespace()
-{
- ASSERT(m_context);
- m_context->pageNamespaceWasDestroyed(this);
-
-#ifndef NDEBUG
- webPageNamespaceCounter.decrement();
-#endif
-}
-
-WebPageProxy* WebPageNamespace::createWebPage(WebPageGroup* group)
-{
- return m_context->createWebPage(this, group);
-}
-
-} // namespace WebKit
diff --git a/WebKit2/UIProcess/WebPageNamespace.h b/WebKit2/UIProcess/WebPageNamespace.h
deleted file mode 100644
index f8955bb..0000000
--- a/WebKit2/UIProcess/WebPageNamespace.h
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright (C) 2010 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.
- */
-
-#ifndef WebPageNamespace_h
-#define WebPageNamespace_h
-
-#include "APIObject.h"
-#include "WebContext.h"
-#include <wtf/PassRefPtr.h>
-#include <wtf/RefPtr.h>
-
-namespace WebKit {
-
-class WebContext;
-class WebPageGroup;
-
-class WebPageNamespace : public APIObject {
-public:
- static const Type APIType = TypePageNamespace;
-
- static PassRefPtr<WebPageNamespace> create(WebContext* context)
- {
- return adoptRef(new WebPageNamespace(context));
- }
-
- virtual ~WebPageNamespace();
-
- WebPageProxy* createWebPage(WebPageGroup*);
-
- WebContext* context() const { return m_context.get(); }
- WebProcessProxy* process() const { return m_context->process(); }
-
-private:
- WebPageNamespace(WebContext*);
-
- virtual Type type() const { return APIType; }
-
- RefPtr<WebContext> m_context;
-};
-
-} // namespace WebKit
-
-#endif // WebPageNamespace_h
diff --git a/WebKit2/UIProcess/WebPageProxy.cpp b/WebKit2/UIProcess/WebPageProxy.cpp
index 8a89d1a..54c5c6c 100644
--- a/WebKit2/UIProcess/WebPageProxy.cpp
+++ b/WebKit2/UIProcess/WebPageProxy.cpp
@@ -51,7 +51,6 @@
#include "WebPageGroup.h"
#include "WebPageGroupData.h"
#include "WebPageMessages.h"
-#include "WebPageNamespace.h"
#include "WebPopupItem.h"
#include "WebPopupMenuProxy.h"
#include "WebPreferences.h"
@@ -81,14 +80,14 @@ namespace WebKit {
static WTF::RefCountedLeakCounter webPageProxyCounter("WebPageProxy");
#endif
-PassRefPtr<WebPageProxy> WebPageProxy::create(WebPageNamespace* pageNamespace, WebPageGroup* pageGroup, uint64_t pageID)
+PassRefPtr<WebPageProxy> WebPageProxy::create(WebContext* context, WebPageGroup* pageGroup, uint64_t pageID)
{
- return adoptRef(new WebPageProxy(pageNamespace, pageGroup, pageID));
+ return adoptRef(new WebPageProxy(context, pageGroup, pageID));
}
-WebPageProxy::WebPageProxy(WebPageNamespace* pageNamespace, WebPageGroup* pageGroup, uint64_t pageID)
+WebPageProxy::WebPageProxy(WebContext* context, WebPageGroup* pageGroup, uint64_t pageID)
: m_pageClient(0)
- , m_pageNamespace(pageNamespace)
+ , m_context(context)
, m_pageGroup(pageGroup)
, m_mainFrame(0)
, m_estimatedProgress(0.0)
@@ -130,12 +129,7 @@ WebPageProxy::~WebPageProxy()
WebProcessProxy* WebPageProxy::process() const
{
- return m_pageNamespace->process();
-}
-
-WebContext* WebPageProxy::context() const
-{
- return m_pageNamespace->context();
+ return m_context->process();
}
bool WebPageProxy::isValid()
@@ -193,8 +187,8 @@ void WebPageProxy::initializeContextMenuClient(const WKPageContextMenuClient* cl
void WebPageProxy::relaunch()
{
m_isValid = true;
- m_pageNamespace->context()->relaunchProcessIfNecessary();
- m_pageNamespace->process()->addExistingWebPage(this, m_pageID);
+ context()->relaunchProcessIfNecessary();
+ process()->addExistingWebPage(this, m_pageID);
m_pageClient->didRelaunchProcess();
}
@@ -398,7 +392,7 @@ bool WebPageProxy::canShowMIMEType(const String& mimeType) const
return true;
String newMimeType = mimeType;
- PluginInfoStore::Plugin plugin = pageNamespace()->context()->pluginInfoStore()->findPlugin(newMimeType, KURL());
+ PluginInfoStore::Plugin plugin = context()->pluginInfoStore()->findPlugin(newMimeType, KURL());
if (!plugin.path.isNull())
return true;
@@ -594,7 +588,7 @@ void WebPageProxy::receivedPolicyDecision(PolicyAction action, WebFrameProxy* fr
uint64_t downloadID = 0;
if (action == PolicyDownload) {
// Create a download proxy.
- downloadID = pageNamespace()->context()->createDownloadProxy();
+ downloadID = context()->createDownloadProxy();
}
// If we received a policy decision while in decidePolicyForMIMEType the decision will
@@ -838,7 +832,7 @@ void WebPageProxy::didFinishProgress()
void WebPageProxy::didStartProvisionalLoadForFrame(uint64_t frameID, const String& url, bool loadingSubstituteDataForUnreachableURL, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -854,7 +848,7 @@ void WebPageProxy::didStartProvisionalLoadForFrame(uint64_t frameID, const Strin
void WebPageProxy::didReceiveServerRedirectForProvisionalLoadForFrame(uint64_t frameID, const String& url, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -867,7 +861,7 @@ void WebPageProxy::didReceiveServerRedirectForProvisionalLoadForFrame(uint64_t f
void WebPageProxy::didFailProvisionalLoadForFrame(uint64_t frameID, const ResourceError& error, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -880,7 +874,7 @@ void WebPageProxy::didFailProvisionalLoadForFrame(uint64_t frameID, const Resour
void WebPageProxy::didCommitLoadForFrame(uint64_t frameID, const String& mimeType, bool frameHasCustomRepresentation, const PlatformCertificateInfo& certificateInfo, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -900,7 +894,7 @@ void WebPageProxy::didCommitLoadForFrame(uint64_t frameID, const String& mimeTyp
void WebPageProxy::didFinishDocumentLoadForFrame(uint64_t frameID, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -912,7 +906,7 @@ void WebPageProxy::didFinishDocumentLoadForFrame(uint64_t frameID, CoreIPC::Argu
void WebPageProxy::didFinishLoadForFrame(uint64_t frameID, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -925,7 +919,7 @@ void WebPageProxy::didFinishLoadForFrame(uint64_t frameID, CoreIPC::ArgumentDeco
void WebPageProxy::didFailLoadForFrame(uint64_t frameID, const ResourceError& error, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -938,7 +932,7 @@ void WebPageProxy::didFailLoadForFrame(uint64_t frameID, const ResourceError& er
void WebPageProxy::didSameDocumentNavigationForFrame(uint64_t frameID, uint32_t opaqueSameDocumentNavigationType, const String& url, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -951,7 +945,7 @@ void WebPageProxy::didSameDocumentNavigationForFrame(uint64_t frameID, uint32_t
void WebPageProxy::didReceiveTitleForFrame(uint64_t frameID, const String& title, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -969,7 +963,7 @@ void WebPageProxy::didReceiveTitleForFrame(uint64_t frameID, const String& title
void WebPageProxy::didFirstLayoutForFrame(uint64_t frameID, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -981,7 +975,7 @@ void WebPageProxy::didFirstLayoutForFrame(uint64_t frameID, CoreIPC::ArgumentDec
void WebPageProxy::didFirstVisuallyNonEmptyLayoutForFrame(uint64_t frameID, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -993,7 +987,7 @@ void WebPageProxy::didFirstVisuallyNonEmptyLayoutForFrame(uint64_t frameID, Core
void WebPageProxy::didRemoveFrameFromHierarchy(uint64_t frameID, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -1005,7 +999,7 @@ void WebPageProxy::didRemoveFrameFromHierarchy(uint64_t frameID, CoreIPC::Argume
void WebPageProxy::didDisplayInsecureContentForFrame(uint64_t frameID, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -1017,7 +1011,7 @@ void WebPageProxy::didDisplayInsecureContentForFrame(uint64_t frameID, CoreIPC::
void WebPageProxy::didRunInsecureContentForFrame(uint64_t frameID, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -1087,7 +1081,7 @@ void WebPageProxy::decidePolicyForMIMEType(uint64_t frameID, const String& MIMET
void WebPageProxy::willSubmitForm(uint64_t frameID, uint64_t sourceFrameID, const StringPairVector& textFieldValues, uint64_t listenerID, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -1146,7 +1140,7 @@ void WebPageProxy::mouseDidMoveOverElement(uint32_t opaqueModifiers, CoreIPC::Ar
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
@@ -1372,7 +1366,7 @@ void WebPageProxy::hidePopupMenu()
void WebPageProxy::showContextMenu(const WebCore::IntPoint& menuLocation, const Vector<WebContextMenuItemData>& proposedItems, CoreIPC::ArgumentDecoder* arguments)
{
RefPtr<APIObject> userData;
- WebContextUserMessageDecoder messageDecoder(userData, pageNamespace()->context());
+ WebContextUserMessageDecoder messageDecoder(userData, context());
if (!arguments->decode(messageDecoder))
return;
diff --git a/WebKit2/UIProcess/WebPageProxy.h b/WebKit2/UIProcess/WebPageProxy.h
index 3b80048..1970eda 100644
--- a/WebKit2/UIProcess/WebPageProxy.h
+++ b/WebKit2/UIProcess/WebPageProxy.h
@@ -86,7 +86,6 @@ class WebEditCommandProxy;
class WebKeyboardEvent;
class WebMouseEvent;
class WebPageGroup;
-class WebPageNamespace;
class WebPopupMenuProxy;
class WebProcessProxy;
class WebURLRequest;
@@ -104,7 +103,7 @@ class WebPageProxy : public APIObject {
public:
static const Type APIType = TypePage;
- static PassRefPtr<WebPageProxy> create(WebPageNamespace*, WebPageGroup*, uint64_t pageID);
+ static PassRefPtr<WebPageProxy> create(WebContext*, WebPageGroup*, uint64_t pageID);
virtual ~WebPageProxy();
@@ -249,8 +248,7 @@ public:
void registerEditCommand(PassRefPtr<WebEditCommandProxy>, UndoOrRedo);
WebProcessProxy* process() const;
- WebPageNamespace* pageNamespace() const { return m_pageNamespace.get(); }
- WebContext* context() const;
+ WebContext* context() const { return m_context.get(); }
WebPageGroup* pageGroup() const { return m_pageGroup.get(); }
@@ -274,7 +272,7 @@ public:
#endif
private:
- WebPageProxy(WebPageNamespace*, WebPageGroup*, uint64_t pageID);
+ WebPageProxy(WebContext*, WebPageGroup*, uint64_t pageID);
virtual Type type() const { return APIType; }
@@ -408,7 +406,7 @@ private:
WebPageContextMenuClient m_contextMenuClient;
OwnPtr<DrawingAreaProxy> m_drawingArea;
- RefPtr<WebPageNamespace> m_pageNamespace;
+ RefPtr<WebContext> m_context;
RefPtr<WebPageGroup> m_pageGroup;
RefPtr<WebFrameProxy> m_mainFrame;
RefPtr<WebFrameProxy> m_focusedFrame;
diff --git a/WebKit2/UIProcess/WebProcessProxy.cpp b/WebKit2/UIProcess/WebProcessProxy.cpp
index 6ade713..c198b41 100644
--- a/WebKit2/UIProcess/WebProcessProxy.cpp
+++ b/WebKit2/UIProcess/WebProcessProxy.cpp
@@ -30,7 +30,6 @@
#include "WebBackForwardListItem.h"
#include "WebContext.h"
#include "WebNavigationDataStore.h"
-#include "WebPageNamespace.h"
#include "WebPageProxy.h"
#include "WebProcessManager.h"
#include "WebProcessMessages.h"
@@ -136,12 +135,12 @@ WebPageProxy* WebProcessProxy::webPage(uint64_t pageID) const
return m_pageMap.get(pageID).get();
}
-WebPageProxy* WebProcessProxy::createWebPage(WebPageNamespace* pageNamespace, WebPageGroup* pageGroup)
+WebPageProxy* WebProcessProxy::createWebPage(WebContext* context, WebPageGroup* pageGroup)
{
- ASSERT(pageNamespace->process() == this);
+ ASSERT(context->process() == this);
unsigned pageID = generatePageID();
- RefPtr<WebPageProxy> webPage = WebPageProxy::create(pageNamespace, pageGroup, pageID);
+ RefPtr<WebPageProxy> webPage = WebPageProxy::create(context, pageGroup, pageID);
m_pageMap.set(pageID, webPage);
return webPage.get();
}
diff --git a/WebKit2/UIProcess/WebProcessProxy.h b/WebKit2/UIProcess/WebProcessProxy.h
index 0d9ec47..f2a031d 100644
--- a/WebKit2/UIProcess/WebProcessProxy.h
+++ b/WebKit2/UIProcess/WebProcessProxy.h
@@ -49,7 +49,6 @@ namespace WebKit {
class WebBackForwardListItem;
class WebContext;
class WebPageGroup;
-class WebPageNamespace;
struct WebNavigationDataStore;
class WebProcessProxy : public RefCounted<WebProcessProxy>, CoreIPC::Connection::Client, ResponsivenessTimer::Client, ProcessLauncher::Client, ThreadLauncher::Client {
@@ -79,7 +78,7 @@ public:
PlatformProcessIdentifier processIdentifier() const { return m_processLauncher->processIdentifier(); }
WebPageProxy* webPage(uint64_t pageID) const;
- WebPageProxy* createWebPage(WebPageNamespace*, WebPageGroup*);
+ WebPageProxy* createWebPage(WebContext*, WebPageGroup*);
void addExistingWebPage(WebPageProxy*, uint64_t pageID);
void removeWebPage(uint64_t pageID);
@@ -144,10 +143,7 @@ private:
WebContext* m_context;
- // NOTE: This map is for WebPageProxies in all WebPageNamespaces that use this process.
WebPageProxyMap m_pageMap;
-
- // NOTE: This map is for WebBackForwardListItems in all WebPageNamespaces and WebPageProxies that use this process.
WebBackForwardListItemMap m_backForwardListItemMap;
HashMap<uint64_t, RefPtr<WebFrameProxy> > m_frameMap;
diff --git a/WebKit2/UIProcess/win/WebView.cpp b/WebKit2/UIProcess/win/WebView.cpp
index a26cfec..cd188a5 100644
--- a/WebKit2/UIProcess/win/WebView.cpp
+++ b/WebKit2/UIProcess/win/WebView.cpp
@@ -33,7 +33,6 @@
#include "WebContextMenuProxyWin.h"
#include "WebEditCommandProxy.h"
#include "WebEventFactory.h"
-#include "WebPageNamespace.h"
#include "WebPageProxy.h"
#include "WebPopupMenuProxyWin.h"
#include <Commctrl.h>
@@ -192,14 +191,9 @@ WebView::WebView(RECT rect, WebContext* context, WebPageGroup* pageGroup, HWND p
, m_trackingMouseLeave(false)
, m_isBeingDestroyed(false)
{
- initialize(context->sharedPageNamespace(), pageGroup, parentWindow);
-}
-
-void WebView::initialize(WebPageNamespace* pageNamespace, WebPageGroup* pageGroup, HWND parentWindow)
-{
registerWebViewWindowClass();
- m_page = pageNamespace->createWebPage(pageGroup);
+ m_page = context->createWebPage(pageGroup);
m_page->setPageClient(this);
m_page->setDrawingArea(ChunkedUpdateDrawingAreaProxy::create(this));
diff --git a/WebKit2/UIProcess/win/WebView.h b/WebKit2/UIProcess/win/WebView.h
index 79092eb..dcc8814 100644
--- a/WebKit2/UIProcess/win/WebView.h
+++ b/WebKit2/UIProcess/win/WebView.h
@@ -37,7 +37,6 @@
namespace WebKit {
class DrawingAreaProxy;
-class WebPageNamespace;
class WebView : public APIObject, public PageClient, WebCore::WindowMessageListener {
public:
@@ -60,8 +59,6 @@ public:
private:
WebView(RECT, WebContext*, WebPageGroup*, HWND parentWindow);
- void initialize(WebPageNamespace*, WebPageGroup*, HWND parentWindow);
-
virtual Type type() const { return TypeView; }
static bool registerWebViewWindowClass();
diff --git a/WebKit2/WebKit2.pro b/WebKit2/WebKit2.pro
index 3d640bc..3f6ca98 100644
--- a/WebKit2/WebKit2.pro
+++ b/WebKit2/WebKit2.pro
@@ -343,7 +343,6 @@ HEADERS += \
UIProcess/WebNavigationData.h \
UIProcess/WebPageContextMenuClient.h \
UIProcess/WebPageGroup.h \
- UIProcess/WebPageNamespace.h \
UIProcess/WebPageProxy.h \
UIProcess/WebPolicyClient.h \
UIProcess/WebPreferences.h \
@@ -534,7 +533,6 @@ SOURCES += \
UIProcess/WebNavigationData.cpp \
UIProcess/WebPageContextMenuClient.cpp \
UIProcess/WebPageGroup.cpp \
- UIProcess/WebPageNamespace.cpp \
UIProcess/WebPageProxy.cpp \
UIProcess/WebPolicyClient.cpp \
UIProcess/WebPreferences.cpp \
diff --git a/WebKit2/WebKit2.xcodeproj/project.pbxproj b/WebKit2/WebKit2.xcodeproj/project.pbxproj
index 5126d8b..48e0b15 100644
--- a/WebKit2/WebKit2.xcodeproj/project.pbxproj
+++ b/WebKit2/WebKit2.xcodeproj/project.pbxproj
@@ -539,8 +539,6 @@
BCEE7DC6128B645D009827DA /* InjectedBundleClient.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BCEE7DC4128B645D009827DA /* InjectedBundleClient.cpp */; };
BCEE966C112FAF57006BCC24 /* Attachment.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BCEE966A112FAF57006BCC24 /* Attachment.cpp */; };
BCEE966D112FAF57006BCC24 /* Attachment.h in Headers */ = {isa = PBXBuildFile; fileRef = BCEE966B112FAF57006BCC24 /* Attachment.h */; };
- BCEE98C6113314D7006BCC24 /* WebPageNamespace.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BCEE98C4113314D7006BCC24 /* WebPageNamespace.cpp */; };
- BCEE98C7113314D7006BCC24 /* WebPageNamespace.h in Headers */ = {isa = PBXBuildFile; fileRef = BCEE98C5113314D7006BCC24 /* WebPageNamespace.h */; };
BCF049E611FE20F600F86A58 /* WKBundleFramePrivate.h in Headers */ = {isa = PBXBuildFile; fileRef = BCF049E411FE20F600F86A58 /* WKBundleFramePrivate.h */; settings = {ATTRIBUTES = (Private, ); }; };
BCF049E711FE20F600F86A58 /* WKBundlePrivate.h in Headers */ = {isa = PBXBuildFile; fileRef = BCF049E511FE20F600F86A58 /* WKBundlePrivate.h */; settings = {ATTRIBUTES = (Private, ); }; };
BCF50121123ED3B3005955AE /* ThreadLauncher.h in Headers */ = {isa = PBXBuildFile; fileRef = BCF5011F123ED3B3005955AE /* ThreadLauncher.h */; };
@@ -1192,8 +1190,6 @@
BCEE7DC4128B645D009827DA /* InjectedBundleClient.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = InjectedBundleClient.cpp; sourceTree = "<group>"; };
BCEE966A112FAF57006BCC24 /* Attachment.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Attachment.cpp; sourceTree = "<group>"; };
BCEE966B112FAF57006BCC24 /* Attachment.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Attachment.h; sourceTree = "<group>"; };
- BCEE98C4113314D7006BCC24 /* WebPageNamespace.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebPageNamespace.cpp; sourceTree = "<group>"; };
- BCEE98C5113314D7006BCC24 /* WebPageNamespace.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebPageNamespace.h; sourceTree = "<group>"; };
BCF049E411FE20F600F86A58 /* WKBundleFramePrivate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKBundleFramePrivate.h; sourceTree = "<group>"; };
BCF049E511FE20F600F86A58 /* WKBundlePrivate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKBundlePrivate.h; sourceTree = "<group>"; };
BCF04C8C11FF9B7D00F86A58 /* APIObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = APIObject.h; sourceTree = "<group>"; };
@@ -1895,8 +1891,6 @@
5153569B1291B1D2000749DC /* WebPageContextMenuClient.h */,
BC7B6205129A0A6700D174A4 /* WebPageGroup.cpp */,
BC7B6204129A0A6700D174A4 /* WebPageGroup.h */,
- BCEE98C4113314D7006BCC24 /* WebPageNamespace.cpp */,
- BCEE98C5113314D7006BCC24 /* WebPageNamespace.h */,
BC111B0B112F5E4F00337BAB /* WebPageProxy.cpp */,
BC032DCB10F4389F0058C15A /* WebPageProxy.h */,
BCBD38FA125BAB9A00D2C29F /* WebPageProxy.messages.in */,
@@ -2477,7 +2471,6 @@
BCF69FA21176D01400471A52 /* WebNavigationData.h in Headers */,
BCF69F9A1176CED600471A52 /* WebNavigationDataStore.h in Headers */,
BC032D8F10F437A00058C15A /* WebPage.h in Headers */,
- BCEE98C7113314D7006BCC24 /* WebPageNamespace.h in Headers */,
BC032DD110F4389F0058C15A /* WebPageProxy.h in Headers */,
1A3E736111CC2659007BD539 /* WebPlatformStrategies.h in Headers */,
BCB9F8B01124E07700A137E0 /* WebPolicyClient.h in Headers */,
@@ -2906,7 +2899,6 @@
BCF69FA31176D01400471A52 /* WebNavigationData.cpp in Sources */,
BC963D6B113DD19200574BE2 /* WebPage.cpp in Sources */,
BC963D6E113DD1A500574BE2 /* WebPageMac.mm in Sources */,
- BCEE98C6113314D7006BCC24 /* WebPageNamespace.cpp in Sources */,
BC111B0F112F5E4F00337BAB /* WebPageProxy.cpp in Sources */,
1A3E736211CC2659007BD539 /* WebPlatformStrategies.cpp in Sources */,
BCB9F8AF1124E07700A137E0 /* WebPolicyClient.cpp in Sources */,
diff --git a/WebKit2/win/WebKit2.vcproj b/WebKit2/win/WebKit2.vcproj
index 613de38..10cbd4a 100755
--- a/WebKit2/win/WebKit2.vcproj
+++ b/WebKit2/win/WebKit2.vcproj
@@ -2063,14 +2063,6 @@
>
</File>
<File
- RelativePath="..\UIProcess\WebPageNamespace.cpp"
- >
- </File>
- <File
- RelativePath="..\UIProcess\WebPageNamespace.h"
- >
- </File>
- <File
RelativePath="..\UIProcess\WebPageProxy.cpp"
>
</File>
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list