Merge "Add telecom command to stop block suppression" into rvc-dev
This commit is contained in:
@@ -68,6 +68,8 @@ public final class Telecom extends BaseCommand {
|
|||||||
private static final String COMMAND_UNREGISTER_PHONE_ACCOUNT = "unregister-phone-account";
|
private static final String COMMAND_UNREGISTER_PHONE_ACCOUNT = "unregister-phone-account";
|
||||||
private static final String COMMAND_SET_DEFAULT_DIALER = "set-default-dialer";
|
private static final String COMMAND_SET_DEFAULT_DIALER = "set-default-dialer";
|
||||||
private static final String COMMAND_GET_DEFAULT_DIALER = "get-default-dialer";
|
private static final String COMMAND_GET_DEFAULT_DIALER = "get-default-dialer";
|
||||||
|
private static final String COMMAND_STOP_BLOCK_SUPPRESSION = "stop-block-suppression";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Change the system dialer package name if a package name was specified,
|
* Change the system dialer package name if a package name was specified,
|
||||||
* Example: adb shell telecom set-system-dialer <PACKAGE>
|
* Example: adb shell telecom set-system-dialer <PACKAGE>
|
||||||
@@ -115,6 +117,8 @@ public final class Telecom extends BaseCommand {
|
|||||||
+ "usage: telecom set-sim-count <COUNT>\n"
|
+ "usage: telecom set-sim-count <COUNT>\n"
|
||||||
+ "usage: telecom get-sim-config\n"
|
+ "usage: telecom get-sim-config\n"
|
||||||
+ "usage: telecom get-max-phones\n"
|
+ "usage: telecom get-max-phones\n"
|
||||||
|
+ "usage: telecom stop-block-suppression: Stop suppressing the blocked number"
|
||||||
|
+ " provider after a call to emergency services.\n"
|
||||||
+ "usage: telecom set-emer-phone-account-filter <PACKAGE>\n"
|
+ "usage: telecom set-emer-phone-account-filter <PACKAGE>\n"
|
||||||
+ "\n"
|
+ "\n"
|
||||||
+ "telecom set-phone-account-enabled: Enables the given phone account, if it has"
|
+ "telecom set-phone-account-enabled: Enables the given phone account, if it has"
|
||||||
@@ -207,6 +211,9 @@ public final class Telecom extends BaseCommand {
|
|||||||
case COMMAND_UNREGISTER_PHONE_ACCOUNT:
|
case COMMAND_UNREGISTER_PHONE_ACCOUNT:
|
||||||
runUnregisterPhoneAccount();
|
runUnregisterPhoneAccount();
|
||||||
break;
|
break;
|
||||||
|
case COMMAND_STOP_BLOCK_SUPPRESSION:
|
||||||
|
runStopBlockSuppression();
|
||||||
|
break;
|
||||||
case COMMAND_SET_DEFAULT_DIALER:
|
case COMMAND_SET_DEFAULT_DIALER:
|
||||||
runSetDefaultDialer();
|
runSetDefaultDialer();
|
||||||
break;
|
break;
|
||||||
@@ -324,8 +331,13 @@ public final class Telecom extends BaseCommand {
|
|||||||
System.out.println("Success - " + handle + " unregistered.");
|
System.out.println("Success - " + handle + " unregistered.");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void runStopBlockSuppression() throws RemoteException {
|
||||||
|
mTelecomService.stopBlockSuppression();
|
||||||
|
}
|
||||||
|
|
||||||
private void runSetDefaultDialer() throws RemoteException {
|
private void runSetDefaultDialer() throws RemoteException {
|
||||||
final String packageName = nextArgRequired();
|
String packageName = nextArg();
|
||||||
|
if ("default".equals(packageName)) packageName = null;
|
||||||
mTelecomService.setTestDefaultDialer(packageName);
|
mTelecomService.setTestDefaultDialer(packageName);
|
||||||
System.out.println("Success - " + packageName + " set as override default dialer.");
|
System.out.println("Success - " + packageName + " set as override default dialer.");
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -276,6 +276,11 @@ interface ITelecomService {
|
|||||||
*/
|
*/
|
||||||
boolean setDefaultDialer(in String packageName);
|
boolean setDefaultDialer(in String packageName);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Stop suppressing blocked numbers after a call to emergency services. Shell only.
|
||||||
|
*/
|
||||||
|
void stopBlockSuppression();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @see TelecomServiceImpl#createManageBlockedNumbersIntent
|
* @see TelecomServiceImpl#createManageBlockedNumbersIntent
|
||||||
**/
|
**/
|
||||||
|
|||||||
Reference in New Issue
Block a user