[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:42:00 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 5278d896f485121113bd907df4abc09938938cb7
Author: weinig at apple.com <weinig at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Wed Dec 15 23:55:22 2010 +0000

    Loading webkit.org over and over is slower in WebKit2 than WebKit1, looks like page is not cached
    <rdar://problem/8774683>
    https://bugs.webkit.org/show_bug.cgi?id=51143
    
    Reviewed by Brady Eidson.
    
    * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
    (WebKit::WebFrameLoaderClient::canCachePage): Return true as long as we
    are not a custom representation (eg. a PDF).
    (WebKit::WebFrameLoaderClient::shouldCacheResponse): Always return true.
    * WebProcess/WebPage/WebPage.cpp:
    (WebKit::WebPage::updatePreferences): Enable the page cache.
    
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@74157 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKit2/ChangeLog b/WebKit2/ChangeLog
index 1a7a67f..e10f4bc 100644
--- a/WebKit2/ChangeLog
+++ b/WebKit2/ChangeLog
@@ -1,3 +1,18 @@
+2010-12-15  Sam Weinig  <sam at webkit.org>
+
+        Reviewed by Brady Eidson.
+
+        Loading webkit.org over and over is slower in WebKit2 than WebKit1, looks like page is not cached
+        <rdar://problem/8774683>
+        https://bugs.webkit.org/show_bug.cgi?id=51143
+
+        * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
+        (WebKit::WebFrameLoaderClient::canCachePage): Return true as long as we
+        are not a custom representation (eg. a PDF).
+        (WebKit::WebFrameLoaderClient::shouldCacheResponse): Always return true.
+        * WebProcess/WebPage/WebPage.cpp:
+        (WebKit::WebPage::updatePreferences): Enable the page cache.
+
 2010-12-15  Simon Fraser  <simon.fraser at apple.com>
 
         Reviewed by Adele Peterson.
diff --git a/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp b/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp
index df97bd9..2b6c3cf 100644
--- a/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp
+++ b/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp
@@ -1066,8 +1066,9 @@ void WebFrameLoaderClient::dispatchDidBecomeFrameset(bool value)
 
 bool WebFrameLoaderClient::canCachePage() const
 {
-    notImplemented();
-    return false;
+    // We cannot cache frames that have custom representations because they are
+    // rendered in the UIProcess. 
+    return !m_frameHasCustomRepresentation;
 }
 
 void WebFrameLoaderClient::download(ResourceHandle* handle, const ResourceRequest& request, const ResourceRequest& initialRequest, const ResourceResponse& response)
@@ -1222,8 +1223,7 @@ NSCachedURLResponse* WebFrameLoaderClient::willCacheResponse(DocumentLoader*, un
 #if USE(CFNETWORK)
 bool WebFrameLoaderClient::shouldCacheResponse(DocumentLoader*, unsigned long identifier, const ResourceResponse&, const unsigned char* data, unsigned long long length)
 {
-    notImplemented();
-    return false;
+    return true;
 }
 
 #endif
diff --git a/WebKit2/WebProcess/WebPage/WebPage.cpp b/WebKit2/WebProcess/WebPage/WebPage.cpp
index 1604015..c52b8a5 100644
--- a/WebKit2/WebProcess/WebPage/WebPage.cpp
+++ b/WebKit2/WebProcess/WebPage/WebPage.cpp
@@ -981,7 +981,9 @@ void WebPage::updatePreferences(const WebPreferencesStore& store)
 #if ENABLE(DATABASE)
     AbstractDatabase::setIsAvailable(store.getBoolValueForKey(WebPreferencesKey::databasesEnabledKey()));
 #endif
-    
+
+    settings->setUsesPageCache(true);
+
     platformPreferencesDidChange(store);
 }
 

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list