Merge "Remove usage of TelecomManager.from() hidden API"
This commit is contained in:
committed by
Gerrit Code Review
commit
07235288eb
@@ -8832,7 +8832,10 @@ public class TelephonyManager {
|
||||
@Deprecated
|
||||
public boolean isTtyModeSupported() {
|
||||
try {
|
||||
TelecomManager telecomManager = TelecomManager.from(mContext);
|
||||
TelecomManager telecomManager = null;
|
||||
if (mContext != null) {
|
||||
telecomManager = mContext.getSystemService(TelecomManager.class);
|
||||
}
|
||||
if (telecomManager != null) {
|
||||
return telecomManager.isTtySupported();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user