Add 6 GHz Wifi band to Wifi Network Details

Display 6 GHz for the frequency pref in Wifi Network Details
when connected to a 6 GHz network.

Bug: 184170532
Test: build
Change-Id: I7d10fe0e4c95e6f0ec66c3a179c3c46828eeb545
This commit is contained in:
Quang Luong
2021-06-07 11:27:22 -07:00
parent ada75fbe7e
commit 1c7ba38627
3 changed files with 11 additions and 4 deletions

View File

@@ -16,7 +16,6 @@
package com.android.settings.wifi;
import android.app.Activity;
import android.content.ComponentName;
import android.content.Context;
import android.content.Intent;
@@ -35,7 +34,6 @@ import android.net.wifi.WifiEnterpriseConfig.Eap;
import android.net.wifi.WifiEnterpriseConfig.Phase2;
import android.net.wifi.WifiManager;
import android.os.IBinder;
import android.os.UserHandle;
import android.security.keystore.KeyProperties;
import android.telephony.SubscriptionInfo;
import android.telephony.SubscriptionManager;
@@ -402,6 +400,9 @@ public class WifiConfigController2 implements TextWatcher,
} else if (frequency >= WifiEntry.MIN_FREQ_5GHZ
&& frequency < WifiEntry.MAX_FREQ_5GHZ) {
band = res.getString(R.string.wifi_band_5ghz);
} else if (frequency >= WifiEntry.MIN_FREQ_6GHZ
&& frequency < WifiEntry.MAX_FREQ_6GHZ) {
band = res.getString(R.string.wifi_band_6ghz);
} else {
Log.e(TAG, "Unexpected frequency " + frequency);
}