summaryrefslogtreecommitdiff
path: root/Source/WebKit2/WebProcess/WebProcess.cpp
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@nokia.com>2012-08-21 10:57:44 +0200
committerSimon Hausmann <simon.hausmann@nokia.com>2012-08-21 10:57:44 +0200
commit5ef7c8a6a70875d4430752d146bdcb069605d71d (patch)
treef6256640b6c46d7da221435803cae65326817ba2 /Source/WebKit2/WebProcess/WebProcess.cpp
parentdecad929f578d8db641febc8740649ca6c574638 (diff)
downloadqtwebkit-5ef7c8a6a70875d4430752d146bdcb069605d71d.tar.gz
Imported WebKit commit 356d83016b090995d08ad568f2d2c243aa55e831 (http://svn.webkit.org/repository/webkit/trunk@126147)
New snapshot including various build fixes for newer Qt 5
Diffstat (limited to 'Source/WebKit2/WebProcess/WebProcess.cpp')
-rw-r--r--Source/WebKit2/WebProcess/WebProcess.cpp33
1 files changed, 28 insertions, 5 deletions
diff --git a/Source/WebKit2/WebProcess/WebProcess.cpp b/Source/WebKit2/WebProcess/WebProcess.cpp
index 6eb8ab7ee..1490ff3ca 100644
--- a/Source/WebKit2/WebProcess/WebProcess.cpp
+++ b/Source/WebKit2/WebProcess/WebProcess.cpp
@@ -80,6 +80,10 @@
#include <wtf/PassRefPtr.h>
#include <wtf/RandomNumber.h>
+#if ENABLE(WEB_INTENTS)
+#include <WebCore/PlatformMessagePortChannel.h>
+#endif
+
#if ENABLE(NETWORK_INFO)
#include "WebNetworkInfoManagerMessages.h"
#endif
@@ -311,6 +315,7 @@ void WebProcess::setShouldUseFontSmoothing(bool useFontSmoothing)
void WebProcess::userPreferredLanguagesChanged(const Vector<String>& languages) const
{
overrideUserPreferredLanguages(languages);
+ languageDidChange();
}
void WebProcess::fullKeyboardAccessModeChanged(bool fullKeyboardAccessEnabled)
@@ -791,12 +796,32 @@ WebPageGroupProxy* WebProcess::webPageGroup(const WebPageGroupData& pageGroupDat
return result.iterator->second.get();
}
+#if ENABLE(WEB_INTENTS)
+uint64_t WebProcess::addMessagePortChannel(PassRefPtr<PlatformMessagePortChannel> messagePortChannel)
+{
+ static uint64_t channelID = 0;
+ m_messagePortChannels.add(++channelID, messagePortChannel);
+
+ return channelID;
+}
+
+PlatformMessagePortChannel* WebProcess::messagePortChannel(uint64_t channelID)
+{
+ return m_messagePortChannels.get(channelID).get();
+}
+
+void WebProcess::removeMessagePortChannel(uint64_t channelID)
+{
+ m_messagePortChannels.remove(channelID);
+}
+#endif
+
static bool canPluginHandleResponse(const ResourceResponse& response)
{
String pluginPath;
bool blocked;
- if (!WebProcess::shared().connection()->sendSync(Messages::WebContext::GetPluginPath(response.mimeType(), response.url().string()), Messages::WebContext::GetPluginPath::Reply(pluginPath, blocked), 0))
+ if (!WebProcess::shared().connection()->sendSync(Messages::WebProcessProxy::GetPluginPath(response.mimeType(), response.url().string()), Messages::WebProcessProxy::GetPluginPath::Reply(pluginPath, blocked), 0))
return false;
return !blocked && !pluginPath.isEmpty();
@@ -855,7 +880,7 @@ void WebProcess::getSitesWithPluginData(const Vector<String>& pluginPaths, uint6
Vector<String> sites;
copyToVector(sitesSet, sites);
- connection()->send(Messages::WebContext::DidGetSitesWithPluginData(sites, callbackID), 0);
+ connection()->send(Messages::WebProcessProxy::DidGetSitesWithPluginData(sites, callbackID), 0);
}
void WebProcess::clearPluginSiteData(const Vector<String>& pluginPaths, const Vector<String>& sites, uint64_t flags, uint64_t maxAgeInSeconds, uint64_t callbackID)
@@ -879,7 +904,7 @@ void WebProcess::clearPluginSiteData(const Vector<String>& pluginPaths, const Ve
}
#endif
- connection()->send(Messages::WebContext::DidClearPluginSiteData(callbackID), 0);
+ connection()->send(Messages::WebProcessProxy::DidClearPluginSiteData(callbackID), 0);
}
#endif
@@ -981,9 +1006,7 @@ void WebProcess::getWebCoreStatistics(uint64_t callbackID)
data.statisticsNumbers.set("CachedFontDataInactiveCount", fontCache()->inactiveFontDataCount());
// Gather glyph page statistics.
-#if !(PLATFORM(QT) && !HAVE(QRAWFONT)) // Qt doesn't use the glyph page tree currently. See: bug 63467.
data.statisticsNumbers.set("GlyphPageCount", GlyphPageTreeNode::treeGlyphPageCount());
-#endif
// Get WebCore memory cache statistics
getWebCoreMemoryCacheStatistics(data.webCoreCacheStatistics);