summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDerek Sollenberger <djsollen@google.com>2012-05-03 09:55:37 -0400
committerDerek Sollenberger <djsollen@google.com>2012-05-03 10:05:50 -0400
commitdf5b35724c74cc8ac3c497d74c9d4dc449b9073f (patch)
tree4f82ef89e6a4cd3d35f66bd196ca6aed992efb7b
parente859a34171f2a36877d95197d118d962078f8aa0 (diff)
downloadexternal_webkit-df5b35724c74cc8ac3c497d74c9d4dc449b9073f.zip
external_webkit-df5b35724c74cc8ac3c497d74c9d4dc449b9073f.tar.gz
external_webkit-df5b35724c74cc8ac3c497d74c9d4dc449b9073f.tar.bz2
Bump WebView font cache size to 1.5MB for better performance.
bug: 6226962 Change-Id: I3c705e50b7204df6be732422a8fcacacaf5ce7e9
-rw-r--r--Source/WebKit/android/jni/WebViewCore.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/Source/WebKit/android/jni/WebViewCore.cpp b/Source/WebKit/android/jni/WebViewCore.cpp
index 4e6ffc6..5030564 100644
--- a/Source/WebKit/android/jni/WebViewCore.cpp
+++ b/Source/WebKit/android/jni/WebViewCore.cpp
@@ -119,6 +119,7 @@
#include "SkTDArray.h"
#include "SkTypes.h"
#include "SkCanvas.h"
+#include "SkGraphics.h"
#include "SkPicture.h"
#include "SkUtils.h"
#include "Text.h"
@@ -529,6 +530,9 @@ WebViewCore::WebViewCore(JNIEnv* env, jobject javaWebViewCore, WebCore::Frame* m
AndroidNetworkLibraryImpl::InitWithApplicationContext(env, 0);
+ // increase the font cache size beyond the standard system setting
+ SkGraphics::SetFontCacheLimit(1572864); // 1572864 bytes == 1.5 MB
+
// Static initialisation of certain important V8 static data gets performed at system startup when
// libwebcore gets loaded. We now need to associate the WebCore thread with V8 to complete
// initialisation.