Replace UserRestriction listener with an intent
Because Bluetooth is going mainline, we need to remove call to hidden API. UserManagerInternal and UserRestrictionsListener are hidden. There is a available Intent: ACTION_USER_RESTRICTIONS_CHANGED to advertise when we need to ask for the new restriction Using both registerReceiverForAllUsers and getSendingUser allow us to retrieve the user it was intended for Bug: 211851706 Test: Build + start bt Tag: #refactor Change-Id: I4924c4a1cc1388015aa1f9b0ab2c47b470d93871
Loading
Please register or sign in to comment