13878 Commits

Author SHA1 Message Date
Dongwon Kang
ab064b3b36 Merge "Add a way for SystemUI to receive media resource (e.g. A/V codec) usage" 2016-01-13 18:21:00 +00:00
Dongwon Kang
2034a4c4c5 Add a way for SystemUI to receive media resource (e.g. A/V codec) usage
Bug: 26175834
Change-Id: If506a533c5c7b567e770217a9430bf68b539677a
2016-01-12 10:54:34 -08:00
Jeff Sharkey
4175be2f4e Triage SearchManagerService for missing apps.
Searchables aren't available until after the user is unlocked.  We
could scan for them while locked, but we're aiming for a minimalist
environment, and scanning them while locked would require us to send
a changed broadcast on every boot.

Switch to using new SystemService lifecycle for faster event
delivery.  Restore broken global search observer.  Verified that
apps on external storage are handled correctly.

Bug: 26471205
Change-Id: Id99ffe2ea6db37a394454cc7dfa4eab10280ff35
2016-01-09 14:57:47 -07:00
Jeff Sharkey
2f3e35376a More work towards triaging missing app behavior.
Many places across the platform query package details without
gracefully handling packages or components that go missing for
various reasons.  This can cause annoying user data loss, such as
resetting back to built-in apps or dropping of accounts, etc.

This change verifies that system callers have thought about these
edge cases by logging if they use default matching behaviors without
explicitly marking themselves as being "triaged."  (The logging is
currently disabled by default.)

Also creates explicit definitions of supported flags for various
incoming PackageManager calls, and defines a clear distinction
between flag types:

-- GET-style flags are used to request additional data that may have
been elided to save wire space.

-- MATCH-style flags are used to include components or packages that
would have otherwise been omitted from a result set by current system
state.

There are a handful of existing GET flags that better fit under the
MATCH definition, so this change clones them to new constants and
marks the old ones as deprecated.

Fixes bug in JobSchedulerService to consider jobs from apps on
external storage.  Revert some dialer behavior back to being
untriaged.

Change-Id: I9b6ab0968241e3479bddbd78de0c51e3b9917318
2016-01-04 13:19:02 -07:00
Jeff Sharkey
2a9e3f8e68 Better named encryption flags, start triaging.
Create distinct flags for encryption aware, unaware, and both, and
name them like the other MATCH_ flags.

Start adding logic to help triage all system internal callers to
verify that they've done their homework and thought about how to
handle apps while locked.  Call sites in the system should either
ask for explicit matching behavior, or explicitly use the DEFAULT
match flag to indicate that they've been triaged to use the
default state-based matching.

Bug: 26250295
Change-Id: I86214e5c4f71a6dc72f06930800388713aecd107
2015-12-19 15:00:09 -07:00
Ruben Brunk
dd18a0b695 Add a framework service tracking VR mode state.
- Implement a "VR mode" that may be enabled by a focused Activity.
- Add a system service that tracks the current VR mode state and notifies
  other core framework services of mode changes.
- Extend NotificationListenerService to allow the bind/unbind lifecycle
  of specified listeners to be triggered by system events.

Bug: 22855417
Bug: 25479708

Change-Id: I1ac8692bbb5521bb6c7cfb9d2b56b98b720f8568
2015-12-17 10:09:17 -08:00
Alan Viverette
ba398eaafe Remove DayNight themes from public API (again)
Bug: 22628106
Change-Id: Id55c9e626813c70671a93aedf8b1e0cdaed45ec1
2015-12-16 15:28:23 -05:00
Gustav Sennton
6258dcd7ea Add functionality for changing WebView provider.
Make it possible to change WebView provider (through a Developer
setting) and kill all apps using the old provider.
This includes checking the signatures of the WebView providers to make
sure they are valid.

Now that we can change WebView provider through a setting it is possible
to change provider while some provider is being updated. Because of this
we now keep track of which provider should be in use in
WebViewUpdateService to make sure we use the correct provider at all
times.

We now also read WebView package meta data (name, package name, and
signature) from a separate xml file.

Main bug: crbug.com/546185

Bug: 25338573

Change-Id: I660fd1a40a5388f6569a06a7f0d029e8ff65945a
2015-12-11 14:29:44 +00:00
Nicolas Geoffray
27c0737969 Remove performBootDexOpt and am's ensurePackageDexOpt.
Except common shared libraries and boot image, all compilations
are now done through BackgroundDexOptService.

Change-Id: Ib736e253c38b0c8085bc94e45f4e61a048f66e26
2015-11-11 12:19:08 +00:00
Makoto Onuki
e1aef85ff1 Use the SystemService lifecycle mechanism for AudioService
This will be needed to refactor user restriction handling.

Change-Id: I4b77a020d631714e7f94bce5559190e3b78ec72c
2015-10-15 17:28:35 -07:00
Bryce Lee
535570a7ce am 979a22ea: am 6ad696c3: am f0740e0a: Merge "Add ThermalObserver system service to capture thermal state uevents." into cw-e-dev
* commit '979a22eaf9c62637c02ebd6f92ef6ea2888aa5be':
  Add ThermalObserver system service to capture thermal state uevents.
2015-09-27 15:11:22 +00:00
Bryce Lee
979a22eaf9 am 6ad696c3: am f0740e0a: Merge "Add ThermalObserver system service to capture thermal state uevents." into cw-e-dev
* commit '6ad696c35b80f70f19de304b53bdbfc6f5a265d8':
  Add ThermalObserver system service to capture thermal state uevents.
2015-09-26 06:55:22 +00:00
Bryce Lee
bc58f59da6 Add ThermalObserver system service to capture thermal state uevents.
Bug: 21445745
Change-Id: I980d60b66ca51942a1fd62502d6cf1f09208fc3a
2015-09-25 16:43:01 -07:00
Alex Hills
03f46af3e1 am d04c6d19: resolved conflicts for 693e11e5 to mnc-dr-dev-plus-aosp
* commit 'd04c6d19a589a2a0f60650675438c59ac6900f45':
  Cherry-pick system theme rebase to fix square UI on round watches
2015-09-14 21:24:53 +00:00
Alex Hills
d04c6d19a5 resolved conflicts for 693e11e5 to mnc-dr-dev-plus-aosp
Change-Id: I701841759a80f434a09b086492e817ca23a6a2e6
2015-09-14 17:03:58 -04:00
Alan Viverette
3d2337eeb5 Cherry-pick system theme rebase to fix square UI on round watches
Our system themes were based on configurations that were added post-
init of the system theme.

I96e695441543379e4d5fdf3cc6f18d9e6cf953b4 broke this, because there
was a race condition in the code for rebasing themes

If8fecde76d62738a8e55eddf898eafc468afdba2 (the cherry-picked commit)
fixes the race condition and adds the rebasing back in.

This change cherry picks If8fecde76d62738a8e55eddf898eafc468afdba2.

Bug:23387146
Change-Id: I0725028e48599fc6cd9731ae16c71474dd5827e5
2015-09-14 10:56:02 -04:00
Yasuhiro Matsuda
6d444185e5 resolved conflicts for merge of fcf9ab5a to master
Change-Id: I69ad6e525430c5c4fc3c274b8bf6ebf653716124
2015-09-03 00:12:30 +09:00
Yasuhiro Matsuda
fcf9ab5ab3 am ebf9465d: resolved conflicts for merge of ef57e5e0 to stage-aosp-master
* commit 'ebf9465d213336819b15e3b21d02afce64470d4f':
  Add trace code to system server.
2015-09-02 14:31:26 +00:00
Yasuhiro Matsuda
ebf9465d21 resolved conflicts for merge of ef57e5e0 to stage-aosp-master
Change-Id: I1c31b38936dc74619dea27f0d5eecab43360bb8c
2015-09-02 22:57:53 +09:00
Yasuhiro Matsuda
1ab43d5978 Add trace code to system server.
- Add TRACE_TAG_SYSTEM_SERVER for tracing system server code.
- Add a few more tracing code to the code paths related to boot.

BUG: 21739901
BUG: 22207144
Change-Id: I08b424d2f83783f512c3818394099909cd55f327
2015-08-27 12:22:07 +09:00
Seigo Nonaka
7309b123c4 Leverage WindowManagerInternal for private communication.
This CL changes following four methods from direct calling of
WindowManagerService to calling via WindowManagerInternal.
- getInputMethodWindowVisibleHeight
  (introduced by I0e920ee79c526c3aea6872b063cf294e2ab081c8)
- saveLastInputMethodWindowForTransition
  (introduced by Idf7700271cf882dfbf35c9d16f0f173a791221bc)
- isHardKeyboardAvailable
  (introduced by I8a6a4a7efce50bfaec114117e33f97f27b1ef950)
- setOnHardKeyboardStatusChangeListener
  (introduced by Ica768083f95c33dc1e494a28ba7d8b6eb989b0ef)

This CL does mechanical code moving and does not change any behaviors.

Bug: 22285167
Change-Id: I08e506050a0e495d62236b46e487848c967d185d
2015-08-25 13:29:04 -07:00
Alan Viverette
02e8c2d418 Merge "Rebase system theme on configuration change" 2015-08-13 20:06:18 +00:00
Narayan Kamath
ae61c26534 am 0d2e3d3e: am c42acbdb: am 088c4155: am 86b6d204: am bf88205b: Fall back to persist.sys.language/country if locale isn\'t set.
* commit '0d2e3d3ea3cd1bd0f77b3fdd8da6b17261cdd799':
  Fall back to persist.sys.language/country if locale isn't set.
2015-08-12 11:02:48 +00:00
Narayan Kamath
0d2e3d3ea3 am c42acbdb: am 088c4155: am 86b6d204: am bf88205b: Fall back to persist.sys.language/country if locale isn\'t set.
* commit 'c42acbdb65d89b1e5fc1cafde4cbe0996c104f7a':
  Fall back to persist.sys.language/country if locale isn't set.
2015-08-12 10:55:33 +00:00
Narayan Kamath
d29382aaf0 am bf88205b: Fall back to persist.sys.language/country if locale isn\'t set.
* commit 'bf88205bef88f78ade5c6830e6203aa343387820':
  Fall back to persist.sys.language/country if locale isn't set.
2015-08-12 10:39:16 +00:00
Narayan Kamath
86b6d204a5 am bf88205b: Fall back to persist.sys.language/country if locale isn\'t set.
* commit 'bf88205bef88f78ade5c6830e6203aa343387820':
  Fall back to persist.sys.language/country if locale isn't set.
2015-08-12 10:39:13 +00:00
Narayan Kamath
bf88205bef Fall back to persist.sys.language/country if locale isn't set.
This will prevent users from losing their language setting when they
take an OTA to M.

bug: 23021286
Change-Id: Ifb66f6bf6a940ab745edac709321f3009ec6eab4
2015-08-12 11:03:46 +01:00
Alan Viverette
395cd017e6 Rebase system theme on configuration change
Also makes native theme accesses thread-safe to avoid a race condition
when modifying the theme off the UI thread. Since drawable loading can
occur off the UI thread, we need to ensure Theme access is thread-safe
anyway.

This reverts commit c12ec70def2a5682c6cd7fdb3adaa82cc34d5bf6.

Change-Id: If8fecde76d62738a8e55eddf898eafc468afdba2
2015-08-11 17:27:04 -04:00
Alan Viverette
7bea76cecf am 3e384531: am 1743988c: am 6c3a468c: am e720297f: am b4eb0640: Merge "Avoid use-after-free race condition when rebasing theme" into mnc-dev
* commit '3e384531bed8f80867ce1bab9c8de315865be824':
  Avoid use-after-free race condition when rebasing theme
2015-08-11 18:59:42 +00:00
Alan Viverette
3e384531be am 1743988c: am 6c3a468c: am e720297f: am b4eb0640: Merge "Avoid use-after-free race condition when rebasing theme" into mnc-dev
* commit '1743988cd7647af8c64c961d4ca5e9d4b4b7bc00':
  Avoid use-after-free race condition when rebasing theme
2015-08-11 18:53:13 +00:00
Alan Viverette
3288e63250 am b4eb0640: Merge "Avoid use-after-free race condition when rebasing theme" into mnc-dev
* commit 'b4eb06402fba62f94bb16cbe433fe99a8df7cb18':
  Avoid use-after-free race condition when rebasing theme
2015-08-11 18:32:05 +00:00
Alan Viverette
e720297fd8 am b4eb0640: Merge "Avoid use-after-free race condition when rebasing theme" into mnc-dev
* commit 'b4eb06402fba62f94bb16cbe433fe99a8df7cb18':
  Avoid use-after-free race condition when rebasing theme
2015-08-11 18:31:48 +00:00
Alan Viverette
c12ec70def Avoid use-after-free race condition when rebasing theme
... by never rebasing the theme. We don't need to do this unless the
system theme is configuration-dependent, which it is not currently.

Bug: 22943781
Change-Id: I96e695441543379e4d5fdf3cc6f18d9e6cf953b4
2015-08-11 10:26:08 -04:00
Zhentao Sun
ea6e001e31 am 6f52ee25: am e965289b: am f26a9a20: am c6cd1f9a: Added service that listens for gestures.
* commit '6f52ee259201c320fe69004623efd1748874f628':
  Added service that listens for gestures.
2015-07-23 22:08:05 +00:00
Zhentao Sun
6f52ee2592 am e965289b: am f26a9a20: am c6cd1f9a: Added service that listens for gestures.
* commit 'e965289b57eb1782580bc5a6bc153d508b7176be':
  Added service that listens for gestures.
2015-07-23 21:50:08 +00:00
Zhentao Sun
c6cd1f9a83 Added service that listens for gestures.
Added the GestureLauncherService that listens for camera launch gesture
and starts the camera app.
OEMs need to specify the sensor type of the camera launch gesture in
their overlays.
In the future, we can add more gesture support in this service.

Change-Id: I0769e7ca71e08bd9159aacf29bdcefd316efd2f0
2015-07-22 17:42:41 -07:00
Elliott Hughes
85235aae1c am e72d0d47: am 66c8a2f9: am 0254af6f: Merge "Fix "Bluetooh" logging typo."
* commit 'e72d0d47b8d495f565cfcfb22dc0de2d35103c2e':
  Fix "Bluetooh" logging typo.
2015-07-07 15:53:33 +00:00
Elliott Hughes
0be2ab3b5e am 66c8a2f9: am 0254af6f: Merge "Fix "Bluetooh" logging typo."
* commit '66c8a2f92acedaa05639ceb0737b95be2fd56281':
  Fix "Bluetooh" logging typo.
2015-07-07 15:48:59 +00:00
Elliott Hughes
e72d0d47b8 am 66c8a2f9: am 0254af6f: Merge "Fix "Bluetooh" logging typo."
* commit '66c8a2f92acedaa05639ceb0737b95be2fd56281':
  Fix "Bluetooh" logging typo.
2015-07-07 06:31:40 +00:00
Elliott Hughes
7271613ed6 Fix "Bluetooh" logging typo.
Change-Id: I2b9aea64f1b53e100ead6e71835bf5935b410eb9
2015-07-06 22:10:36 -07:00
Bart Sears
86b81e9137 resolved conflicts for merge of d1e2789b to master
Change-Id: Ibfbae4ec1d692854a13eaa09deac3134c3524126
2015-07-04 00:15:01 -07:00
Miao Chou
658bf2fa6d Add BluetoothService to reduce resuming time after reboot
As a subclass of SystemService, BluetoothService wraps around
BluetoothManagerService to unlock Auto-enabling Bluetooth earlier by overriding
onBootPhase() and removes the need to wait for BOOT_COMPLETED message.

Bug:21705209
Change-Id: I2acc41370a750d8416e11e662e06392326741d2c
2015-07-01 19:09:44 +00:00
Xiaohui Chen
70f6c38644 Introduce system user and primary user.
Bug: 19913735
Change-Id: I2c7855915d778cf80a7154314321ddd90e2eaaac
2015-06-23 15:25:37 -07:00
Alan Viverette
15d48a16f6 DO NOT MERGE: Remove DayNight theme
Do not go gentle into that good night,
Old age should burn and rave at close of day;
Rage, rage against the dying of the light.

Though wise men at their end know dark is right,
Because their words had forked no lightning they
Do not go gentle into that good night.

Bug: 21854466
Change-Id: I0b7cd116c23f7df88e94f31b3aee7dd22a102804
2015-06-18 15:15:16 -07:00
Christopher Tate
2ff4d92774 am 485c2f8c: am 4f4d54f3: am 1c24a8cd: Merge "If we\'re out of space, retry background dexopting later" into mnc-dev
* commit '485c2f8c5715c12bd84a20f9746ce40a1ff15e70':
  If we're out of space, retry background dexopting later
2015-06-12 21:02:07 +00:00
Christopher Tate
2c9655b3d4 If we're out of space, retry background dexopting later
Give it 4 hours to give the user time to do stuff, then retry;
repeat until we have space to work in.

Bug 20468442

Change-Id: Id4b11abcc38a9e2a50a062f0067a13ce0ae831ad
2015-06-12 13:06:45 -07:00
Steve Paik
b8850932d7 Merge "Disable AssetAtlasService when PRELOAD_RESOURCES is turned off" 2015-06-11 15:30:03 +00:00
Steve Paik
3c27a2303f Disable AssetAtlasService when PRELOAD_RESOURCES is turned off
Change-Id: Ie77810219c8d5dbff7e9364b60db2d1ea50bd685
2015-06-10 18:25:44 -07:00
Tim Kilbourn
0935f3ce51 Refactor DropBoxManagerService as a SystemService.
Move the binder stub inside the service and inherit from SystemService
to take advantage of SystemServiceManager.

Change-Id: Ic6fff50ccfcf6c9626ffca8d61f627c055608953
2015-06-04 09:57:38 -07:00
Alan Viverette
e54d245b99 Improve keying for theme caches, rebase system theme on config change
Themes now use an array of applied styles rather than a String to store
their history. They are keyed based on a hash code computed from the
history of applied styles. The themed drawable cache has been abstracted
out into its own class.

Also updates system context to use DayNight as the default and ensures
that GlobalActions uses the correct context, which exercises the change.

CTS tests have been added in another CL.

Bug: 20421157
Change-Id: I9eb4b7dffd198ad24d02f656eaf0839570b59caa
2015-05-06 10:41:43 -07:00