Expose phone account register/unregister intents.

These were previously @SystemApi.  Retaining the existing SystemAPI
behavior which sends the intents to those with a private permission.
Extending to ALSO send these intents to the default dialer app as well
using an explicit intent.
Cherry-pick from aosp-master to resolve merge conflicts.

Test: Manual
Bug: 37106957
Change-Id: Ifb72870105be5ba024af196a8c3165a9afb397ab
This commit is contained in:
Tyler Gunn
2017-04-14 13:43:30 -07:00
parent e3852d3302
commit d9da6ce993
3 changed files with 18 additions and 8 deletions

View File

@@ -39419,6 +39419,8 @@ package android.telecom {
field public static final java.lang.String ACTION_CONFIGURE_PHONE_ACCOUNT = "android.telecom.action.CONFIGURE_PHONE_ACCOUNT";
field public static final java.lang.String ACTION_DEFAULT_DIALER_CHANGED = "android.telecom.action.DEFAULT_DIALER_CHANGED";
field public static final deprecated java.lang.String ACTION_INCOMING_CALL = "android.telecom.action.INCOMING_CALL";
field public static final java.lang.String ACTION_PHONE_ACCOUNT_REGISTERED = "android.telecom.action.PHONE_ACCOUNT_REGISTERED";
field public static final java.lang.String ACTION_PHONE_ACCOUNT_UNREGISTERED = "android.telecom.action.PHONE_ACCOUNT_UNREGISTERED";
field public static final java.lang.String ACTION_SHOW_CALL_ACCESSIBILITY_SETTINGS = "android.telecom.action.SHOW_CALL_ACCESSIBILITY_SETTINGS";
field public static final java.lang.String ACTION_SHOW_CALL_SETTINGS = "android.telecom.action.SHOW_CALL_SETTINGS";
field public static final java.lang.String ACTION_SHOW_MISSED_CALLS_NOTIFICATION = "android.telecom.action.SHOW_MISSED_CALLS_NOTIFICATION";

View File

@@ -39629,6 +39629,8 @@ package android.telecom {
field public static final java.lang.String ACTION_CONFIGURE_PHONE_ACCOUNT = "android.telecom.action.CONFIGURE_PHONE_ACCOUNT";
field public static final java.lang.String ACTION_DEFAULT_DIALER_CHANGED = "android.telecom.action.DEFAULT_DIALER_CHANGED";
field public static final deprecated java.lang.String ACTION_INCOMING_CALL = "android.telecom.action.INCOMING_CALL";
field public static final java.lang.String ACTION_PHONE_ACCOUNT_REGISTERED = "android.telecom.action.PHONE_ACCOUNT_REGISTERED";
field public static final java.lang.String ACTION_PHONE_ACCOUNT_UNREGISTERED = "android.telecom.action.PHONE_ACCOUNT_UNREGISTERED";
field public static final java.lang.String ACTION_SHOW_CALL_ACCESSIBILITY_SETTINGS = "android.telecom.action.SHOW_CALL_ACCESSIBILITY_SETTINGS";
field public static final java.lang.String ACTION_SHOW_CALL_SETTINGS = "android.telecom.action.SHOW_CALL_SETTINGS";
field public static final java.lang.String ACTION_SHOW_MISSED_CALLS_NOTIFICATION = "android.telecom.action.SHOW_MISSED_CALLS_NOTIFICATION";

View File

@@ -112,20 +112,26 @@ public class TelecomManager {
"android.telecom.action.CHANGE_PHONE_ACCOUNTS";
/**
* The {@link android.content.Intent} action used indicate that a new phone account was
* just registered.
* @hide
* {@link android.content.Intent} action used indicate that a new phone account was just
* registered.
* <p>
* The Intent {@link Intent#getExtras() extras} will contain {@link #EXTRA_PHONE_ACCOUNT_HANDLE}
* to indicate which {@link PhoneAccount} was registered.
* <p>
* Will only be sent to the default dialer app (see {@link #getDefaultDialerPackage()}).
*/
@SystemApi
public static final String ACTION_PHONE_ACCOUNT_REGISTERED =
"android.telecom.action.PHONE_ACCOUNT_REGISTERED";
/**
* The {@link android.content.Intent} action used indicate that a phone account was
* just unregistered.
* @hide
* {@link android.content.Intent} action used indicate that a phone account was just
* unregistered.
* <p>
* The Intent {@link Intent#getExtras() extras} will contain {@link #EXTRA_PHONE_ACCOUNT_HANDLE}
* to indicate which {@link PhoneAccount} was unregistered.
* <p>
* Will only be sent to the default dialer app (see {@link #getDefaultDialerPackage()}).
*/
@SystemApi
public static final String ACTION_PHONE_ACCOUNT_UNREGISTERED =
"android.telecom.action.PHONE_ACCOUNT_UNREGISTERED";