1
0
mirror of https://github.com/yurisieucuti/treble_evolution.git synced 2024-11-24 08:36:19 +00:00
treble_evolution/patches/platform_frameworks_base/0019-TelephonyManager-add-API-annotations-for-setTelephon.patch
2024-04-24 15:13:17 +00:00

42 lines
1.6 KiB
Diff

From 432009330f5eccde819692f613b686e3c2fe62d3 Mon Sep 17 00:00:00 2001
From: Peter Cai <peter@typeblog.net>
Date: Wed, 16 Dec 2020 21:26:45 +0800
Subject: [PATCH 19/51] TelephonyManager: add API annotations for
setTelephonyProperty
* This method was added back by reverting commit
debb4616ef67f9ed5054eca51ec58592358ff55f, but they do not conform to
the new R API requirements.
* R requires such annotations.
---
telephony/java/android/telephony/TelephonyManager.java | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/telephony/java/android/telephony/TelephonyManager.java b/telephony/java/android/telephony/TelephonyManager.java
index 0cd5ab7fad20..bd5255d4a21a 100644
--- a/telephony/java/android/telephony/TelephonyManager.java
+++ b/telephony/java/android/telephony/TelephonyManager.java
@@ -8216,7 +8216,7 @@ public class TelephonyManager {
* @hide
*/
@UnsupportedAppUsage
- public static void setTelephonyProperty(int phoneId, String property, String value) {
+ public static void setTelephonyProperty(int phoneId, @NonNull String property, @Nullable String value) {
String propVal = "";
String p[] = null;
String prop = SystemProperties.get(property);
@@ -8270,7 +8270,8 @@ public class TelephonyManager {
*
* @hide
*/
- public static void setTelephonyProperty(String property, String value) {
+ @UnsupportedAppUsage
+ public static void setTelephonyProperty(@NonNull String property, @Nullable String value) {
if (value == null) {
value = "";
}
--
2.25.1