Commit Graph

3146 Commits

Author SHA1 Message Date
Ben Murdoch
dc00a84af1 Update WebViewUpdateService to receive PACKAGE_REPLACED broadcast.
This allows the WebViewUpdateService to receive notifications that
an update has been installed and we need to trigger recreation of
the relro file.

bug: 16329377
Change-Id: I088e61487416add997995db304beca0cde71390c
2014-07-17 21:18:40 +00:00
Torne (Richard Coles)
08cfaf6726 Use the WebView's loader library to load the real library.
Load libwebviewchromiumloader and use it to load the real WebView
library, to enable sharing of the relro segment between different
application processes without requiring that the library be preloaded in
the zygote. A system service is added to track whether the relro segment
file has been prepared, and block loading of the library until it has
been.

Bug: 13005501
Change-Id: I846b37c7b8e2a4eb8a39e4fd455bccbb2048c173
2014-07-17 09:18:43 -07:00
Torne (Richard Coles)
b5de924fad Remove WebView library preloading mechanism.
We don't want to preload the WebView library in the zygote process any
more, as loading an updatable WebView in the zygote is a stability risk.
The memory benefits of preloading will be obtained in other ways.

Bug: 13005501
Change-Id: Ic89f2a1d057dc92b01fb775bf326b47ac2d4caa2
2014-07-17 09:18:43 -07:00
Marcin Kosiba
bce81bd03d Merge "Add more params to WebViewClient.shouldInterceptRequest." into lmp-dev 2014-07-15 20:46:43 +00:00
Marcin Kosiba
d72e7ba1c0 Add more params to WebViewClient.shouldInterceptRequest.
This changes shouldInterceptRequest to take an object containing the
following new parameters: isMainFrame, hasUserGesture, method, headers.
This also lets the embedder specify the following additional properties
of the response: status code, response phrase, headers.

BUG: 7589347
Change-Id: Id922c5e7023eb067db871e6f782f599492a2428f
2014-07-15 21:31:44 -07:00
Ben Murdoch
7302f4f8f7 Plumb temporary view detach calls through WebView.
Intercept View#onStartTemporaryDetach/onFinishTemporaryDetach
to handle focus changes correctly.

Bug: 14313621
Change-Id: I92ba2f44359643fee63f30b9c35b1ae4183e4245
2014-07-16 03:28:43 +00:00
Yuncheol Heo
eeba0257a7 Tag hole-punching api with @SystemApi.
Change-Id: I50c27c32abd7e6d2404c451fb53cfb1379b88e00
2014-07-10 20:03:57 +09:00
Selim Gurun
7871554e1a Add an API to disable data reduction proxy.
Bug: 16011253

Under rare circumstances, the application may need to disable the
data reduction proxy. This is to provide a way to do that.

Change-Id: I031f689f9d72460c7241aec78459185e0b31f059
2014-07-09 16:50:00 -07:00
Tao Bai
f6e1112216 Enable new geolocation permission API.
BUG: 14668406
Change-Id: I9500154d14eceae0248eb3718de27fc33fef4f28
2014-07-02 20:38:14 +00:00
Hector Dearman
a70d1d99de Deprecate the Cookie Sync Manager
The CookieSyncManager is largely useless as the WebView
automatically syncs cookies every 30s (whether you like it
or not). The one method which needs to be saved is sync,
there is no other way to force a sync without this.
We move sync to the CookieManager and rename it to flush
for greater consistency.

Bug: 11060034
Change-Id: I8a14998020eea54f196fc6ed845b09ed69cfd447
2014-07-01 13:12:29 +01:00
Hector Dearman
5622e8b669 Merge "Add Third Party Cookie API" 2014-06-26 21:23:48 +00:00
Hector Dearman
fc9a27aa5a Add Third Party Cookie API
Bug: 11678084
Change-Id: Ieb74fb6caae3d5a18dbfe748be47ebebad003cf7
2014-06-25 16:34:37 +01:00
Yuncheol Heo
93415a2713 Add a permission resource for the protected media id.
Matched Chromium change: http://crrev.com/309553004
> aw: Add ProtectedIdPermissionRequest.
>
> The DRM ID can be exploited to identify users. so the information
> should be handled under user's explict permission.
> This CL hooks up Chromium's permission request with Android Webview's
> permission mechanism.
>
> BUG=346841
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=276149

Bug: 11762354

Change-Id: Ife3c123ecca2c577ed1bc02a110b87618c6569cf
2014-06-20 19:00:28 +09:00
Richard Coles
2995606963 Merge "Connect WebView Async Cookie APIs" 2014-06-17 05:13:46 +00:00
Hector Dearman
24a11d311c Connect WebView Async Cookie APIs
Bug: 14379829
Change-Id: I6b0e0644153a805eccb48d30b0ad3e91babd8093
2014-06-17 15:32:07 +01:00
Selim Gurun
1b6e10bcca Unhide the file API
Bug: 6930981
Change-Id: I4818d5dff3cb05b38e4d8f9f817e4fcdeade7f00
2014-06-16 11:52:05 -07:00
Selim Gurun
4ffd507e67 am a5aa4b48: Merge "Address the API review" into lmp-preview-dev
* commit 'a5aa4b4879761a93c936303cf5c34d499aa0fe76':
  Address the API review
2014-06-13 19:25:35 +00:00
Selim Gurun
ee89ab4dd5 Address the API review
Bug: 15432556

The api council asks to change the interface to an abstract class
and clarify the clearClientCertPreferences api. This change addresses
these.

Change-Id: I7979788c7c041bacbfef5ea4d94309f91279ef22
2014-06-13 10:53:55 -07:00
Selim Gurun
1ac3e017d4 Merge "Add WebChromeClient.showFileChooser" 2014-06-10 22:13:32 +00:00
Jonathan Dixon
3a5cf3876c Add WebChromeClient.showFileChooser
Bug: 6930981

This replaces the never-published openFileChooser, and is more future
extensible.
Currently hidden; will unhide once working end to end and tested.

Change-Id: Ie66750be37e5b90e4a411cec76278369dc8dabe8
2014-06-10 13:58:07 -07:00
Kristian Monsen
638c078c87 Remove unused function from the WebView statics
Change-Id: I47c47c44d4b5b6f4a4f366affa9d110de440ade5
2014-06-05 10:14:23 -07:00
Hector Dearman
13d6cfb3b5 Merge "Removes bad comment from CookieManager" 2014-06-04 17:12:36 +00:00
Yuncheol Heo
4d07c48e48 Add API definition for WebSettings.setVideoOverlayForEmbeddedEncryptedVideoEnabled.
Introduces an API to control the hole-punching for the embedded
encrypted media.

Bug: 14598993
Change-Id: I6b473e5b38b0bcc243f43dfeba0c2037fcd37af5
2014-05-23 10:34:59 +09:00
Ben Murdoch
73f328953a am 4088970d: am 3011fc1a: Merge "Fallback to NullWebView when Chromium WebView not present." into klp-modular-dev
* commit '4088970dce354f53911f78084a32cb78af45baaf':
  Fallback to NullWebView when Chromium WebView not present.
2014-05-19 11:35:04 +00:00
Ben Murdoch
4088970dce am 3011fc1a: Merge "Fallback to NullWebView when Chromium WebView not present." into klp-modular-dev
* commit '3011fc1aa7dbffd3faab7d41203f63d2c0b50c2c':
  Fallback to NullWebView when Chromium WebView not present.
2014-05-19 11:30:41 +00:00
Hector Dearman
0ac81cb785 Removes bad comment from CookieManager
A change that made the setCookie() docs say setCookie rejected
session cookies was introduced here
https://googleplex-android-review.git.corp.google.com
/#/c/166946/3/core/java/android/webkit/CookieManager.java
and looks like it was just a mistaken rephrasing of the original docs.

This change removes that comment from the current docs.

Bug: 14379829
Change-Id: I36ae708f55faf424424ea18f75c89872e7c71312
2014-05-19 10:20:59 +01:00
Ben Murdoch
0e04bcfbdc Fallback to NullWebView when Chromium WebView not present.
If it's not possible to load the Chromium WebView, fallback to loading
the NullWebView that will throw UnsupportedOperationException.

Bug: 13438487
Change-Id: If44b8b7a569c2f8e0e8bba7e6953288802d1c9e0
2014-05-16 13:41:12 +01:00
Selim Gurun
6e1e0e2ec4 Webview Cleanup part 2
Bug: 1231013

Move classes only needed by Browser to browser package.

Change-Id: I7c8080a74a15c06040e0ac0d4b713afbfd02e2e0
2014-05-15 16:05:40 -07:00
Selim Gurun
049803a00e Merge "Cleanup remainings of old webview." 2014-05-09 21:50:31 +00:00
Mikhail Naganov
3b2f548b67 am a08771ed: am fa75ff62: am b76bc8e0: am 6940b664: Add EventLog event for logging of attempts to call java.lang.Object.getClass
* commit 'a08771edfaabab8c2f1f1d552f788c9c4a4162f9':
  Add EventLog event for logging of attempts to call java.lang.Object.getClass
2014-05-09 16:26:19 +00:00
Mikhail Naganov
a08771edfa am fa75ff62: am b76bc8e0: am 6940b664: Add EventLog event for logging of attempts to call java.lang.Object.getClass
* commit 'fa75ff626ca48db1007105fa5fd72d83c81c56e2':
  Add EventLog event for logging of attempts to call java.lang.Object.getClass
2014-05-09 16:19:12 +00:00
Ben Murdoch
b2e56e34de Hide android.webkit.PermissionRequest.RESOURCE_GEOLOCATION
We haven't hooked this constant up yet, so @hide from the API until
it's ready.

Bug: 14668406
Change-Id: Ia0bb2ac1deaa0575d5ceb509997ca27f930040b0
2014-05-09 13:25:48 +01:00
Selim Gurun
2bfd9839aa Cleanup remainings of old webview.
Cleanup some code that remained from old webview.

Change-Id: I7b654a40284ff88a0a42c7407ad0b2499000f77d
2014-05-08 19:33:58 -07:00
Mikhail Naganov
6940b66409 Add EventLog event for logging of attempts to call java.lang.Object.getClass
Bug: 13694467
Change-Id: I886c6ffb3a008d0cf701c1adc16c607cbf7dce39
2014-05-08 10:10:24 +01:00
Tao Bai
fa1fd2cb7d Public WebView permission API
BUG: 13699047
Change-Id: Ibcc8c0d4f1bba4365cb71c1991a0fcb1d7febb94
2014-05-06 21:17:54 -07:00
Selim Gurun
a83f1e3d23 Add frameworks/base changes for enabling reduction proxy
Bug:12492817

Add an experimental webview setting to developer options to enable
data reduction proxy.

Change-Id: Id73d7f5d655a7de18afff766c5c78209c92964ea
2014-05-05 17:28:04 -07:00
Selim Gurun
87a0351ddc Add an import missing
Change-Id: I99a15779bff3bae5dd78d823d1f6c7f644c98751
2014-05-02 14:52:49 -07:00
Selim Gurun
8b414fc483 Fix javadoc breakage
Change-Id: I2667bdb6b4ea76c2f81bae77ceaecb3391e4521b
2014-05-02 14:40:41 -07:00
Selim Gurun
f271c8ecd0 Unhide Client Cert APIS
Bug:12983007
Change-Id: I9ae23be110ff036ce64271841e1ba69122ce6caa
2014-05-02 14:19:16 -07:00
Selim Gurun
e1c6c3ae21 Design a static API for clearclientcertpreferences
Bug: 12983007

Change-Id: I869b4cd4c178b8fedf725f108fd2e369895543e9
2014-05-02 13:08:55 -07:00
Michael Wright
428d1e40a9 Merge "Fix WebViewClient docs" 2014-05-02 16:29:27 +00:00
Ben Murdoch
fe9fc3d1a3 Add API definition for WebSettings.allowMixedContent
Introduces an API for configuring how the WebView behaves with
regard to referencing insecure content from a secure origin.

By default, apps targeting <= KK will allow mixed content. New apps
will block all insecure content.

Bug: 13948531
Change-Id: Ie773ee144e223f78b6449da0a8564192dd9c1c5d
2014-05-02 14:17:25 +01:00
Michael Wright
1feb11f511 Fix WebViewClient docs
Change-Id: I960701a49be66fccfd03a8876779a5f7917642ea
2014-05-01 15:41:33 -07:00
Michael Wright
e02bfb6fbd Merge "Add unhandledInputEvent API to ViewRoot" 2014-05-01 21:15:29 +00:00
Michael Wright
899d70568b Add unhandledInputEvent API to ViewRoot
Update WebViewClient to use it instead, and add a new public API,
onUnhandledInputEvent. Note that WebViewClients won't receive this
call back until WebView is updated to use it.

Bug: 14279909

Change-Id: Ied49791b469849f5c4cf4471f2b26c56b03f4961
2014-04-29 15:02:34 -07:00
Kristian Monsen
10ca8088f6 Try to not start up chromium when not needed
Also thread behaviour from static methods is not easily understood.

Change-Id: Icedeef70738f35891fa9562d717b119104756ba9
2014-04-29 11:09:47 -07:00
Selim Gurun
f2d50e5536 Clarify a use case.
Clarify a use case regarding clearing client certificates.

Change-Id: Ifdfa00022bb21b26e6f62dbad585faef4f8fc3c7
2014-04-25 09:39:31 -07:00
Selim Gurun
7466e3bbbd am e3fc3073: am 8c2d70f5: Merge "Add a stub for forgotten callback to fix master-gpl."
* commit 'e3fc3073826b4fdfa0d1be17fe0c79ccf211ad7d':
  Add a stub for forgotten callback to fix master-gpl.
2014-04-25 01:15:36 +00:00
Selim Gurun
8c2d70f5e8 Merge "Add a stub for forgotten callback to fix master-gpl." 2014-04-25 01:08:48 +00:00
Selim Gurun
4e48f40b03 Add a stub for forgotten callback to fix master-gpl.
Change-Id: I375dba89403d09dc39f696de04e0811633ecc803
2014-04-24 18:04:04 -07:00