Loading src/com/android/server/telecom/TelecomServiceImpl.java +14 −1 Original line number Diff line number Diff line Loading @@ -320,7 +320,7 @@ public class TelecomServiceImpl { Intent intent = new Intent(TelecomManager.ACTION_PHONE_ACCOUNT_REGISTERED); intent.putExtra(TelecomManager.EXTRA_PHONE_ACCOUNT_HANDLE, account.getAccountHandle()); Log.i(this, "Sending phone-account intent as user"); Log.i(this, "Sending phone-account unregistered intent as user"); mContext.sendBroadcastAsUser(intent, UserHandle.ALL, PERMISSION_PROCESS_PHONE_ACCOUNT_REGISTRATION); } finally { Loading @@ -341,6 +341,19 @@ public class TelecomServiceImpl { accountHandle.getComponentName().getPackageName()); enforceUserHandleMatchesCaller(accountHandle); mPhoneAccountRegistrar.unregisterPhoneAccount(accountHandle); // Broadcast an intent indicating the phone account which was unregistered. long token = Binder.clearCallingIdentity(); try { Intent intent = new Intent(TelecomManager.ACTION_PHONE_ACCOUNT_UNREGISTERED); intent.putExtra(TelecomManager.EXTRA_PHONE_ACCOUNT_HANDLE, accountHandle); Log.i(this, "Sending phone-account registered intent as user"); mContext.sendBroadcastAsUser(intent, UserHandle.ALL, PERMISSION_PROCESS_PHONE_ACCOUNT_REGISTRATION); } finally { Binder.restoreCallingIdentity(token); } } catch (Exception e) { Log.e(this, e, "unregisterPhoneAccount %s", accountHandle); throw e; Loading Loading
src/com/android/server/telecom/TelecomServiceImpl.java +14 −1 Original line number Diff line number Diff line Loading @@ -320,7 +320,7 @@ public class TelecomServiceImpl { Intent intent = new Intent(TelecomManager.ACTION_PHONE_ACCOUNT_REGISTERED); intent.putExtra(TelecomManager.EXTRA_PHONE_ACCOUNT_HANDLE, account.getAccountHandle()); Log.i(this, "Sending phone-account intent as user"); Log.i(this, "Sending phone-account unregistered intent as user"); mContext.sendBroadcastAsUser(intent, UserHandle.ALL, PERMISSION_PROCESS_PHONE_ACCOUNT_REGISTRATION); } finally { Loading @@ -341,6 +341,19 @@ public class TelecomServiceImpl { accountHandle.getComponentName().getPackageName()); enforceUserHandleMatchesCaller(accountHandle); mPhoneAccountRegistrar.unregisterPhoneAccount(accountHandle); // Broadcast an intent indicating the phone account which was unregistered. long token = Binder.clearCallingIdentity(); try { Intent intent = new Intent(TelecomManager.ACTION_PHONE_ACCOUNT_UNREGISTERED); intent.putExtra(TelecomManager.EXTRA_PHONE_ACCOUNT_HANDLE, accountHandle); Log.i(this, "Sending phone-account registered intent as user"); mContext.sendBroadcastAsUser(intent, UserHandle.ALL, PERMISSION_PROCESS_PHONE_ACCOUNT_REGISTRATION); } finally { Binder.restoreCallingIdentity(token); } } catch (Exception e) { Log.e(this, e, "unregisterPhoneAccount %s", accountHandle); throw e; Loading