Fix Slog.wtf to not acquire the activity manager lock in its code
path, so that it can never deadlock. This was the original intention
of it, but part was missed.
Now we can put back in the code to detect when strict mode data is
getting large (a little more targeted now to the actual problem),
and use Slog.wtf to report it. And as a bonus, when this happens
we will now clear all of the collected violations, to avoid getting
in to the bad case where IPCs start failing. So this should be
good enough for L to fix the problem, with wtf reports for us to
see if the underlying issue is still happening.
Finally, switch a butch of stuff in the system process from Log.wtf
to Slog.wtf, since many of those are deadlocks waiting to happen.
Oh and fix a crash in the settings provider I noticed in APR.
Change-Id: I307d51b7a4db238fd1e5fe2f3f9bf1b9c6f1c041
Added a new SLEEP_TIMEOUT setting which governs how long the device will
remain awake or dreaming without user activity. By default this
value is set to -1 which maintains today's existing behavior.
We basically represent the time we are allowed to be dreaming as a new
kind of user activity summary state called DREAM, similar to BRIGHT
and DIM. When the sleep timeout expires, the state is cleared and
the dream ends.
Bug: 17665809
Change-Id: I59aa7648dcec215f1285464fc1134934a09230e5
SettingsProvider reads secure and system settings for managed
profiles from user 0 instead. However it still checks the cache
for the managed profile not user 0.
Bug: 17736586
Change-Id: I15d44b8a5779b01e6b9032e528dc34f5c5602449
If there's a user restriction on location sharing in a
managed profile, always return empty string for location
providers so that location can be disabled by the admin
even if the primary user has location enabled.
Also fix an incorrect update of the cache. Shouldn't update
the primary user's cache when the caller is the managed profile.
Bug: 17478855
Change-Id: Icab3459ae351c5cfc287e21df6a5ba1df9dfbdb4
Cloning of settings to managed profiles could fail due to security restrictions. This caused
Settings app crash. Instead the exception is now caught inside SettingsProvider, logged,
and we leave the app running.
Bug:17450158
Change-Id: I7525d634e57701db304117f4b2035faf53977836
When users upgrade to L, don't restore into a state that would force
zen mode to follow suit. A user's first encounter with zen mode
should be via the UI.
Bug:16826161
Change-Id: I4eb63dce37d88f3a91b5034b3393eed2b768562c
1. Removed setting from Settings.System class.
2. Added settings database migration step to change "SIP_ASK_ME_EACH_TIME"
to "SIP_ADDRESS_ONLY" as the "ask me each time" option no longer makes
sense given the new phone accounts settings.
Bug: 17321422
Change-Id: I3df1be4fcda44f2097c49af44508ac1fce72a24b
Add a notification for those users that teaches them how to re-enable
the notifications.
Bug: 15934899
Depends-On: Ie0bcc207c4f331def207e588bbad36b8986fe114
Change-Id: I4a169e268042cfcaa4ad80cdf205904f9c90e76d
1. Persist microphone mute state.
2. Set mute state for correct user.
3. Check for settings restrictions as the correct user.
Bug: 17177502
Bug: 16701642
Change-Id: Id8b6cd90c5caceb67fbec862f90aac7ec7a00b3c
There is only one instance of the Settings ContentProvider, running in the user 0.
So it should be marked as singleUser.
BUG: 17133716
Change-Id: I426667ddbc8e682e7ea81f04633c0ad4f42782cb
Reset the auto-brightness setting to default since the behavior
of the feature is now quite different and is being presented to
the user in a new way as "adaptive brightness".
Bug: 17114082
Change-Id: Ica63f4caaaf50ad95dc9df88bb376f79782976f7
All reads of those specific settings will go to the primary user.
Inserts to primary also go to managed profiles in order to notify
any observers.
This enables Location settings to be shared by both profiles.
Also some other settings related to IME and Accessibility since
those services are shared across the profiles.
Bug: 16457210
Change-Id: Ib8fd697b5c78027fcbaf245d82dda5e6d6aab4f0
Also, note that this method never worked. Locale
settings were stored with underscores (like Locale.toString)
but matched against AssetManager.getLocales() which
returned language-tag like output.
bug: 10090157
(cherry picked from commit fd138cd81a689ff46e6ae90e46adcdc53f3c5442)
Change-Id: Ifc81ac902c297387dba8c40aba0656e18af57c86