Commit Graph

49232 Commits

Author SHA1 Message Date
Jeff Brown
0cb1cfdcc3 am 76c4c666: Add USB port manager.
* commit '76c4c6668a1486bc003ab0c585bb1f41d16e27a7':
  Add USB port manager.
2015-07-15 22:26:38 +00:00
Jim Miller
c7b0435cc7 resolved conflicts for merge of 1d4247c4 to mnc-dr-dev
Change-Id: I057c529dcd5d48e0dcf256a9d096c5d8b815892a
2015-07-15 14:33:10 -07:00
Jeff Brown
76c4c6668a Add USB port manager.
Add some new internal APIs to enumerate USB Type C ports, query their
status, determine whether they support changing power or data roles,
and doing so.  The API also adds a new ACTION_USB_PORT_CHANGED broadcast
for port state changes.

The implementation includes a mechanism for simulating the behavior
of the USB stack.  See 'adb shell dumpsys usb -h' for details.

Note that the underlying kernel driver interface is still subject
to change but its behavior has been encapsulated as much as possible.

Bug: 21615151
Change-Id: I0c853ae179248a4550b3e60d02a7a7e65e4546b2
2015-07-15 11:34:29 -07:00
Dianne Hackborn
1d4247c4cc Merge "Improve tracking of screen on reasons." into mnc-dev 2015-07-15 17:11:12 +00:00
Dianne Hackborn
280a64e793 Improve tracking of screen on reasons.
- New screen on app op to record the last time each app has
  caused the screen to be turned on.
- New battery stats event that tells us the reason the screen
  has been asked to turn on.
- Propagate out power manager API to specify the reason a caller
  is asking to have the screen turned on.

Note that currently the window flag to turn the screen on bypasses
much of this because it is being handled in the window manager by
just directly telling the power manager to turn the screen on.  To
make this better we need a new API where it can specify who it is
calling the API for.

Change-Id: I667e56cb1f80508d054da004db667efbcc22e971
2015-07-15 09:59:07 -07:00
George Mount
91202e5929 am 503ad9ee: Merge "Fix input pause without resume." into mnc-dev
* commit '503ad9ee0d701d045c382cd534865f48f69c024b':
  Fix input pause without resume.
2015-07-15 14:24:18 +00:00
George Mount
503ad9ee0d Merge "Fix input pause without resume." into mnc-dev 2015-07-15 14:12:28 +00:00
Dianne Hackborn
aa3694f2b3 am f1f8b9cc: Merge "Fix issue #21626564: MMS should be receivied while Dozing" into mnc-dev
* commit 'f1f8b9cc3ff5774e695568e8f02b018c0fd02844':
  Fix issue #21626564: MMS should be receivied while Dozing
2015-07-15 01:57:21 +00:00
Dianne Hackborn
f1f8b9cc3f Merge "Fix issue #21626564: MMS should be receivied while Dozing" into mnc-dev 2015-07-15 01:45:44 +00:00
Fyodor Kupolov
0e45f8737a am 4044440d: Merge "Require ACCESS_COARSE_LOCATION for ACTION_FOUND broadcast" into mnc-dev
* commit '4044440d2c1a9d185a3379b88d88c96f8e234887':
  Require ACCESS_COARSE_LOCATION for ACTION_FOUND broadcast
2015-07-15 01:43:02 +00:00
Fyodor Kupolov
4044440d2c Merge "Require ACCESS_COARSE_LOCATION for ACTION_FOUND broadcast" into mnc-dev 2015-07-15 01:34:43 +00:00
Dianne Hackborn
fd854ee58c Fix issue #21626564: MMS should be receivied while Dozing
We now place whoever is receiving the MMS on the temporary
whitelist while doing so, so they can get network access to
download it.

There was also an issue that needed to be fixed where we
were no longer updating the list of allowed uids while
dozing based on their proc states...  we now do that.

Also did a bit of optimization of the temp white list update
path do the network policy manager, instead of going through
a broadcast we now directly call in to the network policy
manager.  This also allows us to have a synchronous version
of updating the list, so we can know the app has network access
before we tell it to do anything.

Finally added battery stats events for things going on and off
the whitelist so we can diagnose the behavior there.

Change-Id: Ic7fe010af680034d9f8cb014bb135b2addef7455
2015-07-14 18:33:08 -07:00
Fyodor Kupolov
189f313661 am 98724126: Merge "Added sendBroadcastMultiplePermissions method" into mnc-dev
* commit '987241265b77542f45ce95838c25beeaf3ae6849':
  Added sendBroadcastMultiplePermissions method
2015-07-15 01:00:44 +00:00
Fyodor Kupolov
d4fd8c766d Added sendBroadcastMultiplePermissions method
Added Context.sendBroadcastMultiplePermissions(Intent intent, String[]
receiverPermissions) method, which allows an array of required permissions
to be enforced.

Bug: 21852542
Change-Id: I27c9130e8f004b428452501ebc8a36aabde1f343
2015-07-14 17:25:42 -07:00
Yin-Chia Yeh
9d513cec7c am b42cb352: Merge "Camera: clarify largest JPEG dimension expectation" into mnc-dev
* commit 'b42cb352a350bac198470f65125aa151ecacff13':
  Camera: clarify largest JPEG dimension expectation
2015-07-14 23:13:27 +00:00
Fyodor Kupolov
fc4acfd93c am 4a817924: Merge "Revert "Allow array of required permissions in sendBroadcast"" into mnc-dev
* commit '4a817924ecb282eef48b06b92f8e1914edd6cec2':
  Revert "Allow array of required permissions in sendBroadcast"
2015-07-14 23:13:22 +00:00
Yin-Chia Yeh
b42cb352a3 Merge "Camera: clarify largest JPEG dimension expectation" into mnc-dev 2015-07-14 22:53:11 +00:00
Fyodor Kupolov
4a817924ec Merge "Revert "Allow array of required permissions in sendBroadcast"" into mnc-dev 2015-07-14 22:43:47 +00:00
Fyodor Kupolov
e37520b49d Revert "Allow array of required permissions in sendBroadcast"
This reverts commit b4e7283c9a.

Change-Id: Ie8390964bda5bdfa869cee8f46584043d8e7c664
2015-07-14 22:29:21 +00:00
Fyodor Kupolov
ef77c116f3 am d69a82c1: Merge "Allow array of required permissions in sendBroadcast" into mnc-dev
* commit 'd69a82c107cea4aca87eecc3978e21ea9bc23c82':
  Allow array of required permissions in sendBroadcast
2015-07-14 22:12:00 +00:00
Fyodor Kupolov
d69a82c107 Merge "Allow array of required permissions in sendBroadcast" into mnc-dev 2015-07-14 21:57:34 +00:00
Jeff Sharkey
c7a607496a am d3719ab0: Merge "Better handling of storage paths." into mnc-dev
* commit 'd3719ab07a0ba66c019979ce19c45b77c4aae92e':
  Better handling of storage paths.
2015-07-14 21:18:26 +00:00
Chien-Yu Chen
951e2633eb am 6eec00ec: Merge "Camera: Reconnect after camera service crashes" into mnc-dev
* commit '6eec00ecf456b8a24487828b6f515cccc465cc1a':
  Camera: Reconnect after camera service crashes
2015-07-14 21:18:22 +00:00
Jorim Jaggi
4cfdcf5b05 Touch, wake and unlock
- Add onFingerprintAcquired, so Keyguard can grab a wakelock to prevent
the device from sleeping.
- If we get a successful fingerprint, wake the device up, immediately
dismiss the keyguard and tell PWM that we kicked off our frame that
will represent the correct state.
- PWM then waits for this frame to be drawn, and then turns on the
screen, which results in unlocking directly to the previsouly
opened app.

Bug: 21855614
Change-Id: I0c43bcc9d334b509632704fb0c123ab3351edff2
2015-07-14 21:05:26 +00:00
Jeff Sharkey
d3719ab07a Merge "Better handling of storage paths." into mnc-dev 2015-07-14 20:53:16 +00:00
Chien-Yu Chen
6eec00ecf4 Merge "Camera: Reconnect after camera service crashes" into mnc-dev 2015-07-14 20:48:56 +00:00
Andrew Solovay
90adb81b6c am 353886b2: am e67416ec: am 4859a612: Merge "docs: Clarified how to find out when a switch is toggled" into mnc-preview-docs
* commit '353886b2dd1d6751d83469ddd3eb01dd0039231e':
  docs: Clarified how to find out when a switch is toggled
2015-07-14 20:30:31 +00:00
Andrew Solovay
353886b2dd am e67416ec: am 4859a612: Merge "docs: Clarified how to find out when a switch is toggled" into mnc-preview-docs
* commit 'e67416eccc6092e2fce3619b2244deda36fabd26':
  docs: Clarified how to find out when a switch is toggled
2015-07-14 20:22:59 +00:00
Jeff Sharkey
983294596e Better handling of storage paths.
Give more details about why we failed to create storage paths, and
search for underlying volumes using canonical paths.

Bug: 22135060
Change-Id: I75d3584403ece310438b05f5b9fe72d94c9096c6
2015-07-14 13:08:22 -07:00
Andrew Solovay
e67416eccc am 4859a612: Merge "docs: Clarified how to find out when a switch is toggled" into mnc-preview-docs
* commit '4859a6125bcf967cf97339b19f30d9788b971e02':
  docs: Clarified how to find out when a switch is toggled
2015-07-14 20:08:00 +00:00
Fyodor Kupolov
b4e7283c9a Allow array of required permissions in sendBroadcast
Added Context.sendBroadcast(Intent intent, String[] receiverPermissions)
method, which allows an array of required permissions to be enforced.

Bug: 21852542
Change-Id: I3b8ff258fa9f3249c344bb8093b820b24eef00c0
2015-07-14 12:50:22 -07:00
Adrian Roos
9c013a2117 Merge "Show charging speed on Keyguard" into mnc-dr-dev 2015-07-14 19:17:07 +00:00
Fyodor Kupolov
72f491dd86 Require ACCESS_COARSE_LOCATION for ACTION_FOUND broadcast
Receivers of ACTION_FOUND intent are now required to have
ACCESS_COARSE_LOCATION permission.

Bug: 21852542
Change-Id: I8306f7431f067ca36bfc568a912385153fa3d496
2015-07-14 11:38:58 -07:00
Adrian Roos
7b04311d88 Show charging speed on Keyguard
Bug: 8099739
Change-Id: I2e5c21dd7ec028ce47fb03ab71e74f7fccaa9e36
2015-07-14 18:22:39 +00:00
Marco Nelissen
c56668eb22 am 3ced9617: Merge "Use original path if translated path doesn\'t exist" into mnc-dev
* commit '3ced96178b1b132705e773736cbb707a3a0cd951':
  Use original path if translated path doesn't exist
2015-07-14 17:36:07 +00:00
Craig Lafayette
d86ab3c539 am 2f0116fa: Merge "Prevent null allowableAccounts from crashing" into mnc-dev
* commit '2f0116fa3ab2153188e43e87b194afae7e4efb81':
  Prevent null allowableAccounts from crashing
2015-07-14 17:36:02 +00:00
Marco Nelissen
3ced96178b Merge "Use original path if translated path doesn't exist" into mnc-dev 2015-07-14 17:30:06 +00:00
George Mount
80141d1c8b Fix input pause without resume.
Bug 22455206

Previously, when an exit activity transition was created, the input
would be paused. This worked fine as long as the transition was
run. However, sometimes that transition wasn't run and this would
cause the input to fail to be started again.

This fix moves the input pause to when the transition is started.

Change-Id: I738d5471f7932f00b50897f87a8f8a71ecbc57e2
2015-07-14 10:03:06 -07:00
Marco Nelissen
aa41103668 Use original path if translated path doesn't exist
Bug: 22376538
Change-Id: I2f6af4fa31c097e2e2d619a068cf83721091c450
2015-07-14 08:25:23 -07:00
Craig Lafayette
3c9c71d36e Prevent null allowableAccounts from crashing
The javadoc for newChooseAccountIntent says that a null
value for the allowableAccounts parameter is valid and
an acceptable default. This CL makes sure that when this
parameter is null, a NullPointerException is not thrown.

Bug: 22475546
Change-Id: Ieb0d67dd02628e1ae5629499b3be3c6382efc9aa
2015-07-14 11:09:58 -04:00
Andrei Stingaceanu
a7e2ab6ec6 am 8af7432c: Merge "Fix "Select All" in extracted mode" into mnc-dev
* commit '8af7432ca3fc1ce3539997d24439954f0e64134c':
  Fix "Select All" in extracted mode
2015-07-14 14:17:48 +00:00
Andrei Stingaceanu
5396c131c0 Fix "Select All" in extracted mode
Stop calling onExtractTextContextMenuItem if "Select All"
is selected (the action does not modify text thus does
not need batch editing). Editor#finishBatchEdit reports
that text changed which in turn can stop the action mode
and the selection after it was started by onPreDraw.

Bug: 22059417
Change-Id: I5354cbe4bae374e0d5f3de39616336170ee33b92
2015-07-14 11:37:28 +01:00
Andrei Stingaceanu
0e6360f454 am a9b9907f: Merge "Fix insertion handle disappearing in extract mode" into mnc-dev
* commit 'a9b9907f3c472e70d0950964d3e2c83c4926af14':
  Fix insertion handle disappearing in extract mode
2015-07-14 10:14:22 +00:00
Andrei Stingaceanu
a9b9907f3c Merge "Fix insertion handle disappearing in extract mode" into mnc-dev 2015-07-14 09:57:24 +00:00
Erik Kline
68bc390c0a am 77612940: Merge "Log NetworkRequestInfo to get more detailed history" into mnc-dev
* commit '776129402746be08d52bb9f0901f6ecd63b25399':
  Log NetworkRequestInfo to get more detailed history
2015-07-14 06:07:04 +00:00
Zach Johnson
19ab3b47cb am 569ff225: Fix BluetoothSocket file descriptor leak
* commit '569ff225a3879363bb31548a664161fee5270a0d':
  Fix BluetoothSocket file descriptor leak
2015-07-14 06:07:00 +00:00
Ian Pedowitz
d7be214ca4 resolved conflicts for merge of 8cee6587 to mnc-dr-dev
Change-Id: I0b2ed52214bb097d7fd69434afd0c6c890b5afb3
2015-07-13 22:58:29 -07:00
Erik Kline
7761294027 Merge "Log NetworkRequestInfo to get more detailed history" into mnc-dev 2015-07-14 04:09:29 +00:00
Zach Johnson
569ff225a3 Fix BluetoothSocket file descriptor leak
Sockets accepted on a server socket didn't populate
the mPfd field, which is used to close out the java
end of the native-and-java communication socket when
the overall rfcomm socket is closed. #badnewsbears

b/21398841

Change-Id: I3adb0a9965f83d0f3006fa4f79ea4abeab5c9a17
2015-07-14 03:40:49 +00:00
Erik Kline
7523eb349e Log NetworkRequestInfo to get more detailed history
Bug: 21641983
Bug: 22235775
Bug: 22299819
Bug: 22358164
Change-Id: I48a2d162dd499a3590f06d805267a63822856969
2015-07-14 11:46:51 +09:00