diff options
| author | Teng-Hui Zhu <ztenghui@google.com> | 2011-11-07 12:47:43 -0800 |
|---|---|---|
| committer | Teng-Hui Zhu <ztenghui@google.com> | 2011-11-07 13:54:28 -0800 |
| commit | 8852b0905b1a50ca045eb4bd19b2589aad663b5c (patch) | |
| tree | 5ada6868bad7b38b61151f3b8308732bd5ff6a42 /Source/WebKit/android/nav | |
| parent | 1c694b72a5eeade23acf64618e14ab19fcb5801a (diff) | |
| download | external_webkit-8852b0905b1a50ca045eb4bd19b2589aad663b5c.zip external_webkit-8852b0905b1a50ca045eb4bd19b2589aad663b5c.tar.gz external_webkit-8852b0905b1a50ca045eb4bd19b2589aad663b5c.tar.bz2 | |
Change the default webView behavior to minimize the memory consumption
For now, we just limit the expansion on x and y direction.
In the future, we need to dynamically allocate and deallocate the memory.
browser change is : c/148242
bug:5522175
Change-Id: I8562c39c55913ab89848afe8a36e8a2784c12727
Diffstat (limited to 'Source/WebKit/android/nav')
| -rw-r--r-- | Source/WebKit/android/nav/WebView.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/Source/WebKit/android/nav/WebView.cpp b/Source/WebKit/android/nav/WebView.cpp index 10f679d..d4131c0 100644 --- a/Source/WebKit/android/nav/WebView.cpp +++ b/Source/WebKit/android/nav/WebView.cpp @@ -2639,16 +2639,20 @@ static bool nativeSetProperty(JNIEnv *env, jobject obj, jstring jkey, jstring jv TilesManager::instance()->setInvertedScreen(false); return true; } - if (key == "inverted_contrast") { + else if (key == "inverted_contrast") { float contrast = value.toFloat(); TilesManager::instance()->setInvertedScreenContrast(contrast); return true; } - if (key == "enable_cpu_upload_path") { + else if (key == "enable_cpu_upload_path") { TilesManager::instance()->transferQueue()->setTextureUploadType( value == "true" ? CpuUpload : GpuUpload); return true; } + else if (key == "use_minimal_memory") { + TilesManager::instance()->setUseMinimalMemory(value == "true"); + return true; + } return false; } |
