diff options
author | boliu@chromium.org <boliu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-11-21 12:34:09 +0000 |
---|---|---|
committer | boliu@chromium.org <boliu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-11-21 12:34:09 +0000 |
commit | 1f0d041d875f287e1da906c39db249f713433ef2 (patch) | |
tree | 3c193ea4634a524e511967722d9f582571451d3a /android_webview/android_webview_tests.gypi | |
parent | f45a5f17a7cd4b7819f59fd0048cf6f6f37113b0 (diff) | |
download | chromium_src-1f0d041d875f287e1da906c39db249f713433ef2.zip chromium_src-1f0d041d875f287e1da906c39db249f713433ef2.tar.gz chromium_src-1f0d041d875f287e1da906c39db249f713433ef2.tar.bz2 |
Android WebView save/restoreState and backForardList Part 1
Design for save/restoreState is do all serialization in native and pass
an opaque byte array to java to put into the bundle.
This patch contains the native code to (de)serialize a WebContents with
some unit test coverage.
Reasons for not re-using TabNavigation under chrome/:
* Android WebView has different requirements for fields to store since
we are the only ones using values like base_url_for_data_url.
* TabNavigation does unnecessary copying of data, which in Android
WebView case, is undesired since save/restore is called in Android
very frequently.
* TabNavigation is tightly integrated with the rest of chrome session
restore and sync code, and has other purpose in addition to serializing
NavigationEntry.
Optimization-wise, there will be an unnecessary copy when converting
native to java byte array. Only way to avoid it is to know the
allocation size before pickling starts. Maybe consider pre-computing the
size (brittle), or use chrome's design of capping the size of the data
and throwing away old entries and "less important" information. Only
consider this if speed becomes a problem.
BUG=
Android WebView only change. Ran through trybots.
NOTRY=true
Review URL: https://chromiumcodereview.appspot.com/11420056
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@169024 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'android_webview/android_webview_tests.gypi')
-rw-r--r-- | android_webview/android_webview_tests.gypi | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/android_webview/android_webview_tests.gypi b/android_webview/android_webview_tests.gypi index 20585b5..fb9317f 100644 --- a/android_webview/android_webview_tests.gypi +++ b/android_webview/android_webview_tests.gypi @@ -45,6 +45,7 @@ 'sources': [ 'lib/main/webview_tests.cc', 'native/android_stream_reader_url_request_job_unittests.cc', + 'native/state_serializer_unittests.cc', ], }, { |