With File-Based Encryption (FBE), now we have yet another runteime event
to reset IMMS state in order to keep the list of available IMEs updated
and make sure one IME is enabled. Here is the full list of such runtime
events.
1. Boot phase reaches SystemService.PHASE_ACTIVITY_MANAGER_READY.
2. One or more packages that contain InputMethodService are updated.
3. The current user is switched.
4. The device locale is changed.
5. The device is unlocked by the current user.
Now we are adding the rule 5 in this CL.
We also apply Copy-On-Write (COW) settings mode, which was added in a
recent commit [1], until the deivice is unlocked. This allows us to
temporarily update the settings when the device is locked, without
messing up actual SecureSettings.
[1] I9c6f9bb3d51174198e5f73588637f87ea0d90e11
Here are some examples of what users would see in FBE-enabled devices.
Suppose we have following 5 IMEs installed.
- IME A: Encryption Aware, pre-installed, ASCII-capable
- IME B: Encryption Unaware, pre-installed, ASCII-capable
- IME C: Encryption Unaware, not pre-installed, ASCII-capable
- IME D: Encryption Aware, not pre-installed, ASCII-capable
Case 1)
Before boot:
Enabled: IME A
Selected: IME A
Device Locked:
Available: IME A, IME D
Enabled: IME A
Selected: IME A
Device Unolcked:
Available: IME A, IME B, IME C, IME D
Enabled: IME A
Selected: IME A
Case 2)
Before boot:
Enabled: IME A, IME B
Selected: IME B
Device Locked:
Available: IME A, IME D
Enabled: IME A
Selected: IME A
Device Unolcked:
Available: IME A, IME B, IME C, IME D
Enabled: IME A, IME B
Selected: IME B
Case 3)
Before boot:
Enabled: IME B, IME C
Selected: IME B
Device Locked:
Available: IME A, IME D
Enabled: IME A
Selected: IME A
Device Unolcked:
Available: IME A, IME B, IME C, IME D
Enabled: IME B, IME C
Selected: IME B
Note: in this case, IMMS can rely on an existing rule to support
the situation where enabled/selected IMEs were already uninstalled.
Case 4)
Before boot:
Enabled: IME B, IME C, IME D
Selected: IME B
Device Locked:
Available: IME A, IME D
Enabled: IME D
Selected: IME D
Device Unolcked:
Available: IME A, IME B, IME C, IME D
Enabled: IME B, IME C, IME D
Selected: IME B
Following things should be taken care of subsequent CLs.
- Add CTS to ensure that at least one encryption-aware IME is
pre-installed if the device supports FBE.
- Consider an accidental case where there is no encryption-aware IME.
This includes the case where all the encryption-aware system IMEs are
overwritten by encryption-unaware IMEs that have higher versions.
Bug: 26279466
Change-Id: Ifa2225070bf8223f8964cf063c86889e312c5e9a
Fix a bug where calling setUserVisibleHint(true) before adding a
Fragment to a FragmentManager could cause a crash.
Bug 27250018
Change-Id: Id192ae31bab95f15d32de9f105e707bdb8691641
Clients can now set a lock-only wallpaper that Keyguard can
observe and choose to draw as appropriate.
Bug 25454162
Change-Id: I3fc30e02919e814b55dfded2a1a36ad9d2e55299
Pressing backspace pops the user up a directory level if they aren't at
the root directory of the current root.
BUG=27123794
Change-Id: I8f0a88a1194bf8f082d0b057a288a0c3da3068f6
Reset mExiting even if we are not going to do enter animation.
Also make sure has surface state is set correctly if restoring.
bug: 27235356
Change-Id: Ie6e78baefc8242015ed9c37ab221c39860682ab2
Visually separate directory background from sidebar.
Lower shadows so the "real" effect isn't so prominent.
Hitchhikders:
Consolidate bool values in config.xml files (were in dimens.xml).
Add missing supportsRecents & supportsSearch methods
to RootInfo.
Rename RecentLoader to RecentsLoader so it doesn't defy
searching for "Recents" string.
Move Downloads below the divider.
Change-Id: I06c76e26ec6df6541860a1448865c67ed953ed43
This fixes a TODO to use kUTF32_TextEncoding directly. This avoids
encoding UTF32 codepoints from HarfBuzz into UTF16 to pass to Skia,
which will then re-decode to UTF32. This also removes a use of
SkUtils.h which Skia desires to move to private use.
Change-Id: I087f4216c25f7874e496920cd33e2f109530c397
am: d828c95a93 -s ours
* commit 'd828c95a930c6789f6251bc8a120bf2293a3a22e':
DO NOT MERGE ANYWHERE: UsageStats: Use new settings key idle_duration2 for app idle
am: f2fd47bfa5 -s ours
* commit 'f2fd47bfa5533bb9e57b37760edde71776048c88':
DO NOT MERGE ANYWHERE: UsageStats: Fix issue where initializing data for first time would cause crash
am: 78a2522c7f -s ours
* commit '78a2522c7f02570f36a3683a9ba5cfa813abc26e':
DO NOT MERGE ANYWHERE: UsageStatsService: Fix app idle issue at rollover time
am: 5c9378f310 -s ours
* commit '5c9378f310acd4ab375ed8a5d703a86522ab814c':
DO NOT MERGE ANYWHERE: UsageStats: Use new settings key idle_duration2 for app idle
Make printlns in Log public-@hide so it can be used.
Print uncaught exceptions that will terminate the process in
RuntimeInit using printlns, so that long exception traces are not
being truncated.
Bug: 27245306
Change-Id: Ib24635f0ebdd80bd125e367302cab6a78e6a210a
The new sdcardfs kernel driver needs to know this mapping for
deriving UID permissions, so push the data through /config when
supported by the kernel. This also has the nice benefit of letting
us push only the deltas of what actually changes, instead of
re-parsing the entire "packages.list" file.
The mappings for newly installed apps are pushed before the app is
allowed to run, removing some latent race conditions. Also cleans
up stale mappings when packages are uninstalled, and whenever the
system server reboots.
Bug: 19160983
Change-Id: Iace92efb69616c96b34c0d9d911e4b54e5fd8a67
am: bca4317a3b -s ours
* commit 'bca4317a3bbbdfdda083283d73a26e9c078c84f2':
DO NOT MERGE ANYWHERE: UsageStats: Fix issue where initializing data for first time would cause crash
am: 7e03454985 -s ours
* commit '7e0345498528611f538d8a5f259acc3440c1a649':
DO NOT MERGE ANYWHERE: UsageStatsService: Fix app idle issue at rollover time
WindowStateAnimator.mSurfaceController is set to null whenever a
surface is destroyed and WindowState.mHasSurface is set to false
shortly after that. However, it is possible for them to get out
of sync in a couple of places due to exceptions or duplicate destroy.
Consolidated the call to set WindowState.mHasSurface inside a finally
block in WindowStateAnimator.destroySurface
Also, cleaned up the code a little to that it is more obvious what is
going on.
Bug: 27235356
Change-Id: I7e6d0c1fb015531c393ac86dcaebebd134fad612
Interop database entries are stored in the system settings entry
"BluetoothInteropDatabase". The format is a list of entries separated by
";". An entry consists of a BDA fragment, followed by a comma and an
integer representing a feature from interop.h.
Example:
To disable LE secure connections for devices starting with BDA 11:22:33,
use "11:22:33,0".
Bug: 26548845
Change-Id: I6a9fd34f6af4d3bdfcaa0e051eafebdfbf2a4949
(cherry picked from commit 3bc623be8dd8b83d0a22c5cc5b5a8955001f6fc7)
This partially reverts the previous commit [1], which allowed special
components to be granted some pre-configured default permissions.
With this CL, we no longer grant Contacts permissions to pre-installed
IMEs. Rationals are:
1. Even without this CL, not the all pre-installed IMEs are granted
Contacts permission by default, because it was done during the boot
time where InputMethodManagerService is not yet completely
initialized. The current behavior is confusing not only for users
but also for developers.
2. In almost all the cases, IMEs are supposed to be able to work
without Contacts permission. Hence it is not too late to ask users
to grant the permission to the IME after the initial setup is
completed.
3. It is difficult to add new features such as File-Based Encryption
(FBE) with keeping the current implementation, because currently we
dynamically call mSettings.setCurrentUserId(userId) just to
enumerate what IMEs will be enabled for a given user. Adding
another condition (whether the user has already unlocked the device
or not) would make things more complicated.
Note that LatinIME has already support the case where Contacts
permission is not granted by default. It does not ask users for
anything until Setup-Wizard is completed, and requests Contacts
permission only when the user taps a message in the suggestion strip
that suggests users to use contacts name for typing suggestions.
[1] If8b8cadbd1980ffe7a6fc15bbb5f54a425f6e8f9
adc1cf46045ae756d3a9ccbccf6b0f894e4c1edd
Bug: 24756974
Bug: 26743676
Change-Id: Ief2a40b5971b3eb97d765f934d20ce7f2ef25665
And set the drawable's callback to null during drag-resizing, since
we use multi-threaded renderer, will do not want to schedule draws
to the ViewRootImpl's thread.
bug: 26729953
Change-Id: I6e5f94a5a6ba15edc2d391dd11d8fee3c657d337
(cherry picked from commit 1cc95075e89a0f91cb59ff37a1a027199040c7b4)
- Only add preserved surface to removal list when the new surface is shown
- When surface mode change again before the previous preserved surface is
removed, don't do nothing, instead, destroy the current surface which is
of wrong size.
bug: 26545679
Change-Id: Ifd548a0fa9ccdcbc9609ca38bb701cc7256cc6e1
(cherry picked from commit ec63381f7596d89719fd3528b181ed1820a4cb84)
Add the concept of a client ID which is used to identify a specific
(one of several) clients in all API calls.
Bug: 26962024
Change-Id: I43f13d51bee8b57c6d0ba1174168288b8d6c21c5
An app can now declare that it really needs to be backed up
whenever possible even if it is currently engaged in foreground-
equivalent work. Only applies to full-data backup clients: key/value
backups are not intrusive on normal lifecycle so they can already
happen in such circumstances.
Bug 26790411
Change-Id: Ia0ebcc7a53da888ae9ae4d63cd4bcab6e3a2e866
For the initial release of Marshmallow auto-launching was suppressed
for ChooserActivity if there was only a single choice in order to let
the user confirm what would be launched. In practice, many apps use
ACTION_CHOOSER when they should probably use implicit intents, but
still others have use cases where setting a default doesn't make sense
and the user should still be able to make a choice when one is
available.
As the user confirmation didn't buy much in terms of developer API
expectations (ACTION_CHOOSER being a forced choice) and it adds
speedbumps to existing apps in the ecosystem, revert this change.
Bug 27243827
Change-Id: Id8fd5385d5b1f459e80b0096efe7e2944264739a
Originally I didn't know user-0 could have PO, so I excluded this case
from migration. Now we handle it properly.
Also make sure only restrictions that can actually be set by each
owner moves to the owner restriction. (Because of this, we no longer
have to have DISALLOW_WALLPAPER in the exception list, because
owners can't set DISALLOW_WALLPAPER.)
Bug 27225996
Change-Id: I6ad79d90e6c4400abbb1e4feba6ba59e3b650815
Add a helper to the FocusManager, to handle alphanumeric keystrokes.
- Build a search index mapping document titles to adapter positions, and
keep it up-to-date.
- Intercept alphanumeric keystrokes and build up a search string from
them.
- Use the search string and index to set focus in the directory listing.
- Highlight code is written, but not activated in the UI for now, to
minimize surface area for potential breakages. Revisit enabling
highlights for O.
BUG=24988911
Change-Id: I148ff5583c655338d12bc06d6484a9ed7aa528ad