diff options
author | chrishtr@chromium.org <chrishtr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-08-08 21:31:30 +0000 |
---|---|---|
committer | chrishtr@chromium.org <chrishtr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-08-08 21:31:30 +0000 |
commit | da3d7e4c5c71e71ba7b8e1517e6d14bf747f591e (patch) | |
tree | 9ab57028d6d9227d18df5a5c262128f6c95051c4 /android_webview | |
parent | c165e8d5af73c63df563e0286cc1814e4d997afd (diff) | |
download | chromium_src-da3d7e4c5c71e71ba7b8e1517e6d14bf747f591e.zip chromium_src-da3d7e4c5c71e71ba7b8e1517e6d14bf747f591e.tar.gz chromium_src-da3d7e4c5c71e71ba7b8e1517e6d14bf747f591e.tar.bz2 |
Cache the current WebPreferences on RenderViewHostImpl (try #2).
This makes lookups of a WebPreferences field fast.
In order do this, add code to listen to all preferences updates in order to recompute the cache.
The first version was rolled back because some code in Blink that listened for inspector prefs updates
incorrectly sent the preference update back to Chromium, causing an infinite loop.
BUG=390799
Review URL: https://codereview.chromium.org/444843002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@288438 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'android_webview')
-rw-r--r-- | android_webview/native/aw_settings.cc | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/android_webview/native/aw_settings.cc b/android_webview/native/aw_settings.cc index e9ba10e..2a0a50b 100644 --- a/android_webview/native/aw_settings.cc +++ b/android_webview/native/aw_settings.cc @@ -158,8 +158,7 @@ void AwSettings::UpdateWebkitPreferencesLocked(JNIEnv* env, jobject obj) { content::RenderViewHost* render_view_host = web_contents()->GetRenderViewHost(); if (!render_view_host) return; - render_view_host->UpdateWebkitPreferences( - render_view_host->GetWebkitPreferences()); + render_view_host->OnWebkitPreferencesChanged(); } void AwSettings::UpdateInitialPageScaleLocked(JNIEnv* env, jobject obj) { |