diff options
author | Nancy Chen <nancychen@google.com> | 2014-08-21 22:50:11 -0700 |
---|---|---|
committer | Nancy Chen <nancychen@google.com> | 2014-08-22 16:13:05 -0700 |
commit | 105015e3b07650638e696dcf4cdeb8f4d1b14de4 (patch) | |
tree | 50b1d6e93283588de62d652e7cda4e617442e348 /src/com/android/dialer/dialpad | |
parent | 6fc974f2e8cb2bb1e084acc54dca149b6d191c6b (diff) |
API Review PhoneManager -> TelecommManager. Rename methods (1/6)
PhoneManager
- handlePinMMI docs should explain what a Pin is and what MMI is
- rename isInAPhoneCall to isInCall
- rename showCallScreen to showInCallScreen
- merge this class into TelecommManager, we don't need both
Bug: 16960458
Change-Id: I6d1939175c0292641f6ece0b630db8a864871d7e
Diffstat (limited to 'src/com/android/dialer/dialpad')
-rw-r--r-- | src/com/android/dialer/dialpad/DialpadFragment.java | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/com/android/dialer/dialpad/DialpadFragment.java b/src/com/android/dialer/dialpad/DialpadFragment.java index 84f1c64bf..141a45188 100644 --- a/src/com/android/dialer/dialpad/DialpadFragment.java +++ b/src/com/android/dialer/dialpad/DialpadFragment.java @@ -33,11 +33,11 @@ import android.media.AudioManager; import android.media.ToneGenerator; import android.net.Uri; import android.os.Bundle; -import android.phone.PhoneManager; import android.provider.Contacts.People; import android.provider.Contacts.Phones; import android.provider.Contacts.PhonesColumns; import android.provider.Settings; +import android.telecomm.TelecommManager; import android.telephony.PhoneNumberUtils; import android.telephony.PhoneStateListener; import android.telephony.TelephonyManager; @@ -213,7 +213,7 @@ public class DialpadFragment extends AnalyticsFragment * press/depress of the "hookswitch" of a landline phone. Aka "empty flash". * * TODO: Using an intent extra to tell the phone to send this flash is a - * temporary measure. To be replaced with an Telephony/PhoneManager call in the future. + * temporary measure. To be replaced with an Telephony/TelecommManager call in the future. * TODO: Keep in sync with the string defined in OutgoingCallBroadcaster.java * in Phone app until this is replaced with the Telephony/Telecomm API. */ @@ -273,8 +273,8 @@ public class DialpadFragment extends AnalyticsFragment return (TelephonyManager) getActivity().getSystemService(Context.TELEPHONY_SERVICE); } - private PhoneManager getPhoneManager() { - return (PhoneManager) getActivity().getSystemService(Context.PHONE_SERVICE); + private TelecommManager getTelecommManager() { + return (TelecommManager) getActivity().getSystemService(Context.TELECOMM_SERVICE); } @Override @@ -1384,7 +1384,7 @@ public class DialpadFragment extends AnalyticsFragment * or "return to call" from the dialpad chooser. */ private void returnToInCallScreen(boolean showDialpad) { - getPhoneManager().showCallScreen(showDialpad); + getTelecommManager().showInCallScreen(showDialpad); // Finally, finish() ourselves so that we don't stay on the // activity stack. @@ -1402,7 +1402,7 @@ public class DialpadFragment extends AnalyticsFragment * is active (ie. off hook or ringing or dialing, or on hold). */ public boolean isPhoneInUse() { - return getPhoneManager().isInAPhoneCall(); + return getTelecommManager().isInCall(); } /** |