Commit Graph

2994 Commits

Author SHA1 Message Date
Jonathan Dixon
cb64bb4b16 Add some logging when the webview dev setting changes
Bug: 9773865

This will not be visible in shipping config, so shouldn't be a major
source of log spam.

Change-Id: If09734b70e59aeab87c6dddee72212aa6748505f
2013-07-30 16:21:32 -07:00
Jonathan Dixon
d8501485e3 Build fix for WebViewFactory
Make fields public again until users are no longer using them

Change-Id: I27d06ca8478f5ba44940e8ce15d65df97cbbb5f1
2013-07-29 13:05:52 -07:00
Jonathan Dixon
a7eaa8ee22 Add accessors for WebViewFactory.UseExperimentalWebView
In preperation for flag-flip, have Settings app access the current
state via methods that are neutral to the on/off state.
Also setup the property to change name when enabled by default, to reset
any user changes to this setting.

Change-Id: I55017bcd89573c1ecac7de8913264d9cf66fdcd9
2013-07-29 11:45:34 -07:00
Jonathan Dixon
fa80ad95d3 Merge "Remove spurious @Deprecate tag from WebView.onMeasure" 2013-07-27 01:40:18 +00:00
Jonathan Dixon
697c8ed523 Remove spurious @Deprecate tag from WebView.onMeasure
onMeasure is not deprecated, this tag is spurious (and has no effect on
the api.txt or SDK anyway)

Change-Id: Iae003727649e86db2e0adaa5071399b676526c38
2013-07-26 16:40:02 -07:00
Ben Murdoch
597256e128 Update WebView.loadDataWithBaseURL documentation.
Clarify behavior around base URLs with data: vs. non-data: schemes.

Bug: 9894754
Change-Id: I335253c07a13f3d4a5485b6ff11e53bd1580a890
2013-07-23 15:15:21 +01:00
Ben Murdoch
a5cdd51cb7 Add WebView.evaluateJavaScript(String, ValueCallback) API.
This API is intended to replace the "WebView.loadUrl("javascript:...")
pattern that is the current mechanism for executing JavaScript in the
context of the current page displayed in the WebView.

The new API is more convenient - it doesn't trigger the normal URL
loading path - and so does not have side effects such as hiding
the keyboard - and allows the caller to specify a callback that will
be invoked once the script execution is complete.

BUG=9814043

Change-Id: I3f27e8ff5371077d9265430090d61381a3a86e76
2013-07-19 10:24:05 +01:00
Ben Murdoch
e3f9071e0d Plumb View.getAccessibilityNodeProvider though WebViewProvider.
This is needed to make use of the new Accessibility implementation
in the Chromium WebView. nos for WebView Classic.

Change-Id: I96bd2426d2de3b26dc9b72d0fdbacefa9bbe20f7
2013-07-11 14:41:46 +01:00
Ben Murdoch
db2302513b Revert "Plumb View.getAccessibilityNodeProvider though WebViewProvider."
This reverts commit 150cf1c15b.
2013-06-29 01:02:48 +01:00
Ben Murdoch
d08ee870a0 Merge "Plumb View.getAccessibilityNodeProvider though WebViewProvider." 2013-06-28 21:18:03 +00:00
John Reck
ced29a54b6 am 52dbdbf2: am 9d2b0dbf: am 12c4c0e4: Merge "Fix deadlock of WebViewCoreThread"
* commit '52dbdbf2d10f4e53f76c40a0bed0ffe31301f1f0':
  Fix deadlock of WebViewCoreThread
2013-06-25 17:02:08 -07:00
John Reck
9d2b0dbf67 am 12c4c0e4: Merge "Fix deadlock of WebViewCoreThread"
* commit '12c4c0e45b12be18005f0ad2af2433e34dcb1a9f':
  Fix deadlock of WebViewCoreThread
2013-06-25 15:31:39 -07:00
Ben Murdoch
150cf1c15b Plumb View.getAccessibilityNodeProvider though WebViewProvider.
This is needed to make use of the new Accessibility implementation
in the Chromium WebView. nos for WebView Classic.

Change-Id: I8e26035d15af494e4caa50b4c6c7cb4ac8efeb9e
2013-06-24 23:57:06 +01:00
Torne (Richard Coles)
03ce9b3e69 Enable preloading of the appropriate WebView.
Allow the appropriate WebView to be preloaded in the zygote by
constructing the currently selected WebViewFactoryProvider when the
WebViewFactory is preloaded. At runtime, if the preloaded provider is
still the current selection, the preloaded instance is used, otherwise
the provider is loaded at that time.

This change also removes "graceful" fallback from the experimental
WebView to the classic implementation: if the option to use the
experimental WebView is selected and it could not be loaded
successfully at the time a WebView is created, an exception will be
thrown, rather than allowing execution to continue with the classic
implementation, as the fallback may mislead developers who do not
examine logcat output in detail.

Change-Id: I0cd01c784d7048abeac55ab5863ca16b8fd9ecf2
2013-06-19 15:03:08 +01:00
Primiano Tucci
eb665d66ba Deprecate webview.use_chromium and introduce webview.force_provider.
The new webview.force_provider property, when set, enforces the use
of Chromium or classic WebView, regardless the value of the
persist.sys.webview.exp (accessible through the settings UI).
This will help telemetry tests to run correctly regardless of UI
settings.

Change-Id: Ica5a0faa7f7539c22332cac5a8946f11fb7df6b2
2013-06-17 16:03:55 +01:00
Torne (Richard Coles)
eb07f3cad0 WebViewChromium: don't use a separate class loader.
Use the ordinary system class loader to load the Chromium-based WebView
implementation classes now that the implementation .jar is part of the
boot class path. Instead of checking for the .jar file's existence, just
check to see if we can load the class to determine whether the new
WebView is available.

This also removes the check for Build.IS_DEBUGGABLE; the Chromium-based
WebView will now be available in user builds if enabled in the developer
options.

Change-Id: I06bae9b91656aa41b09c0e6f63f90736db993418
2013-06-11 14:26:44 +01:00
Mikhail Naganov
8887b2b4f1 Specify that WebSettings.{get|set}DefaultZoom are not recommented to use
Alternatives are advised in the JavaDoc. The settings will be marked as
deprecated in the K release.

Bug: 9004875

Change-Id: I033be03f14244390016cb2b40337aab1df945465
2013-05-29 21:19:40 +01:00
Marco Nelissen
1d3488cba9 am 86e0b491: Merge "Add VideoView.getAudioSessionId()" into jb-mr2-dev
* commit '86e0b491d1b50e59221420de3005184b1dee8373':
  Add VideoView.getAudioSessionId()
2013-05-10 12:44:05 -07:00
Marco Nelissen
13bfebd6b7 Add VideoView.getAudioSessionId()
This lets apps get the audio session id of the video being played, so
they can apply effects to the audio track.
b/8767565

Change-Id: Iaa39d97d0b6fb528ed04b52d579afa58444ebcfe
2013-05-09 15:50:38 -07:00
Yuya Aoki
dae43b16a7 Fix deadlock of WebViewCoreThread
There was a deadlock in destroy process.
Investigation showed that WebViewCoreThread is waiting some
callbacks but in this case WebViewCoreThread can not resume
itself not to call notify method.

Flow:
1. CallbackProxy.sendMessageToUiThreadSync
2. WebViewClassic.destroy()
3. CallbackProxy.blockMessages()
4. CallbackProxy.handleMessage is called via MainThread
5. The WebViewCoreThread deadlock is occured.

The cases we have to call notify method are followings.
OVERRIDE_URL
CREATE_WINDOW
SAVE_PASSWORD
NOTIFY
OPEN_FILE_CHOOSER
JS_ALERT
JS_CONFIRM
JS_PROMPT
JS_UNLOAD
JS_TIMEOUT

Change-Id: I9d95ae500bf6338d77b32b5fa15de7cff5720d0f
2013-05-01 14:56:22 +09:00
Alan Viverette
a7fa0079a7 am 561dcc58: Merge "Avoid crash when TextToSpeech calls onInit() from the constructor." into jb-mr2-dev
* commit '561dcc5823eec20c48d116531556b32e9de66f91':
  Avoid crash when TextToSpeech calls onInit() from the constructor.
2013-04-30 14:04:13 -07:00
Kenny Root
e9ae6822a8 resolved conflicts for merge of 1f6e789b to jb-mr2-dev-plus-aosp
Change-Id: I06c05d637613215b6d83df3e29cd495f6a5a0176
2013-04-29 23:09:03 -07:00
John Reck
be53f1806c am 28d91bdb: Merge "Revert "Can not mark the same content of browser page after copy""
* commit '28d91bdbde63ba1afe3bb67c5466527ec7184217':
  Revert "Can not mark the same content of browser page after copy"
2013-04-29 22:53:57 -07:00
Kenny Root
1f6e789b7e Merge "Track change to JSSE provider" 2013-04-30 04:02:01 +00:00
John Reck
28d91bdbde Merge "Revert "Can not mark the same content of browser page after copy"" 2013-04-30 01:21:31 +00:00
John Reck
8717061f5b Revert "Can not mark the same content of browser page after copy"
This reverts commit 2b3cef0dd7

Causes crashes in Email, reverting for now

Change-Id: Ia0286763d0ab1f90c2b6082d44a6ca804769f49c
2013-04-30 01:17:15 +00:00
Kenny Root
12e752225a Track change to JSSE provider
Change-Id: I35e824e47ad758ab6408e91e2ba5dcda053a82f5
2013-04-29 15:15:27 -07:00
Alan Viverette
76f0c217fc Avoid crash when TextToSpeech calls onInit() from the constructor.
If construction of a TextToSpeech object fails, it may call the
initialization listener's onInit() method before the assignment
of the constructed TextToSpeech object to a variable has occurred.

BUG: 8744558
Change-Id: I3404fdb39308009762371154b05d3653bab81ab2
2013-04-29 14:59:04 -07:00
Kenny Root
d334cb13d6 am d152f7ec: Merge "Don\'t use X509CertImpl directly"
* commit 'd152f7ec1ae43d77ff8e2206724ce71da3da9913':
  Don't use X509CertImpl directly
2013-04-29 14:16:09 -07:00
Kenny Root
28b1f0ee02 Don't use X509CertImpl directly
Change-Id: Ibabee35c90c2636c6f362e4d778d6795a0cef6c2
2013-04-29 13:27:39 -07:00
Victoria Lease
aae1b5163c am b0e0e54d: Merge "Can not mark the same content of browser page after copy"
* commit 'b0e0e54d9dbef720ac653ed87d8ed6b46e1abdbe':
  Can not mark the same content of browser page after copy
2013-04-26 10:27:02 -07:00
Kristian Monsen
5866570947 Merge "Workaround for bug 8700358: Reproducible WebView crash in Feedly starting in JWR22B" into jb-mr2-dev 2013-04-26 00:06:16 +00:00
Kristian Monsen
62cadf153f Workaround for bug 8700358: Reproducible WebView crash in Feedly starting in JWR22B
Catching all excptions from reading from the AssetManager

Change-Id: I53f99484deda3778307eab2ae86ca9fc0ad2fead
2013-04-24 16:41:24 -07:00
Selim Gurun
940718d859 am a6854579: am fa1f7d21: am 07c9c291: am a2b0b35e: am 5fba3404: am 3c4fa654: am 679c8f68: am 38915fd4: Revert "Add a delimiter between scheme and host"
* commit 'a68545796da33bd7fde616958e6abc7548d0a975':
  Revert "Add a delimiter between scheme and host"
2013-04-20 00:38:31 -07:00
Selim Gurun
a68545796d am fa1f7d21: am 07c9c291: am a2b0b35e: am 5fba3404: am 3c4fa654: am 679c8f68: am 38915fd4: Revert "Add a delimiter between scheme and host"
* commit 'fa1f7d21e97b7225f1e7553abc0eebe06cc79367':
  Revert "Add a delimiter between scheme and host"
2013-04-20 00:35:29 -07:00
Selim Gurun
3c4fa65480 am 679c8f68: am 38915fd4: Revert "Add a delimiter between scheme and host"
* commit '679c8f689f6799d143719bb8eb839e2640bf9d07':
  Revert "Add a delimiter between scheme and host"
2013-04-20 00:19:41 -07:00
Geremy Condra
464be7975f am 30504327: am 62588d79: am 8f87c5d8: am ed1e5a87: am b7787a31: DO NOT MERGE Merge commit \'8225df00\' into bp
* commit '30504327364a7ad641c09a227f7930b9fba91614':
  Add a delimiter between scheme and host
2013-04-19 23:19:20 -07:00
Geremy Condra
b7787a317f DO NOT MERGE Merge commit '8225df00' into bp
Add a delimiter between scheme and host

Bug: 6923539
Change-Id: Ic5e19f96c64367c9dc0e3168850309cdd5047e47
2013-04-18 11:40:09 -07:00
Kristian Monsen
87c67f315c Merge "Part of fix for bug 8629392" into jb-mr2-dev 2013-04-17 02:22:26 +00:00
Kristian Monsen
083c4dc1ac Part of fix for bug 8629392
Adding extra logging to fix cts bugs that are only on bots

Change-Id: I24b4b7aad200ffc23c002f4a8f0fe9246991c4f0
2013-04-16 18:14:47 -07:00
Kristian Monsen
639857f7f4 Merge "Fix for bug 8607049: Improve javascript dialogs for classic" into jb-mr2-dev 2013-04-15 23:54:43 +00:00
Kristian Monsen
98dedf7ccc Fix for bug 8607049: Improve javascript dialogs for classic
Make a common JsDialogHelper for classic and chromium webview
Improve on before unload dialog

Change-Id: Ib9711e4f95189ef8b2b31fc64aec7c0cb535d0e4
2013-04-15 10:22:34 -07:00
Ben Murdoch
7e157f321c Merge "Deprectate WebViewDatabase password methods." into jb-mr2-dev 2013-04-15 15:48:25 +00:00
Kristian Monsen
03499a23f9 Merge "Fix for bug 8589670: Marking a not called WebChromeClient as deprecated." into jb-mr2-dev 2013-04-12 21:05:15 +00:00
Kristian Monsen
83b002584c Merge "Fix for bug 8577776 Throw exception if app calls WebView used on wrong thread" into jb-mr2-dev 2013-04-12 04:50:20 +00:00
Ben Murdoch
924ac51ea6 Deprectate WebViewDatabase password methods.
Bug: 8593749
Change-Id: I3d87fa43731a275af95f00933a5439d17a16ae80
2013-04-11 13:51:59 +01:00
Kristian Monsen
b5cd8c0a81 Fix for bug 8577776 Throw exception if app calls WebView used on wrong thread
Mostly copied and pasted from the bug report.

Change-Id: I57cd19961f51fce266025d76ad9273a24f629c5b
2013-04-10 19:04:40 -07:00
Kristian Monsen
0e0b2daa98 Fix for bug 8589670: Marking a not called WebChromeClient as deprecated.
This is just a documentation improvement, the method is not called anymore.

Change-Id: I6f704f7f1a5eef5048b7bf2c52c0589bc8e99839
2013-04-10 15:04:59 -07:00
Peter Nilsson
2b3cef0dd7 Can not mark the same content of browser page after copy
Marking a text on the web page and then press copy works,
but trying to mark the same text again does not work.
The reason for this is that the selection never gets
cleared in webkit.
The fix, calling cleaSelection in the onDestroyActionMode.
Also added clearSelection when getting an
onConfigurationChange.

Change-Id: I59b384cb5441b6a3a05007ea7e77f9699889a87c
2013-04-10 18:50:10 +02:00
Jonathan Dixon
f38b070b31 Merge "Hide PlusinsEnabled/PluginsPath methods" into jb-mr2-dev 2013-04-09 20:09:29 +00:00