1156 Commits

Author SHA1 Message Date
Christoph Studer
cee44ba418 Simplify NotificationListenerService API
Use ParceledListSlice to send the list of active notifications
from NoMan to NotificationListeners.

This allows us to simplify the API to what it was before
introducing the "String[] key" workaround for dealing with large
numbers of StatusBarNotifications.

While we're at it, rename Ranking.getIndexOfKey to something that
makes more sense.

Bug: 15126927
Change-Id: I02c2087978c6c4ec1198be496c6250a66143ecb3
2014-05-21 22:03:45 +02:00
RoboErik
5b53148a4e Merge changes I1cbdff1d,I23906b4c
* changes:
  Handle headsethook voice launching
  Add 5s timeout to wakelock
2014-05-21 19:59:11 +00:00
justinzhang
7bd35c7e6f Use DeviecPolicyManager to authenticate lock task
Uncomment lines in ActivityManagerService. Before start lock task,
ActivityMangerService calls DevicePolicyManager to see if the
app can go into lock task.

Change-Id: I9ad784d7cc637d45884dcb2623b4c59ff802f93d
2014-05-21 15:28:08 -04:00
Yohei Yukawa
eac222a002 Merge "Update InputMethodSubtypeSwitchingController correctly" 2014-05-21 14:03:34 +00:00
Adrian Roos
efb5d8d317 Merge "Add dumpsys facility and a history to TrustManagerService" 2014-05-21 13:44:07 +00:00
Yohei Yukawa
c834a2590c Update InputMethodSubtypeSwitchingController correctly
User visible behavior is supposed to be identical with and
without this CL.

Previously, there is some corner cases where
InputMethodSubtypeSwitchingController#resetCircularListLocked is
not called but the list of enabled input method is updated.

Fortunately, this corner cases are not observable for a user
because we have not updated the the rotation order dynamically.

However we should fix this before implementing smarter rotation
algorithm that changes the rotation order dynamically.

BUG: 7043015
Change-Id: I145a514dc4cde369ba50431c408c916046ab0c6e
2014-05-21 22:42:32 +09:00
Dan Sandler
b979f23c59 Elide extras strings from noman dumpsys output.
Bug: 14292528
Change-Id: I19cfb6b692e6901fa7f115ea675b1b03fc5ba176
2014-05-21 13:36:41 +00:00
Chris Wren
5daa4598e2 Merge "add ranking information to the dumpsys info" 2014-05-21 12:36:06 +00:00
Jeff Brown
4bfcae9a3f am 77669abb: am 9beccf9f: Merge "Defer display ready until brightness ramp completes." into klp-modular-dev
* commit '77669abb8300b672700418216939b9253dc98bee':
  Defer display ready until brightness ramp completes.
2014-05-21 11:16:52 +00:00
Narayan Kamath
d862ebb603 resolved conflicts for merge of fcc4fed3 to master
Change-Id: Icebca982b01debd67a1470c02651ef8936f6e5b0
2014-05-21 12:07:35 +01:00
Sander Alewijnse
3856204c0e Merge "Disallow adb sideloading if UserManager flag is set for user." 2014-05-21 09:19:08 +00:00
Sander Alewijnse
1c91077bf7 Disallow adb sideloading if UserManager flag is set for user.
Solution is based on "redefining" the User_all.

Change-Id: Ie1ce5d6391e807f8caa05fe2a92009923d1032a8
2014-05-21 10:12:33 +01:00
Jeff Brown
77669abb83 am 9beccf9f: Merge "Defer display ready until brightness ramp completes." into klp-modular-dev
* commit '9beccf9f9e28f74bd78041e4381b59ce0a2351e7':
  Defer display ready until brightness ramp completes.
2014-05-21 08:40:36 +00:00
Jeff Brown
fcc4fed3c1 am 6fb904bf: Merge "Make power button behavior configurable." into klp-modular-dev
* commit '6fb904bfd1f943547d6e5bc6f199ffec2290da01':
  Make power button behavior configurable.
2014-05-21 08:40:33 +00:00
Brian Carlstrom
1d26571695 am e77a77d0: am ec71fed0: Merge "Improve ABI handling for shared user ids."
* commit 'e77a77d081ff9d05100702f5880f356da27fd087':
  Improve ABI handling for shared user ids.
2014-05-21 08:27:03 +00:00
Jungshik Jang
e1a2e26a03 Merge "Add several actions for ARC (Audio Return Channel)" 2014-05-21 06:43:09 +00:00
Jungshik Jang
2f51aec689 Fix NullPointerException on init of HdmiMhlController.
Change-Id: I2f79ce0ef3a368c2fcc8d047de2dcad914679e0c
2014-05-21 06:42:07 +00:00
Jungshik Jang
67ea521d14 Add several actions for ARC (Audio Return Channel)
ARC channel is established by both TV and AV Reciever.
From TV, it sends <Request ARC Initiation> and AVR
responds with <Initiate ARC>.
From AVR, it can be initiated by sending <Initiate ARC> directly
to TV.
Once TV receives <Initiate ARC> it sets up ARC internally
and replies <Report ARC Initiated> to AVR.
Termination steps are almost same except for message name
(use Terminate instread of Initiation).

In order to implement the above steps, this change introduces
following classes.

RequestArcInitiation(Termination)Action:
  handles <Request ARC Initiation> (<Request ARC Termination>)
  RequestArcAction handles common logic of them.

SetArcTransmissionStateAction:
  handles ARC set up, enabling/disabling ARC and
  reports results to AVR.

<Initiate ARC> and <Terminate ARC> handles directly in
HdmiControlService

Along with this, this change has implmentation for
add&removeAction. To avoid synchronization issue
they are isolated to main thread.

Change-Id: I3c5cf7c777e6c1de50d63ce4643b191dfe15fe1f
2014-05-21 14:52:50 +09:00
Narayan Kamath
96db91e0ff Improve ABI handling for shared user ids.
The key improvement is that we need to keep track of
the package that's currently being scanned (this includes
new installs and upgrades of existing packages) and treat
it specially. If we didn't do that, In the case of upgrades
we would perform the shared UID calculation based on the ABI
of the old package, and not the current package.

This change also allows us to perform the CPU ABI calculation
before dexopt, which saves us from having to do it twice and
fixes a bug where we were using the wrong package path to
dexopt a package.

This also has the side effect of fixing 15081286.

bug: 15081286

(cherry-picked from commit b851c89d2252cf3d1dc504558ce1553527885316)

Change-Id: I20f8ad36941fc3df29007f0e83ce82f38f3585c8
2014-05-20 22:10:24 -07:00
Jeff Brown
4255869ac0 Defer display ready until brightness ramp completes.
Bug: 14494096
Change-Id: I6da6fffbbce2c7058170e5c6139eae4cb5a06d88
2014-05-20 22:02:46 -07:00
Jeff Brown
6d8fd27e51 Make power button behavior configurable.
Allow power button to be used to either go to sleep as usual,
which may doze, or skip that completely and really go to sleep.
May also really go to sleep and go home all at once.

Bug: 14406056
Change-Id: Ia19e2551b9c2a72271bb2eddd5c0d1749761e019
2014-05-20 21:24:38 -07:00
Jeff Brown
7a32533c62 am ccf51bef: am 2d9b513d: Merge "I\'m feeling the good vibrations." into klp-modular-dev
* commit 'ccf51bef288652cb618a566a376173e252b84af0':
  I'm feeling the good vibrations.
2014-05-21 02:41:06 +00:00
Jeff Brown
df3bad37d2 am 8f120dd6: am 0702786d: Merge "Allow display timeouts to be set in config.xml." into klp-modular-dev
* commit '8f120dd6d631ac632d3356b81403a53f958021f0':
  Allow display timeouts to be set in config.xml.
2014-05-21 02:41:00 +00:00
Jeff Brown
ccf51bef28 am 2d9b513d: Merge "I\'m feeling the good vibrations." into klp-modular-dev
* commit '2d9b513dab78242281bca125b4abc6b8235089a6':
  I'm feeling the good vibrations.
2014-05-21 02:38:11 +00:00
Jeff Brown
8f120dd6d6 am 0702786d: Merge "Allow display timeouts to be set in config.xml." into klp-modular-dev
* commit '0702786d81eb9f9bf47c3a0827d3f2824c3f4228':
  Allow display timeouts to be set in config.xml.
2014-05-21 02:38:07 +00:00
Jeff Brown
969579bb9d I'm feeling the good vibrations.
When the device enters a non-interactive state, we normally
cancel all active vibrations as a safety precaution.  However if
the system is performing haptic feedback then we want to allow
it to run to completion.

Bug: 14319563
Change-Id: I673781bbf32562e45c1595689e6b423bd178ea73
2014-05-20 19:29:29 -07:00
Jeff Brown
27736f5c0a Allow display timeouts to be set in config.xml.
Bug: 13671523
Change-Id: I79fc21999bc62743178d2d22071455a0c11070c9
2014-05-20 17:17:10 -07:00
Lorenzo Colitti
00592c2700 Merge "Move IP config from WifiConfiguration to IpConfiguration." 2014-05-20 23:15:50 +00:00
Yuncheol Heo
cd47ecb690 Merge "Fix the wrong conversion of byte to int." 2014-05-20 22:53:13 +00:00
Jaewan Kim
6346155c5a Move IP config from WifiConfiguration to IpConfiguration.
This is so that Ethernet can use it in the future.

Bug: 7606609
Bug: 8687763

Change-Id: I5d1189682b13f1088848809604690648d8d9ecca
2014-05-20 15:24:10 -07:00
Amith Yamasani
863ddcc7ac Merge "Per-user telephony restrictions" 2014-05-20 22:20:06 +00:00
Amith Yamasani
9f6c25f57e Per-user telephony restrictions
Allow profile owners or administrators of restricted profiles
to restrict access to telephony features such as calling and
texting for a user.

Change-Id: I89f97608c07c647ad8a7b43fef9d1e6bc4a84e95
2014-05-20 15:13:28 -07:00
RoboErik
9a9d0b5f6f Handle headsethook voice launching
This launches voice search when headsethook is long pressed unless
you're in a call. The handling is done in MediaSessionService. This
CL also adds a switch to the new APIs to the fallback event handler
which was missed previously.

Change-Id: I1cbdff1d6e9f5293885dd8aaed8ba13cb15b36d4
2014-05-20 14:57:46 -07:00
RoboErik
418c10ca9d Add 5s timeout to wakelock
Also filed a b/15110168 to anr the app if it doesn't finish with the
button event in 5s.

Change-Id: I23906b4c7f17d3d3a29eef92b523d8653c87017e
2014-05-20 14:57:46 -07:00
Eric Laurent
c0e439f1b7 Merge "AudioSystem: add new audio device definitions" 2014-05-20 21:39:23 +00:00
Winson Chung
53dd1f7ffc Merge "Fixing transition to/from Recents with full screen apps." 2014-05-20 21:36:28 +00:00
Winson Chung
ae08441649 Fixing transition to/from Recents with full screen apps.
Change-Id: I2f400b6736581a37d38a75ee7194fc7cb6438460
2014-05-20 14:20:11 -07:00
Chris Wren
d1dd027755 add ranking information to the dumpsys info
Change-Id: Ie08186066821a10feef010fd7967150b5517cd54
2014-05-20 17:10:31 -04:00
Dianne Hackborn
3bf2723193 Merge "Delay the dispatching of non-wakeup alarms." 2014-05-20 20:25:08 +00:00
Dianne Hackborn
d4e6d467cd Delay the dispatching of non-wakeup alarms.
When the screen is off, there are no guarantees about when
non-wakeup alarms will be dispatched.  Historically they are
dispatched any time the device wakes up.  With this change,
we will delay the dispatch until sometime later.

The amount of delay is determined by how long the screen has
been off.  Currently there are three possible delays: up to
2 minutes if the screen has been off for less than 5 minutes;
up to 15 minutes if it has been off for less than 30 minutes;
and otherwise up to an hour.

When the screen is turned on or a wakeup alarm is dispatched,
all delayed alarms will also be dispatched.

Note that one of the things this delays is TIME_TICK, which
means the in many cases we won't deliver TIME_TICK until the
screen is in the process of waking up.  The current
implementation causes this to be delayed until the SCREEN_ON
broadcast is sent; we probably want to improve this to have
the power manager tell the alarm manager about the screen
turning on before it sends that broadcast, to help make sure
things like the lock screen can update their current time
before the screen is actually turned on.

In addition, switch all of the alarm stats to use the new
PendingIntent "tag" identifier for its operations, instead
of the old code to try to construct a pseudo-identifier
by retrieving the raw Intent.

Also add a new package manager command to immediately write
packages.xml.

Change-Id: Id4b14757cccff9cb2c6b36de994de38163abf615
2014-05-20 13:24:25 -07:00
Robert Greenwalt
a67be03f9e Add NetworkFactory names and unregistration.
Some Factories come and go (Telephony) and so they need to be able to unregister.
Also, debugging is tough when the factories are anonymous, so add names for logging.

Lastly, only send single set of NetworkRequests to a newly registered NetworkFactory
and only send the requests.

Change-Id: I717d63363f25c446f8ecf38d933b1a35d744af6e
2014-05-20 09:03:57 -07:00
Christoph Studer
05ad48206a Add ZEN and speedbump to NotificationListenerService
Change-Id: I39fae5d77863e0d10cf236a096cc589167d146d3
2014-05-20 17:03:22 +02:00
Adrian Roos
7a4f3d448b Add dumpsys facility and a history to TrustManagerService
TrustManagerService now keeps track of all events that
influence its state and reports them when it is dumped or
a bugreport is collected.

Bug: 15079129

Change-Id: Iac13de8a848d2b12c8d06168a6969f55b264144a
2014-05-20 16:46:36 +02:00
Jason Monk
87be9ba1ea Merge "Fix reference to ProxyInfo extra" 2014-05-20 12:59:52 +00:00
Yuncheol Heo
03e8a834da Fix the wrong conversion of byte to int.
Because 'byte' type is signed, we need a mask when converting it to 'int' type.

Change-Id: I3a8fcb38c9d108c0280d66301e29144391807401
2014-05-20 19:49:58 +09:00
Eric Laurent
948d32748c AudioSystem: add new audio device definitions
Change-Id: Ib7675bc33771365b2dbb7694c522469317b11457
2014-05-19 18:43:49 -07:00
Amith Yamasani
3fa61b671e Merge "Allow adding a user while still removing other users" 2014-05-20 01:02:59 +00:00
Amith Yamasani
f584f014db Allow adding a user while still removing other users
When at the user limit, removing and adding a user causes a race
condition where the deleted user is still being removed and adding
another one fails.

This change excludes deleted users from the counting to compare
against the limit.

Also fix an ArrayIndexOutOfBounds recently introduced in AppOpsService.

Bug: 13282768
Change-Id: Ib79659e7604396583a280dbbc560b288a6d9051c
2014-05-19 17:57:25 -07:00
Jim Miller
fe4e1b655f Merge "Fix infinite loop in TrustManagerService exception handler." 2014-05-20 00:50:05 +00:00
John Spurlock
ce271360da Merge "Dump the countdown condition, if active." 2014-05-20 00:46:09 +00:00