summaryrefslogtreecommitdiffstats
path: root/wifi/java
diff options
context:
space:
mode:
authorVinit Deshpande <vinitd@google.com>2015-03-09 19:01:37 -0700
committerVinit Deshpande <vinitd@google.com>2015-03-09 19:01:37 -0700
commite95944300eccf78a871fbfaf0545c7550ab424a5 (patch)
tree3dee50d88f1814f211864d0efc41ce34c8ac1720 /wifi/java
parent14a2008f63367a68235ae1602ef2e17eb4a2c053 (diff)
parentb938c0e2036d28df24ec626fc8ed7e277248b9a6 (diff)
downloadframeworks_base-e95944300eccf78a871fbfaf0545c7550ab424a5.zip
frameworks_base-e95944300eccf78a871fbfaf0545c7550ab424a5.tar.gz
frameworks_base-e95944300eccf78a871fbfaf0545c7550ab424a5.tar.bz2
am "Do not provide 5GHz option for softap if there is no country code available"
merged from partner/m-wireless-wifi-dev b938c0e Do not provide 5GHz option for softap if there is no country code available
Diffstat (limited to 'wifi/java')
-rw-r--r--wifi/java/android/net/wifi/IWifiManager.aidl2
-rw-r--r--wifi/java/android/net/wifi/WifiManager.java15
2 files changed, 17 insertions, 0 deletions
diff --git a/wifi/java/android/net/wifi/IWifiManager.aidl b/wifi/java/android/net/wifi/IWifiManager.aidl
index b87a1e9..bc95a36 100644
--- a/wifi/java/android/net/wifi/IWifiManager.aidl
+++ b/wifi/java/android/net/wifi/IWifiManager.aidl
@@ -79,6 +79,8 @@ interface IWifiManager
void setCountryCode(String country, boolean persist);
+ String getCountryCode();
+
void setFrequencyBand(int band, boolean persist);
int getFrequencyBand();
diff --git a/wifi/java/android/net/wifi/WifiManager.java b/wifi/java/android/net/wifi/WifiManager.java
index b001bb8..40d40bb 100644
--- a/wifi/java/android/net/wifi/WifiManager.java
+++ b/wifi/java/android/net/wifi/WifiManager.java
@@ -1238,6 +1238,21 @@ public class WifiManager {
}
/**
+ * get the country code.
+ * @return the country code in ISO 3166 format.
+ *
+ * @hide
+ */
+ public String getCountryCode() {
+ try {
+ String country = mService.getCountryCode();
+ return(country);
+ } catch (RemoteException e) {
+ return null;
+ }
+ }
+
+ /**
* Set the operational frequency band.
* @param band One of
* {@link #WIFI_FREQUENCY_BAND_AUTO},