3066 Commits

Author SHA1 Message Date
Adam Powell
95b0c1a723 am 33d0dad1: Merge "android.widget.Toolbar"
* commit '33d0dad1bce329b5794091c31c50543666b3a251':
  android.widget.Toolbar
2014-04-04 17:51:58 +00:00
Adam Powell
e43340c80d android.widget.Toolbar
Add the new Toolbar widget for use in app layouts.

ActionBar can now be used as a point of control for either a
traditional window decor action bar or for a Toolbar that appears
inline in an Activity's layout.

ToolbarActionBar is currently WIP.

Change-Id: I0da093e5645840f4fd032aa34efa0ae5f1825ff2
2014-04-04 10:08:17 -07:00
Paul Lawrence
4a3285de79 am f17f0e0e: Merge "Save OwnerInfo so CryptKeeper can display at boot time"
* commit 'f17f0e0eb0eef424401caa122e51a648f5ef3801':
  Save OwnerInfo so CryptKeeper can display at boot time
2014-04-04 14:12:02 +00:00
Paul Lawrence
f17f0e0eb0 Merge "Save OwnerInfo so CryptKeeper can display at boot time" 2014-04-04 14:05:56 +00:00
Dianne Hackborn
d21310ae0f am 5d5902d1: Merge "Don\'t allow -1 uids for wake locks."
* commit '5d5902d140040936fa6aa7e443220140af0e9843':
  Don't allow -1 uids for wake locks.
2014-04-03 20:56:17 +00:00
Dianne Hackborn
ef640cdfb2 Don't allow -1 uids for wake locks.
Change-Id: Ia1b412a166f69247be3b047138349e7b4031bd7d
2014-04-03 11:20:15 -07:00
Alan Viverette
3a3395042e am b325345e: Merge "Switch framework Holo references to Quantum.Light"
* commit 'b325345ef0adf2849350d339de1ec5f92b67b7ae':
  Switch framework Holo references to Quantum.Light
2014-04-02 22:18:59 +00:00
Alan Viverette
b325345ef0 Merge "Switch framework Holo references to Quantum.Light" 2014-04-02 22:15:16 +00:00
Kenny Guy
501f2c2cf0 am f4824a06: Fix issue with not allowing activities for current user.
* commit 'f4824a06884e096beef921646cba4be29d7f36fc':
  Fix issue with not allowing activities for current user.
2014-04-02 18:28:35 +00:00
Kenny Guy
f4824a0688 Fix issue with not allowing activities for current user.
Change-Id: Ic2e30c3f4990a03aac9801ee9bf5f270a5e90ef8
2014-04-02 19:17:41 +01:00
Paul Lawrence
e51dcf98a4 Save OwnerInfo so CryptKeeper can display at boot time
Requires vold change from
  https://googleplex-android-review.git.corp.google.com/#/c/435164/

Bug: 13526708
Change-Id: I33153df9961832f72c3b8103bd5e1d3a17e77df3
2014-04-02 07:16:05 -07:00
Kenny Guy
ffa80df578 am 1ccace91: Merge "Rename related users to profiles."
* commit '1ccace916c8fdc61f1a8db6677aed518d31647e6':
  Rename related users to profiles.
2014-04-02 13:10:07 +00:00
Kenny Guy
1ccace916c Merge "Rename related users to profiles." 2014-04-02 13:06:28 +00:00
Kenny Guy
2a764949c9 Rename related users to profiles.
Rename the related user concept as profiles.
When returning profiles of a user include the
user as a profile of itself.

Change-Id: Id5d4f29017b7ca6844632ce643f10331ad733e1d
2014-04-02 13:44:50 +01:00
Narayan Kamath
b07178467f am b69bb445: resolved conflicts for merge of 71ab4f4f to master
* commit 'b69bb445585a083b8e4ff8a13a1a1a63e9c22a6a':
  Move zygote startup logic to the frameworks.
2014-04-02 10:59:18 +00:00
Narayan Kamath
b69bb44558 resolved conflicts for merge of 71ab4f4f to master
Change-Id: I888c231f7579523e12fbd68f820f0775019e51e0
2014-04-02 11:52:07 +01:00
Narayan Kamath
71ab4f4f48 am ea9e5eca: am 17b1b8fe: Merge "Move zygote startup logic to the frameworks."
* commit 'ea9e5ecac1e5240370f0e3f998b9c8b159ee9320':
  Move zygote startup logic to the frameworks.
2014-04-02 10:41:24 +00:00
Narayan Kamath
973b4663b0 Move zygote startup logic to the frameworks.
The Zygote class is now in com.android.internal.os. It is
responsible for the vast majority of work before and after
the call to fork(). It calls back into the Runtime via
the new dalvik.system.ZygoteHooks class to allow the Runtime
to perform pre fork cleanup and post fork initialization.

The native code in Zygote.cpp is a direct and straightforward
port of the existing code in art. Most differences are
superficial, for example :
- We use C style logging (ALOGE) instead of stream based
  logging.
- We call env->FatalError() instead of using LOG(FATAL)

Change-Id: Ia101fb2af12d23894fe57e4134d2bc6d142e5059
2014-04-02 10:18:43 +01:00
Alan Viverette
6259933ec9 Switch framework Holo references to Quantum.Light
Change-Id: Ib545a143f1959b6104adbc9d594dd626851d90b3
2014-04-01 14:57:39 -07:00
Paul Lawrence
d2cf756996 am df42723d: Merge "Don\'t double prompt on booting encrypted device"
* commit 'df42723d6b717fd2882c98c930a0f93c75af2474':
  Don't double prompt on booting encrypted device
2014-04-01 15:12:17 +00:00
Paul Lawrence
df42723d6b Merge "Don't double prompt on booting encrypted device" 2014-04-01 15:07:10 +00:00
Fabrice Di Meglio
ade07fd429 am a780d932: Merge "Fix bug #13727850 Input values are not visible when setting up the lockscreen... ...security(PIN/Passwor/Pattern)."
* commit 'a780d9323b3ab9d0a06a9b8569164940d23405d4':
  Fix bug #13727850 Input values are not visible when setting up the lockscreen... ...security(PIN/Passwor/Pattern).
2014-04-01 01:26:01 +00:00
Fabrice Di Meglio
a780d9323b Merge "Fix bug #13727850 Input values are not visible when setting up the lockscreen... ...security(PIN/Passwor/Pattern)." 2014-04-01 01:21:32 +00:00
Fabrice Di Meglio
1cf3594114 Fix bug #13727850 Input values are not visible when setting up the lockscreen...
...security(PIN/Passwor/Pattern).

- remove that hardcoded color
- enable passing a color for the Path lines

Change-Id: Ie40b15bf209f41ea2df16842a3e56ffc2020df65
2014-03-31 16:50:29 -07:00
Adrian Roos
e6978cda71 am 53ab5174: Merge "Define trust agent framework components"
* commit '53ab5174d5009786dc58da3011181b77e325c130':
  Define trust agent framework components
2014-03-31 19:26:11 +00:00
Adrian Roos
82142c21dd Define trust agent framework components
Adds the TrustManager system service that allows
registering for changes to the trust status and
reporting events that are important to trust agents.

Bug: 13723878
Change-Id: I7d0d2ea86fd755702d31aa5d49cac038a6cd4301
2014-03-31 21:18:28 +02:00
Jorim Jaggi
5cf17879a3 Reuse KeyguardViewMediator for new Keyguard implementation.
This change reuses KeyguardViewMediator for the new Keyguard
implementation in status bar. KeyguardViewManager is replaced by
StatusBarKeyguardManager which handles adding the view, setting the
state etc. StatusBarWindowManager is introduced to managed the window
of the status bar, which has the logic of both the old Keyguard window
and the old status bar window. In the current implementation, Keyguard
gets displayed like it would be in the bouncer state, but that's likely
to change in the future. Also, setHidden in IKeyguardService is also
renamed to setOccluded, as the word hidden interferes with the
terminology when dismissing the Keyguard.

Bug: 13635952
Change-Id: I1c5d5a49d810d8532089f464cb2efe35e577f517
2014-03-31 20:58:31 +02:00
Jorim Jaggi
8ae65aecc8 Address comments for I059d80d8b9b9818a778ab685f4672ea2694def63
Bug: 13635952
Change-Id: I5d2bd44b3588621f26d94baab161e4e2444197a8
2014-03-31 12:15:18 +00:00
Jorim Jaggi
380ecb81db Make Keyguard a library and make StatusBar the new Keyguard.
This change achieves a couple of things:
- Let Keyguard be a library, so we can use it in SystemUI.
- Introduce FLAG_KEYGUARD for windows and deprecate TYPE_KEYGUARD. Make
all the TYPE_KEYGUARD behaviour dependant on the flag.
- Implement a new KeyguardService in SystemUI, and bind that service
from PhoneWindowManager.
- Introduce BaseStatusBar.setKeyguardState and inflate
KeyguardSimpleHostView there and use FLAG_KEYGUARD for the window, such
that the status bar window essentially gets the Keyguard.

Bug: 13635952
Change-Id: I059d80d8b9b9818a778ab685f4672ea2694def63
2014-03-28 22:35:03 +01:00
Paul Lawrence
945490c12e Don't double prompt on booting encrypted device
vold will store password securely until KeyGuard requests it
and hands it on to KeyStore.

This is a revision of

https://googleplex-android-review.git.corp.google.com/#/c/418123/

which was reverted. It had two bugs in LockSettingsService.checkVoldPassword.
1) We were not checking password for null, which caused an exception
2) checkPattern/checkPassword return true if there is no saved pattern or password.
   This leads to situations where we get true returned even when the password
   doesn't match. Call the correct one based on what is there, not what vold
   thinks ought to be there.

Bug: 12990752
Change-Id: I05315753387b1e508de5aa79b5a68ad7315791d4
2014-03-28 10:35:44 -07:00
John Spurlock
0e14f2d455 Merge "Remove obsolete MultiWaveView" 2014-03-28 13:11:09 +00:00
Adam Lesinski
776abc24cd Uses VMRuntime.newUnpaddedArray for ideal array sizes
Bug:13028925

Change-Id: I0a9301248b10a339afbdc5e4ffe3310ac4fa1fb7
2014-03-27 11:42:10 -07:00
Jorim Jaggi
73581effb0 Merge "Move legacy notification processing to Notification.Builder" 2014-03-27 14:25:17 +00:00
Jorim Jaggi
5c2d84675b Move legacy notification processing to Notification.Builder
Bug: 13485610
Change-Id: I5466d3dbc328c77876dc701c17e7a5a06777dbbe
2014-03-27 12:08:55 +01:00
John Spurlock
4f0db5e23a Remove obsolete MultiWaveView
Change-Id: Ic878221c873d29577928aed2669f967851307e4d
2014-03-26 21:52:03 -04:00
Paul Lawrence
6ee7d25010 Revert "Don't prompt at boot if we already did that when decrypting"
This reverts commit 493e3e7e6523fd94cc1acae3e45935a1227d58c3.

Should fixes

Bug: 13611885
Bug: 13656830
Change-Id: I117c988bb6679f44f8add4fcc18f45cb8238dfb4
2014-03-26 22:31:04 +00:00
Dianne Hackborn
4590e52f3d Battery stats: wake locks, radio active, cleanup.
- Improve wake lock work source updates to also update the current
  history tag, in case the new work source gets recorded in the
  history.

- Fix bug in recording radio active time that was not distributing
  any time to apps.

- No longer hold a wake lock while dispatching data conn active call,
  since it comes with its own timestamp.

- Fix issue where the top app was not being cleared while the screen
  was off.

- Remove obsolete STATS_LAST stats type.

- Fix bug that was not clearing the total run time when resetting
  the stats.

Change-Id: Iabe17a9edf34f762374ae09fcffb8a819cf72e30
2014-03-24 13:36:46 -07:00
Dianne Hackborn
a1bd79268b Battery stats: track actually running time
Use the uptime while creating the battery stats history to
generate a new event indicating when the CPU is actually running.
We can do this in combination with the new event reporting when
the CPU comes awake, looking at the difference between the
uptime and elapsed time at that point to determine when it last
when to sleep.

Also use this information to generate a new set of aggregated
states, the uptime caused by each wake reason.

Finally use new radio down timestamp to adjust the times we
compute for radio use.  Note that this information is not (yet)
being used to adjust how these are recorded in the history.

Change-Id: I723b3b526c8e7d64de0cac9d1193e04132d5a3e4
2014-03-21 16:14:59 -07:00
Paul Lawrence
717e0f5db7 Merge "Don't prompt at boot if we already did that when decrypting" 2014-03-21 20:40:46 +00:00
John Spurlock
f9e1a0b369 Annotate framework vibrate calls with stream hints.
Migrate existing framework usages of Vibrator.vibrate to use
the new overload with an explicit stream hint.  This prevents
them from being blocked by rules targeting the unspecified stream.

For calls that pass the existing appops check in VibrateService,
pass streamHint down to the input device vibrator so we don't lose
the signal, but leave it up to InputManager to decide what to do
with it - currently unused.

Change-Id: I65c944e4010edea29a412bf57d8d7d3b8098b746
2014-03-21 08:57:53 -04:00
Christopher Tate
adfe8b86e9 App widget backup/restore infrastructure
Backup/restore now supports app widgets.

An application involved with app widgets, either hosting or publishing,
now has associated data in its backup dataset related to the state of
widget instantiation on the ancestral device.  That data is processed
by the OS during restore so that the matching widget instances can be
"automatically" regenerated.

To take advantage of this facility, widget-using apps need to do two
things:  first, implement a backup agent and store whatever widget
state they need to properly deal with them post-restore (e.g. the
widget instance size & location, for a host); and second, implement
handlers for new AppWidgetManager broadcasts that describe how to
translate ancestral-dataset widget id numbers to the post-restore
world.  Note that a host or provider doesn't technically need to
store *any* data on its own via its agent; it just needs to opt in
to the backup/restore process by publishing an agent.  The OS will
then store a small amount of data on behalf of each widget-savvy
app within the backup dataset, and act on that data at restore time.

The broadcasts are AppWidgetManager.ACTION_APPWIDGET_RESTORED and
ACTION_APPWIDGET_HOST_RESTORED, and have three associated extras:

    EXTRA_APPWIDGET_OLD_IDS
    EXTRA_APPWIDGET_IDS
    EXTRA_HOST_ID [for the host-side broadcast]

The first two are same-sized arrays of integer widget IDs.  The
_OLD_IDS values are the widget IDs as known to the ancestral device.
The _IDS array holds the corresponding widget IDs in the new post-
restore environment.  The app should simply update the stored
widget IDs in its bookkeeping to the new values, and things are
off and running.  The HOST_ID extra, as one might expect, is the
app-defined host ID value of the particular host instance which
has just been restored.

The broadcasts are sent following the conclusion of the overall
restore pass.  This is because the restore might have occurred in a
tightly restricted lifecycle environment without content providers
or the package's custom Application class.  The _RESTORED broadcast,
however, is always delivered into a normal application environment,
so that the app can use its content provider etc as expected.

*All* widget instances that were processed over the course of the
system restore are indicated in the _RESTORED broadcast, even if
the backing provider or host is not yet installed.  The widget
participant is responsible for understanding that these are
promises that might be fulfilled later rather than necessarily
reflecting the immediate presentable widget state.  (Remember
that following a cloud restore, apps may be installed piecemeal
over a lengthy period of time.)  Telling the hosts up front
about all intended widget instances allows them to show placeholder
UI or similarly useful information rather than surprising the user
with piecemeal unexpected appearances.

The AppWidgetProvider helper class has been updated to add a new
callback, onRestored(...), invoked when the _RESTORED broadcast
is received.  The call to onRestored() is immediately followed by
an invocation of onUpdate() for the affected widgets because
they will need to have their RemoteViews regenerated under the
new ID values.

Bug 10622506
Bug 10707117

Change-Id: Ie0007cdf809600b880d91989c00c3c3b8a4f988b
2014-03-20 12:30:51 -07:00
Dianne Hackborn
40c8725804 batstats: fix wake lock tracking, service bug
- Fix bug I introduced in handling wake lock changes where
  we weren't iterating over the new work sources correctly.
- Fix bug in ActiveServices that would wtf too much.
- Prepare to start tracking uptime in the battery history.

Change-Id: Ia94316be51bc6eab7b02f214a5c40c08e99cc3b1
2014-03-19 17:13:43 -07:00
John Spurlock
1af30c7ac4 Add stream-level suppression to vibrate/audio services.
- Add new audio restriction layer to app-ops.  Restrictions add
additional constraints to audio operations at a stream-level.
Restrictions do not affect the persistable state, and are purely
additive: that is, they can only impose additional contstraints, not
enable something that has already been disabled.  Restrictions
also support a whitelisted set of exempt package names.

- Add new audio stream-level checks to app-ops.

- Implement a provisional OP_PLAY_AUDIO suppression to three
java entry points MediaPlayer, AudioTrack, & SoundPool.

- Enhance vibrator api to take stream information as an optional
hint - the constants correspond to AudioManager stream types.
OP_VIBRATE now supports the stream-level restriction check.

- Simplify Vibrator subclasses by adding default implementations
for two .vibrate calls.

- Migrate NoMan's zen-mode control to use the new app-ops
stream-level restriction mechanism.

Change-Id: Ifae8952647202f728cf1c73e881452660c704678
2014-03-19 15:32:51 -04:00
George Mount
31dc8f701f Merge "Fix ActionBar layout bug when INVISIBLE." 2014-03-19 14:25:23 +00:00
George Mount
14a9738330 Fix ActionBar layout bug when INVISIBLE.
ActionBar did not layout properly when INVISIBLE, but worked
when VISIBLE or GONE.

Change-Id: I30ca85377f3516c79174a35b65648d4ca68e927a
2014-03-18 15:48:00 -07:00
Ashish Sharma
0535a9f7aa Include elapsed realtime (nanos) of the event in the radio state change notifications.
Bug: 13247811
Change-Id: I3454aa159a68b9087b4762df947b41965b5a3941
2014-03-18 21:42:02 +00:00
Jeff Sharkey
432f755d44 am ac0f9ffd: am da07fe64: am eeb36c5c: am d88d8174: Merge "Null pointer exception in FileRotator.java"
* commit 'ac0f9ffda2a7e48d2d641654dafd11b8da39830a':
  Null pointer exception in FileRotator.java
2014-03-17 17:57:13 +00:00
Jeff Sharkey
da07fe64b0 am eeb36c5c: am d88d8174: Merge "Null pointer exception in FileRotator.java"
* commit 'eeb36c5cfc107fe9128490e9e127c2bca2d24e28':
  Null pointer exception in FileRotator.java
2014-03-17 16:39:13 +00:00
Yohei Yukawa
c05362b84c am 77943308: am fd2f8d43: am 51b921d0: DO NOT MERGE - Preserve the order of InputMethodManager method calls
* commit '77943308f5661636d85cb5e78188dbbc8f0e329e':
  DO NOT MERGE - Preserve the order of InputMethodManager method calls
2014-03-14 21:59:35 +00:00
Yohei Yukawa
77943308f5 am fd2f8d43: am 51b921d0: DO NOT MERGE - Preserve the order of InputMethodManager method calls
* commit 'fd2f8d43419d1f25ced8b2bac96407925dd4c471':
  DO NOT MERGE - Preserve the order of InputMethodManager method calls
2014-03-14 21:54:49 +00:00