OSDN Git Service

android-x86/frameworks-base.git
5 years agoMerge "Adding some helper methods in QuickstepContract"
TreeHugger Robot [Wed, 3 Apr 2019 20:26:44 +0000 (20:26 +0000)]
Merge "Adding some helper methods in QuickstepContract"

5 years agoMerge "Proper package icon for Q SystemUI."
Daniel Sandler [Wed, 3 Apr 2019 20:07:38 +0000 (20:07 +0000)]
Merge "Proper package icon for Q SystemUI."

5 years agoMerge "Ensure input transactions are applied before injecting input"
Chavi Weingarten [Wed, 3 Apr 2019 20:05:59 +0000 (20:05 +0000)]
Merge "Ensure input transactions are applied before injecting input"

5 years agoMerge "Fix am start -S <package>"
Zhi An Ng [Wed, 3 Apr 2019 20:04:58 +0000 (20:04 +0000)]
Merge "Fix am start -S <package>"

5 years agoMerge changes from topic "rro-cts"
Ryan Mitchell [Wed, 3 Apr 2019 20:04:41 +0000 (20:04 +0000)]
Merge changes from topic "rro-cts"

* changes:
  RRO CTS Test APIs
  Relax restrictions on non-system overlays

5 years agoMerge "Fix idmap2 policy concatenation"
TreeHugger Robot [Wed, 3 Apr 2019 20:04:32 +0000 (20:04 +0000)]
Merge "Fix idmap2 policy concatenation"

5 years agoFix am start -S <package>
Ng Zhi An [Tue, 2 Apr 2019 16:00:22 +0000 (09:00 -0700)]
Fix am start -S <package>

Previously, am start <package> and am start -S <package> had different
behaviors because the -S code path did not convert the default user id
(by calling handleIncomingUser) into a proper userId that is uses for
querying intent activities.
The default user id is converted in other code paths, so we do not
convert it inside of makeIntent, but only in the mStopOption path, right
before queryIntentActivities.

Test: adb shell am start -S com.android.chrome
Test: adb shell run-as com.example.zhin am start
(same as P)
IllegalArgumentException: No intent supplied
Test: adb shell run-as com.example.zhin am start com.example.zhin
(same as P)
Security exception: Permission Denial: startActivityAsUser asks to run as user
-2 but is calling from uid u0a193; this requires
android.permission.INTERACT_ACROSS_USERS_FULL
Test: adb shell run-as com.example.zhin am start --user 0 com.example.zhin
(same as P)
Starting: Intent { act=android.intent.action.MAIN
cat=[android.intent.category.LAUNCHER] pkg=com.example.zhin }
Error: Activity not started, unable to resolve Intent {
    act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER]
    flg=0x10000000 pkg=com.example.zhin }
Bug: 129712542
Change-Id: I3ce6ffd40fd834bffd28b4440c1fb0024c799d95

5 years agoMerge "Add onPointerDownOutsideFocus for events outside the focused window (4/4)"
Chavi Weingarten [Wed, 3 Apr 2019 19:59:24 +0000 (19:59 +0000)]
Merge "Add onPointerDownOutsideFocus for events outside the focused window (4/4)"

5 years agoMerge "PlayerBase: conditional muting on OP_PLAY_AUDIO changes"
Jean-Michel Trivi [Wed, 3 Apr 2019 19:58:59 +0000 (19:58 +0000)]
Merge "PlayerBase: conditional muting on OP_PLAY_AUDIO changes"

5 years agoMerge "Straighten AIDL interface for the memory store"
Chalard Jean [Wed, 3 Apr 2019 19:58:46 +0000 (19:58 +0000)]
Merge "Straighten AIDL interface for the memory store"

5 years agoMerge "Adds the flyout view."
Josh Tsuji [Wed, 3 Apr 2019 19:54:34 +0000 (19:54 +0000)]
Merge "Adds the flyout view."

5 years agoMerge "Using input monitor for edge swipe handling for back"
TreeHugger Robot [Wed, 3 Apr 2019 19:47:26 +0000 (19:47 +0000)]
Merge "Using input monitor for edge swipe handling for back"

5 years agoMerge "Add package name when loadModules and attach."
TreeHugger Robot [Wed, 3 Apr 2019 19:36:20 +0000 (19:36 +0000)]
Merge "Add package name when loadModules and attach."

5 years agoMerge "Removes unnecessary call to prepareScanResultLocked"
TreeHugger Robot [Wed, 3 Apr 2019 19:35:40 +0000 (19:35 +0000)]
Merge "Removes unnecessary call to prepareScanResultLocked"

5 years agoMerge "Set packages.list context to packages_list_file."
TreeHugger Robot [Wed, 3 Apr 2019 19:34:28 +0000 (19:34 +0000)]
Merge "Set packages.list context to packages_list_file."

5 years agoMerge "Add onDestroyView to allow clock plugins to clean up resources."
TreeHugger Robot [Wed, 3 Apr 2019 19:33:23 +0000 (19:33 +0000)]
Merge "Add onDestroyView to allow clock plugins to clean up resources."

5 years agoMerge "Set current user to USER_NULL when HAL dies"
Kevin Chyn [Wed, 3 Apr 2019 19:33:11 +0000 (19:33 +0000)]
Merge "Set current user to USER_NULL when HAL dies"

5 years agoMerge "Don't invoke resetLockout when not enrolled"
Kevin Chyn [Wed, 3 Apr 2019 19:32:51 +0000 (19:32 +0000)]
Merge "Don't invoke resetLockout when not enrolled"

5 years agoAdds the flyout view.
Joshua Tsuji [Tue, 26 Mar 2019 17:57:05 +0000 (13:57 -0400)]
Adds the flyout view.

This moves the view itself from BubbleView to BubbleStackView, since there will never be multiple flyouts and it simplifies layout. This also adds getUpdateMessage to NotificationEntry which is used to generate the flyout text.

Test: atest SystemUITests
Change-Id: Ief2fcfb2b12b927fdd68f737d49080335c884bef

5 years agoMerge "Disallow PIP for Volume Panel"
TreeHugger Robot [Wed, 3 Apr 2019 19:07:26 +0000 (19:07 +0000)]
Merge "Disallow PIP for Volume Panel"

5 years agoMerge "Remove focusable attribute from car_preference."
David Nelloms [Wed, 3 Apr 2019 19:04:01 +0000 (19:04 +0000)]
Merge "Remove focusable attribute from car_preference."

5 years agoMerge "Ensure that we always log updating from file."
TreeHugger Robot [Wed, 3 Apr 2019 18:33:29 +0000 (18:33 +0000)]
Merge "Ensure that we always log updating from file."

5 years agoAdding some helper methods in QuickstepContract
Sunny Goyal [Wed, 3 Apr 2019 18:25:35 +0000 (11:25 -0700)]
Adding some helper methods in QuickstepContract

Test: N/A
Change-Id: I3d4c05820659a1f91d4a23f2bfd2ffc56ed06234

5 years agoMerge "Allow companion apps to start background activities from PendingIntents (even...
TreeHugger Robot [Wed, 3 Apr 2019 18:20:33 +0000 (18:20 +0000)]
Merge "Allow companion apps to start background activities from PendingIntents (even if they aren't foreground)"

5 years agoMerge "Remove obscure check that was always true"
TreeHugger Robot [Wed, 3 Apr 2019 18:19:02 +0000 (18:19 +0000)]
Merge "Remove obscure check that was always true"

5 years agoMerge "Merge "Clean up permissions when uids are no longer used" am: 7754d368f4 am...
Android Build Merger (Role) [Wed, 3 Apr 2019 18:04:24 +0000 (18:04 +0000)]
Merge "Merge "Clean up permissions when uids are no longer used" am: 7754d368f4 am: ecb28c1948 am: 16ee7a1be4"

5 years agoMerge "Clean up permissions when uids are no longer used" am: 7754d368f4 am: ecb28c1948
Chenbo Feng [Wed, 3 Apr 2019 18:03:32 +0000 (11:03 -0700)]
Merge "Clean up permissions when uids are no longer used" am: 7754d368f4 am: ecb28c1948
am: 16ee7a1be4

Change-Id: I7773132d11d6225eac91ab2fee1043159c295d83

5 years agoFix idmap2 policy concatenation
Ryan Mitchell [Wed, 3 Apr 2019 18:02:39 +0000 (11:02 -0700)]
Fix idmap2 policy concatenation

When printing warning messages while generating idmaps, put the vertical
bar chracater in between the policies.

Bug: none
Test: manual

Change-Id: I8efee753d9ed7ce99ccafd49b6c8744eea031839

5 years agoMerge "Add statically built regex pattern to avoid rebuilding all the time"
Ioannis Ilkos [Wed, 3 Apr 2019 18:02:27 +0000 (18:02 +0000)]
Merge "Add statically built regex pattern to avoid rebuilding all the time"

5 years agoMerge "Snapshot arguments before processing."
Jeff Sharkey [Wed, 3 Apr 2019 17:58:22 +0000 (17:58 +0000)]
Merge "Snapshot arguments before processing."

5 years agoMerge "Clean up permissions when uids are no longer used" am: 7754d368f4
Chenbo Feng [Wed, 3 Apr 2019 17:50:39 +0000 (10:50 -0700)]
Merge "Clean up permissions when uids are no longer used" am: 7754d368f4
am: ecb28c1948

Change-Id: I256ca6f16ea1fcd240a1b7cd2b3199d4504e6c33

5 years agoMerge "OverlayInfo API: fix @Nullable -> @NonNull"
Todd Kennedy [Wed, 3 Apr 2019 17:48:11 +0000 (17:48 +0000)]
Merge "OverlayInfo API: fix @Nullable -> @NonNull"

5 years agoMerge "Avoid a bunch of log spam in SmartReplyConstantsTest."
TreeHugger Robot [Wed, 3 Apr 2019 17:45:47 +0000 (17:45 +0000)]
Merge "Avoid a bunch of log spam in SmartReplyConstantsTest."

5 years agoMerge "Clean up permissions when uids are no longer used"
Chenbo Feng [Wed, 3 Apr 2019 17:38:57 +0000 (10:38 -0700)]
Merge "Clean up permissions when uids are no longer used"
am: 7754d368f4

Change-Id: I3c06a36368abb9a1e7885d281ea1155fce857eea

5 years agoMerge "Cancel Metric activations"
Muhammad Qureshi [Wed, 3 Apr 2019 17:38:51 +0000 (17:38 +0000)]
Merge "Cancel Metric activations"

5 years agoMerge "Increase char limit for face_error_not_enrolled"
TreeHugger Robot [Wed, 3 Apr 2019 17:37:07 +0000 (17:37 +0000)]
Merge "Increase char limit for face_error_not_enrolled"

5 years agoAdd onDestroyView to allow clock plugins to clean up resources.
Robert Snoeberger [Wed, 3 Apr 2019 17:09:55 +0000 (13:09 -0400)]
Add onDestroyView to allow clock plugins to clean up resources.

Fixes: 129859743
Test: New test point added to KeyguardClockSwitchTest
Change-Id: Ia0eb7cb329820a64a4783937f65135fda742a2d1

5 years agoSet packages.list context to packages_list_file.
Florian Mayer [Thu, 21 Mar 2019 13:57:42 +0000 (13:57 +0000)]
Set packages.list context to packages_list_file.

Bug: 123186697

Test: adb shell su root ls -lZd /data/system/packages.list
-rw-r----- 1 system package_info u:object_r:packages_list_file:s0 35816 2019-04-02 14:17 /data/system/packages.list

Change-Id: I62ae03b5c2acf6c703f2e4c6f49cc68825e3a785

5 years agoUsing input monitor for edge swipe handling for back
Sunny Goyal [Tue, 2 Apr 2019 17:20:29 +0000 (10:20 -0700)]
Using input monitor for edge swipe handling for back

Bug: 112934365
Bug: 124299674
Bug: 124298541
Test: Verified build on device
Change-Id: Ic4cc4339b22aee63b0d96587f05dae3d8c01563f

5 years agoMerge "Dont sync keys using the unified challenge profile random credential"
Annie Meng [Wed, 3 Apr 2019 17:18:34 +0000 (17:18 +0000)]
Merge "Dont sync keys using the unified challenge profile random credential"

5 years agoMerge "Remove call identification APIs."
Tyler Gunn [Wed, 3 Apr 2019 17:18:10 +0000 (17:18 +0000)]
Merge "Remove call identification APIs."

5 years agoMerge "Clean up permissions when uids are no longer used"
Treehugger Robot [Wed, 3 Apr 2019 17:15:48 +0000 (17:15 +0000)]
Merge "Clean up permissions when uids are no longer used"

5 years agoMerge "Fix NPE in logActionClick"
TreeHugger Robot [Wed, 3 Apr 2019 17:10:25 +0000 (17:10 +0000)]
Merge "Fix NPE in logActionClick"

5 years agoRemoves unnecessary call to prepareScanResultLocked
Patrick Baumann [Wed, 3 Apr 2019 17:09:00 +0000 (10:09 -0700)]
Removes unnecessary call to prepareScanResultLocked

There were two calls to prepare scan result within a dozen lines of one
another. This was not resulting in any bad behavior, but was unnecessary
and resulted in unneeded warnings.

Test: atest CtsAtomicInstallTestCases:AtomicInstallTest
Bug: 109941548
Change-Id: I8817a189cb9976382a8057fe8b2c7a638f3d0d64

5 years agoMerge "Enforce new bubble policy in NoMan"
Mady Mellor [Wed, 3 Apr 2019 17:08:09 +0000 (17:08 +0000)]
Merge "Enforce new bubble policy in NoMan"

5 years agoMerge "Add metadata and headers to incident reports."
TreeHugger Robot [Wed, 3 Apr 2019 17:06:29 +0000 (17:06 +0000)]
Merge "Add metadata and headers to incident reports."

5 years agoMerge "Change visibility of *WorkSourceUid APIs to public instead of @SystemApi."
Olivier Gaillard [Wed, 3 Apr 2019 17:06:07 +0000 (17:06 +0000)]
Merge "Change visibility of *WorkSourceUid APIs to public instead of @SystemApi."

5 years agoEnsure that we always log updating from file.
Alex Kershaw [Wed, 3 Apr 2019 10:24:31 +0000 (11:24 +0100)]
Ensure that we always log updating from file.

If an exception was thrown by one of the methods, we were not logging
the event, which caused the CTS test to fail.

In particular, this happened on non-AB devices, such as the emulator.

Bug: 127268862
Change-Id: I8f853d5e0a8e810a570562071fb73266fee3b696
Test: atest CtsDevicePolicyManagerTestCases:com.android.cts.devicepolicy.DeviceOwnerTest#testInstallUpdateLogged

5 years agoMerge "Change KernelCpuThreadReader frequency bucketing to work with >2 core clusters"
TreeHugger Robot [Wed, 3 Apr 2019 17:03:21 +0000 (17:03 +0000)]
Merge "Change KernelCpuThreadReader frequency bucketing to work with >2 core clusters"

5 years agoMerge "Don't lock the profile after setting work challenge."
TreeHugger Robot [Wed, 3 Apr 2019 16:58:31 +0000 (16:58 +0000)]
Merge "Don't lock the profile after setting work challenge."

5 years agoMerge "Disable a flaky test, will fix later."
Josh Tsuji [Wed, 3 Apr 2019 16:46:15 +0000 (16:46 +0000)]
Merge "Disable a flaky test, will fix later."

5 years agoMerge "Ensure that THM sets up even when system dies"
William Hester [Wed, 3 Apr 2019 16:43:12 +0000 (16:43 +0000)]
Merge "Ensure that THM sets up even when system dies"

5 years agoMerge "libmedia2_jni: link to libcgrouprc"
Yifan Hong [Wed, 3 Apr 2019 16:41:20 +0000 (16:41 +0000)]
Merge "libmedia2_jni: link to libcgrouprc"

5 years agoDisable a flaky test, will fix later.
Joshua Tsuji [Wed, 3 Apr 2019 16:37:26 +0000 (12:37 -0400)]
Disable a flaky test, will fix later.

Test: Disabling a test
Change-Id: Ifc76fc8fc66ee57ebf87eedcad0e2474a19674da

5 years agoMerge "Merge "Pass app's data dir to ART" am: 16749ac83e am: 33ed677361 am: 6277c39b0e"
Android Build Merger (Role) [Wed, 3 Apr 2019 16:32:55 +0000 (16:32 +0000)]
Merge "Merge "Pass app's data dir to ART" am: 16749ac83e am: 33ed677361 am: 6277c39b0e"

5 years agoMerge "Tweak bar chart measurement."
TreeHugger Robot [Wed, 3 Apr 2019 16:32:48 +0000 (16:32 +0000)]
Merge "Tweak bar chart measurement."

5 years agoMerge "Pass app's data dir to ART" am: 16749ac83e am: 33ed677361
David Brazdil [Wed, 3 Apr 2019 16:30:44 +0000 (09:30 -0700)]
Merge "Pass app's data dir to ART" am: 16749ac83e am: 33ed677361
am: 6277c39b0e

Change-Id: Iec85a2630e364e66e45e42f2cbb6a26008c0ab4a

5 years agoMerge "Support content description with app name"
TreeHugger Robot [Wed, 3 Apr 2019 16:30:08 +0000 (16:30 +0000)]
Merge "Support content description with app name"

5 years agoProper package icon for Q SystemUI.
Dan Sandler [Wed, 3 Apr 2019 04:43:57 +0000 (00:43 -0400)]
Proper package icon for Q SystemUI.

Test: make, examine in Settings
Bug: 123903304
Change-Id: I81d8c283ed67725fa85c9a3116c7434cb00d3d22

5 years agoMerge "Improve CursorWindow failure message"
Makoto Onuki [Wed, 3 Apr 2019 16:19:28 +0000 (16:19 +0000)]
Merge "Improve CursorWindow failure message"

5 years agoMerge "Pass app's data dir to ART" am: 16749ac83e
David Brazdil [Wed, 3 Apr 2019 16:13:31 +0000 (09:13 -0700)]
Merge "Pass app's data dir to ART" am: 16749ac83e
am: 33ed677361

Change-Id: I9a7c617f13dadc91b735837d1778e3d526be8520

5 years agoOverlayInfo API: fix @Nullable -> @NonNull
Mårten Kongstad [Tue, 2 Apr 2019 13:22:17 +0000 (15:22 +0200)]
OverlayInfo API: fix @Nullable -> @NonNull

OverlayInfo#getTargetPackageName will never return null. Correct
@Nullable annotation to say @NonNull instead.

Fixes: 129853770
Test: builds, boots
Change-Id: I70a9634e4f7da99be5d9044a7884b9ad01a22fd8

5 years agoMerge "Expose input region monitoring to system components."
Michael Wright [Wed, 3 Apr 2019 16:04:03 +0000 (16:04 +0000)]
Merge "Expose input region monitoring to system components."

5 years agoMerge "Update the format of the am_compact event log message."
TreeHugger Robot [Wed, 3 Apr 2019 16:03:45 +0000 (16:03 +0000)]
Merge "Update the format of the am_compact event log message."

5 years agoImprove CursorWindow failure message
Makoto Onuki [Tue, 2 Apr 2019 21:05:05 +0000 (14:05 -0700)]
Improve CursorWindow failure message

Bug: 129139241
Bug: 129721058
Test: atest CursorWindowTest
Change-Id: Iac1c5ec6f999dadd638fc5ab47c69d13f60ea467

5 years agoMerge "Adds the ability for SysUI to request QSB alpha changes."
Govinda Wasserman [Wed, 3 Apr 2019 15:59:10 +0000 (15:59 +0000)]
Merge "Adds the ability for SysUI to request  QSB alpha changes."

5 years agodocs: Javadoc cleanup
Andrew Solovay [Thu, 28 Mar 2019 22:56:45 +0000 (15:56 -0700)]
docs: Javadoc cleanup

There were a number of Javadoc style problems in the
WifiNetworkSuggestion.Builder.build() docs, which caused some formatting
problems.

One specific problem worth noting: A {{ causes trouble at publish time,
because it looks like the start of a Django directive. But escaping the
{ -- e.g. &#123 -- doesn't work, because the Javadoc compiler helpfully
escapes the *ampersand*, so the HTML output is "&amp;#123", which
renders on the page as "&#123" instead of "{". So putting a space
between the two braces seems like the simplest solution.

No code changes here, just Javadoc comment fixes.

Tested by building the docs and staging to:

http://go/dac-stage/reference/android/net/wifi/WifiNetworkSuggestion.Builder#build

Screenshots (in case the stage gets overwritten):
https://screenshot.googleplex.com/o4p7efFGCbJ.png (1)
https://screenshot.googleplex.com/nkhEqU54LNb.png (2)

Bug: 128536865
Test: make ds-docs (then build & stage)
Change-Id: Ie04bc4dc517443a6899aba989beeb38b9299826e

5 years agoMerge "Remove user switcher when multiple users is disabled"
TreeHugger Robot [Wed, 3 Apr 2019 15:53:32 +0000 (15:53 +0000)]
Merge "Remove user switcher when multiple users is disabled"

5 years agoMerge "Don't announce changes in zen dialog"
TreeHugger Robot [Wed, 3 Apr 2019 15:41:33 +0000 (15:41 +0000)]
Merge "Don't announce changes in zen dialog"

5 years agoIncrease char limit for face_error_not_enrolled
Ilya Matyukhin [Wed, 3 Apr 2019 15:38:36 +0000 (08:38 -0700)]
Increase char limit for face_error_not_enrolled

Test: build
Fixes: 129708679
Change-Id: Id7ddb5a767dc33d701c2d8ba97672b41c93dccff

5 years agoMerge "Pass app's data dir to ART"
David Brazdil [Wed, 3 Apr 2019 15:35:34 +0000 (08:35 -0700)]
Merge "Pass app's data dir to ART"
am: 16749ac83e

Change-Id: I170cbff78d12ccc418cb440820a584f141f28433

5 years agoMerge "Tidy up some Javadoc."
TreeHugger Robot [Wed, 3 Apr 2019 15:32:42 +0000 (15:32 +0000)]
Merge "Tidy up some Javadoc."

5 years agoMerge "Set active stream when progerss changed by user"
TreeHugger Robot [Wed, 3 Apr 2019 15:28:12 +0000 (15:28 +0000)]
Merge "Set active stream when progerss changed by user"

5 years agoChange KernelCpuThreadReader frequency bucketing to work with >2 core clusters
Misha Wagner [Wed, 3 Apr 2019 11:37:17 +0000 (12:37 +0100)]
Change KernelCpuThreadReader frequency bucketing to work with >2 core clusters

Change-Id: I470dc055b9b1eb07913280fc269fbdadb259b4db
Test: atest KernelCpuThreadReaderTest

5 years agoMerge "Revert "Mute haptic channels by default.""
Eric Laurent [Wed, 3 Apr 2019 15:23:16 +0000 (15:23 +0000)]
Merge "Revert "Mute haptic channels by default.""

5 years agoMerge "[Multi-user] Clean up user state stored in the system user directory when...
Chandan Nath [Wed, 3 Apr 2019 15:22:11 +0000 (15:22 +0000)]
Merge "[Multi-user] Clean up user state stored in the system user directory when user is removed."

5 years agoMerge "Pass app's data dir to ART"
David Brazdil [Wed, 3 Apr 2019 15:21:45 +0000 (15:21 +0000)]
Merge "Pass app's data dir to ART"

5 years agoMerge "Use a confirmedTap listener to guarantee a click. This eliminates the overlapp...
TreeHugger Robot [Wed, 3 Apr 2019 15:13:32 +0000 (15:13 +0000)]
Merge "Use a confirmedTap listener to guarantee a click. This eliminates the overlapping component listener bug from the caption service."

5 years agoMerge "Use FLAG_BUBBLE rather than setting the value ourselves"
Mady Mellor [Wed, 3 Apr 2019 14:56:42 +0000 (14:56 +0000)]
Merge "Use FLAG_BUBBLE rather than setting the value ourselves"

5 years agoAllow companion apps to start background activities from
Michal Karpinski [Tue, 2 Apr 2019 18:46:52 +0000 (19:46 +0100)]
Allow companion apps to start background activities from
PendingIntents (even if they aren't foreground)

And push companion packages to ATMS after the user is
unlocked.

Bug: 129757565
Test: atest WmTests:ActivityStarterTests
Test: manual
Change-Id: Ic76d5c8a3fb096a8caf76dafb6c38212a8506f3a

5 years agoMerge "OMS: ignore instant apps"
Todd Kennedy [Wed, 3 Apr 2019 14:47:01 +0000 (14:47 +0000)]
Merge "OMS: ignore instant apps"

5 years agoMerge "Change theme setting to JSONObject format."
TreeHugger Robot [Wed, 3 Apr 2019 14:40:58 +0000 (14:40 +0000)]
Merge "Change theme setting to JSONObject format."

5 years agoFix NPE in logActionClick
Tony Mak [Wed, 27 Mar 2019 17:03:45 +0000 (17:03 +0000)]
Fix NPE in logActionClick

Problem:
The issue could happen when clicking on the archive button on the
notification from Gmail repeatedly and quickly. Tapping the Archive
button will change the notification layout to something custom
with a single UNDO button. The bug happens when the notification object
is already updated, while logActionClick of the old action button is
still running.

Proposed solution:
1. Add sanity check to avoid NPE, array index out of bounds.
2. To ensure that the action object is  the one we want, use PendingIntent in
Notification.Action as a token.

logActionClick is just used as logging, and the problem seems only happen
in repetitive clicks, so just bailing out should be fine.

Test: Have a Gmail notification, taps archive button repeatedly.
      Observe no crash.
Test: Ensure that log is sent in normal cases by checking logcat.

FIXES: 128804769

Change-Id: Ic04fd9288cba5253179bf1f478a7454e44f31703

5 years agoAvoid a bunch of log spam in SmartReplyConstantsTest.
Gustav Sennton [Wed, 3 Apr 2019 14:15:58 +0000 (15:15 +0100)]
Avoid a bunch of log spam in SmartReplyConstantsTest.

DeviceConfig logs errors when trying to read e.g. an integer and the
value provided isn't an integer. However, DeviceConfig avoids logging
the error if the value is null. So with this CL we use null as the reset
value for SmartReplyConstantsTest.

Bug: 129538548
Test: atest SmartReplyConstantsTest, and check logcat for spam.
Change-Id: I4c714b7e808163c20fccc5cdca734a255c698ede

5 years agoMerge "CastTile: Better handling of multiple active devices."
Narayan Kamath [Wed, 3 Apr 2019 14:10:22 +0000 (14:10 +0000)]
Merge "CastTile: Better handling of multiple active devices."

5 years agoMerge "Tell the app that a smart reply was used even when it has been edited."
TreeHugger Robot [Wed, 3 Apr 2019 14:07:39 +0000 (14:07 +0000)]
Merge "Tell the app that a smart reply was used even when it has been edited."

5 years agoRemove obscure check that was always true
Jorim Jaggi [Wed, 3 Apr 2019 12:50:57 +0000 (14:50 +0200)]
Remove obscure check that was always true

This condition never made any sense because we checked the
systemUiVisibility field for a WindowManager flag. Instead of
trying to fix it, let's just remove the check to keep the
behavior.

Test: boots
Bug: 129751541
Change-Id: Ib0ace4d47f5623b32430a8a7e4f25f5a259451ea

5 years agoMerge "Add more tests to KernelCpuThreadReaderDiffTest"
Misha Wagner [Wed, 3 Apr 2019 13:55:30 +0000 (13:55 +0000)]
Merge "Add more tests to KernelCpuThreadReaderDiffTest"

5 years agoTell the app that a smart reply was used even when it has been edited.
Gustav Sennton [Tue, 2 Apr 2019 14:10:00 +0000 (15:10 +0100)]
Tell the app that a smart reply was used even when it has been edited.

The existing API RemoteInput.Source covers two scenarios for responding
to message notifications:
1. A user uses the 'reply' button and enters a response freely.
2. A user clicks a smart reply which is used as the response.

Before this CL the platform would notify the app of scenario nr. 1 in
the case where we use tap-to-edit smart replies (replies that can be
edited before being sent). With this CL we instead log scenario nr. 2
(since a smart reply was clicked).

Bug: 123407240
Test: use a test-app to ensure that a response created using smart
replies + tap-to-edit logs the correct @Source.
Change-Id: I3dc8169a3c440af106c4f244b72ddf7c9e450203

5 years agoDont sync keys using the unified challenge profile random credential
Annie Meng [Fri, 29 Mar 2019 17:43:35 +0000 (17:43 +0000)]
Dont sync keys using the unified challenge profile random credential

When the work profile has a tied screen lock to its parent, its lock
credentials are set to a random password. This CL adds logic to prevent
syncing keys with this random credential.

On set/update lock:
- If creating the work profile or going from separate -> unified lock
screen: don't sync keys (random password case)
- If going from unified -> separate lock screen: sync keys
- If removing the parent lock: invalidate unified profile keys

On unlock:
- If unlocking a work profile with a unified lock: don't sync keys
(random password case).
- If unlocking a work profile with a separate lock: sync keys
- If unlocking a parent profile that has work profiles with a unified
lock: sync keys for the work profiles.

Design: https://docs.google.com/document/d/1y6LXcf-Rk3TMG-Ka4pJ5fpinDaK4fnlCyGi3kuGWWNg/edit?usp=sharing

Bug: 128834006
Test: 1) atest frameworks/base/services/tests/servicestests/src/com/android/server/locksettings/
2) Manual testing of the following cases by verifying key sync on the
backup device and being able to unencrypt the backup set on the restore
device:
a) Work profile unified lock screen: all 3 types (pin/password/pattern).
b) Changing parent lock screen in the unified case -> updates keys for
profile.
c) Unified lock screen -> separate lock screen: updates keys.
d) Separate lock screen and change credentials: updates keys.
e) Separate lock screen -> unified lock screen: does not update keys
with random password.
f) Unified lock screen -> remove lock screen: invalidates keys.

Change-Id: Ie2249f4c32fd6c48aae7f791e2d1e353b4ef9939

5 years agoChange visibility of *WorkSourceUid APIs to public instead of @SystemApi.
Olivier Gaillard [Wed, 3 Apr 2019 10:32:12 +0000 (11:32 +0100)]
Change visibility of *WorkSourceUid APIs to public instead of @SystemApi.

Bug: 127465468
Test: atest BinderWorkSourceTest
Change-Id: Ib5743219ed44b893a64825d3d8c66e2f20b4197f

5 years agoMerge "Use mPidMap instead of mProcessNames to get process with pid info"
Jorim Jaggi [Wed, 3 Apr 2019 13:16:43 +0000 (13:16 +0000)]
Merge "Use mPidMap instead of mProcessNames to get process with pid info"

5 years agoSupport content description with app name
Tony Mak [Mon, 1 Apr 2019 19:02:29 +0000 (20:02 +0100)]
Support content description with app name

The logic is like:
1. If content description string with app name placeholder is available,
   and we also have a app name, then we will use this string.
2. Otherwise, fallback to content description string without app
   name placeholder.

Test: atest frameworks/base/core/tests/coretests/src/android/view/textclassifier/
Test: Actually see the content description with app name is formatted
      properly

BUG: 128541828

Change-Id: Iee1dc8d4a429d759d9ab3f4b84dc1ad13b698cdb

5 years agoChange theme setting to JSONObject format.
Amin Shaikh [Tue, 2 Apr 2019 22:07:40 +0000 (18:07 -0400)]
Change theme setting to JSONObject format.

Add JSON_OBJECT_VALIDATOR to Settings and add unit tests.

Fixes: 129543539
Test: atest coretests
Change-Id: I4fa7a1357d442c1fa04a7eee815d5c3a48cc5115

5 years agoCancel Metric activations
Muhammad Qureshi [Thu, 28 Mar 2019 19:38:21 +0000 (12:38 -0700)]
Cancel Metric activations

Cancel Metric activations triggered by atom matchers

Bug: 128218061
Test: statsd_test
Test: statsd_localdrive
Change-Id: I90a705d74725c2aa04025e18e1fa77ec4fefc522

5 years agoDon't lock the profile after setting work challenge.
Pavel Grafov [Wed, 3 Apr 2019 12:58:58 +0000 (13:58 +0100)]
Don't lock the profile after setting work challenge.

In TrustManager user state defaults to "locked", so previously
the profile would become locked after work challenge is enabled.

Test: manual
Bug: 121256032
Change-Id: Ic0f5b075b85ca66c28d51830b47ed015c10da45c

5 years agoMerge "carrier-config: define imsi_eap_identity_sequence_int key"
Ecco Park [Wed, 3 Apr 2019 12:56:05 +0000 (12:56 +0000)]
Merge "carrier-config: define imsi_eap_identity_sequence_int key"

5 years agoExpose input region monitoring to system components.
Michael Wright [Thu, 14 Feb 2019 12:33:46 +0000 (12:33 +0000)]
Expose input region monitoring to system components.

This is to allow SysUI to detect system-wide gestures.

Test: manual
Bug: 123748692
Change-Id: Ic1e2cd6afea219d0e20b29e7150c9a42b75c7a67

5 years ago[Multi-user] Clean up user state stored in the system user directory
Chandan Nath [Fri, 29 Mar 2019 13:18:35 +0000 (13:18 +0000)]
[Multi-user] Clean up user state stored in the system user directory
when user is removed.

For non system users, backup state is stored in both the user's own dir and the system dir.
When the user is removed, the user's own dir gets removed by the OS. This code change ensures
that the part of the user backup state which is in the system dir also gets removed.

Bug: 127650374

Test: atest -v CtsBackupHostTestCases:android.cts.backup.MultiUserBackupStateTest

Change-Id: I4ea252e8e6da608e36ec3ac335666923d88a8748

5 years agoPass app's data dir to ART
David Brazdil [Wed, 3 Apr 2019 12:00:55 +0000 (13:00 +0100)]
Pass app's data dir to ART

Inform ART about the location of the app's data directory when setting
up the process. This is part of an optimization that has ART cache
verification data into that directory.

Test: compiles, boots
Bug: 72131483
Change-Id: Ic80526b6ee383733eb5860e66f6c608109d838fb