diff options
author | Mike Kasick <mike@kasick.org> | 2012-12-03 22:49:13 -0500 |
---|---|---|
committer | Gerrit Code Review <gerrit@review.cyanogenmod.com> | 2012-12-07 16:28:18 -0800 |
commit | eb6cde75bcbc2782a93ffafcaf364bbb3080d342 (patch) | |
tree | 3e628f05a6159fbd65936975a51cb86687c8cea9 /telephony | |
parent | 1dde8f0d79c5b5437e097a5f36a56a8572373053 (diff) | |
download | frameworks_base-eb6cde75bcbc2782a93ffafcaf364bbb3080d342.zip frameworks_base-eb6cde75bcbc2782a93ffafcaf364bbb3080d342.tar.gz frameworks_base-eb6cde75bcbc2782a93ffafcaf364bbb3080d342.tar.bz2 |
PowerWidget: Re-enable LTE button.
- Implement toggleLTE,
from CM 10.0: I3f7521f5ec4e9f9106c58afd4d5b10c7086b55fd.
- Support all LTE network modes defined in RILConstants and
com.android.internal.telephony.Phone.
- Cleanup: Remove unused LTE_MODE, restrict state change to updateState.
- Also use Settings.Global.getInt() for PREFERRED_NETWORK_MODE.
Change-Id: I43bb2491d650d641d243d3cb67ee80bc7c8f5cdf
Diffstat (limited to 'telephony')
-rwxr-xr-x | telephony/java/android/telephony/TelephonyManager.java | 11 | ||||
-rw-r--r-- | telephony/java/com/android/internal/telephony/ITelephony.aidl | 6 |
2 files changed, 17 insertions, 0 deletions
diff --git a/telephony/java/android/telephony/TelephonyManager.java b/telephony/java/android/telephony/TelephonyManager.java index d486529..2f80d39 100755 --- a/telephony/java/android/telephony/TelephonyManager.java +++ b/telephony/java/android/telephony/TelephonyManager.java @@ -607,6 +607,17 @@ public class TelephonyManager { } } + /** + * {@hide} + */ + public void toggleLTE(boolean on) { + try { + getITelephony().toggleLTE(on); + } catch (RemoteException e) { + //Silently fail + } + } + /** Unknown network class. {@hide} */ public static final int NETWORK_CLASS_UNKNOWN = 0; /** Class of broadly defined "2G" networks. {@hide} */ diff --git a/telephony/java/com/android/internal/telephony/ITelephony.aidl b/telephony/java/com/android/internal/telephony/ITelephony.aidl index 11e01b9..9d1cc1d 100644 --- a/telephony/java/com/android/internal/telephony/ITelephony.aidl +++ b/telephony/java/com/android/internal/telephony/ITelephony.aidl @@ -45,6 +45,12 @@ interface ITelephony { void call(String number); /** + * Toggle between 3G and LTE (NT_MODE_CDMA, NT_MODE_GLOBAL) + * @param boolean to turn on and off LTE + */ + void toggleLTE(boolean on); + + /** * If there is currently a call in progress, show the call screen. * The DTMF dialpad may or may not be visible initially, depending on * whether it was up when the user last exited the InCallScreen. |