commit | 8725a2f5c84b47a5e3e3b085e2f02c2873e54a75 | [log] [tgz] |
---|---|---|
author | Felipe Leme <felipeal@google.com> | Wed Dec 09 16:04:51 2020 -0800 |
committer | Felipe Leme <felipeal@google.com> | Tue Jan 12 10:02:55 2021 -0800 |
tree | 09286ef1fa160f7a3fa4fd7c2cba070a8ff070cd | |
parent | eb220c277db6768e447ec19103f080ca483eade8 [diff] |
Initial implementation of DPM.ACTION_SHOW_NEW_USER_DISCLAIMER. This intent is broadcasted the first time a new user is added when the device is managed by a device owner. Upon receiving it: - A notification is shown. - When the user taps the notification it launches an activity with a "Accept" button. - When the user taps the button, the activity is dismissed and DPM is called to acknowledge that user accepted it. - If the user never taps the notification or for some reason the button is not tapped, the intent will be sent again the next time the user is switched to. There's still some polishing work to be done (like using the proper resource strings), but the overall workflow is done. Test: adb shell dumpsys activity service com.android.car/.PerUserCarService Test: manual verification (automated tests will be added later Bug: 175057848 Change-Id: I0063a28c5df226456da5c8abcd42d63b07dc4149
Native (C++) code format is required to be compatible with .clang-format file. Run
git clang-format --style=file --extension='h,cpp,cc' HEAD~
Note that clang-format is not desirable for Android java files. Therefore the command line above is limited to specific extensions.