Merge changes from topic 'mwd-merge-040115'
* changes: Merge (manually) pag/209446: Increase allowed duration to connect to HOGP profile Merge commit 'd91f193' into merge2 Merge commit '5718646' into merge2 Merge commit '7aa0345' into merge2
This commit is contained in:
@@ -18802,6 +18802,7 @@ package android.net.wifi {
|
||||
|
||||
public static final class WifiEnterpriseConfig.Eap {
|
||||
field public static final int AKA = 5; // 0x5
|
||||
field public static final int AKA_PRIME = 6; // 0x6
|
||||
field public static final int NONE = -1; // 0xffffffff
|
||||
field public static final int PEAP = 0; // 0x0
|
||||
field public static final int PWD = 3; // 0x3
|
||||
|
||||
@@ -6333,6 +6333,7 @@ package android.bluetooth {
|
||||
method public android.bluetooth.BluetoothDevice getRemoteDevice(byte[]);
|
||||
method public int getScanMode();
|
||||
method public int getState();
|
||||
method public boolean isBleScanAlwaysAvailable();
|
||||
method public boolean isDiscovering();
|
||||
method public boolean isEnabled();
|
||||
method public boolean isMultipleAdvertisementSupported();
|
||||
@@ -6349,6 +6350,7 @@ package android.bluetooth {
|
||||
field public static final java.lang.String ACTION_DISCOVERY_FINISHED = "android.bluetooth.adapter.action.DISCOVERY_FINISHED";
|
||||
field public static final java.lang.String ACTION_DISCOVERY_STARTED = "android.bluetooth.adapter.action.DISCOVERY_STARTED";
|
||||
field public static final java.lang.String ACTION_LOCAL_NAME_CHANGED = "android.bluetooth.adapter.action.LOCAL_NAME_CHANGED";
|
||||
field public static final java.lang.String ACTION_REQUEST_BLE_SCAN_ALWAYS_AVAILABLE = "android.bluetooth.adapter.action.REQUEST_BLE_SCAN_ALWAYS_AVAILABLE";
|
||||
field public static final java.lang.String ACTION_REQUEST_DISCOVERABLE = "android.bluetooth.adapter.action.REQUEST_DISCOVERABLE";
|
||||
field public static final java.lang.String ACTION_REQUEST_ENABLE = "android.bluetooth.adapter.action.REQUEST_ENABLE";
|
||||
field public static final java.lang.String ACTION_SCAN_MODE_CHANGED = "android.bluetooth.adapter.action.SCAN_MODE_CHANGED";
|
||||
@@ -20499,6 +20501,7 @@ package android.net.wifi {
|
||||
|
||||
public static final class WifiEnterpriseConfig.Eap {
|
||||
field public static final int AKA = 5; // 0x5
|
||||
field public static final int AKA_PRIME = 6; // 0x6
|
||||
field public static final int NONE = -1; // 0xffffffff
|
||||
field public static final int PEAP = 0; // 0x0
|
||||
field public static final int PWD = 3; // 0x3
|
||||
|
||||
@@ -18,6 +18,7 @@ package android.bluetooth;
|
||||
|
||||
import android.annotation.SdkConstant;
|
||||
import android.annotation.SdkConstant.SdkConstantType;
|
||||
import android.annotation.SystemApi;
|
||||
import android.bluetooth.le.BluetoothLeAdvertiser;
|
||||
import android.bluetooth.le.BluetoothLeScanner;
|
||||
import android.bluetooth.le.ScanCallback;
|
||||
@@ -205,6 +206,23 @@ public final class BluetoothAdapter {
|
||||
public static final String ACTION_REQUEST_ENABLE =
|
||||
"android.bluetooth.adapter.action.REQUEST_ENABLE";
|
||||
|
||||
/**
|
||||
* Activity Action: Show a system activity that allows user to enable BLE scans even when
|
||||
* Bluetooth is turned off.<p>
|
||||
*
|
||||
* Notification of result of this activity is posted using
|
||||
* {@link android.app.Activity#onActivityResult}. The <code>resultCode</code> will be
|
||||
* {@link android.app.Activity#RESULT_OK} if BLE scan always available setting is turned on or
|
||||
* {@link android.app.Activity#RESULT_CANCELED} if the user has rejected the request or an
|
||||
* error occurred.
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
@SystemApi
|
||||
@SdkConstant(SdkConstantType.ACTIVITY_INTENT_ACTION)
|
||||
public static final String ACTION_REQUEST_BLE_SCAN_ALWAYS_AVAILABLE =
|
||||
"android.bluetooth.adapter.action.REQUEST_BLE_SCAN_ALWAYS_AVAILABLE";
|
||||
|
||||
/**
|
||||
* Broadcast Action: Indicates the Bluetooth scan mode of the local Adapter
|
||||
* has changed.
|
||||
@@ -915,6 +933,22 @@ public final class BluetoothAdapter {
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns {@code true} if BLE scan is always available, {@code false} otherwise. <p>
|
||||
*
|
||||
* If this returns {@code true}, application can issue {@link BluetoothLeScanner#startScan} and
|
||||
* fetch scan results even when Bluetooth is turned off.<p>
|
||||
*
|
||||
* To change this setting, use {@link #ACTION_REQUEST_BLE_SCAN_ALWAYS_AVAILABLE}.
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
@SystemApi
|
||||
public boolean isBleScanAlwaysAvailable() {
|
||||
// TODO: implement after Settings UI change.
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns whether peripheral mode is supported.
|
||||
*
|
||||
|
||||
@@ -6374,6 +6374,14 @@ public final class Settings {
|
||||
public static final String WIFI_SCAN_ALWAYS_AVAILABLE =
|
||||
"wifi_scan_always_enabled";
|
||||
|
||||
/**
|
||||
* Settings to allow BLE scans to be enabled even when Bluetooth is turned off for
|
||||
* connectivity.
|
||||
* @hide
|
||||
*/
|
||||
public static final String BLE_SCAN_ALWAYS_AVAILABLE =
|
||||
"ble_scan_always_enabled";
|
||||
|
||||
/**
|
||||
* Used to save the Wifi_ON state prior to tethering.
|
||||
* This state will be checked to restore Wifi after
|
||||
|
||||
@@ -25,9 +25,13 @@
|
||||
<string-array name="wfcOperatorErrorCodes" translatable="false">
|
||||
<item>REG09</item>
|
||||
</string-array>
|
||||
<!-- WFC Operator Error Messages -->
|
||||
<string-array name="wfcOperatorErrorMessages">
|
||||
<item>Wi-Fi Calling isn\'t available. Contact your carrier to enable Wi-Fi Calling.</item>
|
||||
<!-- WFC Operator Error Messages showed as alerts -->
|
||||
<string-array name="wfcOperatorErrorAlertMessages">
|
||||
<item>To make calls and send messages over Wi-Fi, first ask your carrier to set up this service. Then turn on Wi-Fi calling again from Settings.</item>
|
||||
</string-array>
|
||||
<!-- WFC Operator Error Messages showed as notifications -->
|
||||
<string-array name="wfcOperatorErrorNotificationMessages">
|
||||
<item>Register with your carrier</item>
|
||||
</string-array>
|
||||
<!-- Template for showing cellular network operator name while WFC is active -->
|
||||
<string name="wfcSpnFormat">%s Wi-Fi Calling</string>
|
||||
|
||||
@@ -471,6 +471,18 @@
|
||||
<!-- Wifi driver supports batched scan -->
|
||||
<bool translatable="false" name="config_wifi_batched_scan_supported">false</bool>
|
||||
|
||||
<!-- Idle Receive current for wifi radio. 0 by default-->
|
||||
<integer translatable="false" name="config_wifi_idle_receive_cur_ma">1</integer>
|
||||
|
||||
<!-- Rx current for wifi radio. 0 by default-->
|
||||
<integer translatable="false" name="config_wifi_active_rx_cur_ma">2</integer>
|
||||
|
||||
<!-- Tx current for wifi radio. 0 by default-->
|
||||
<integer translatable="false" name="config_wifi_tx_cur_ma">3</integer>
|
||||
|
||||
<!-- Operating volatage for wifi radio. 0 by default-->
|
||||
<integer translatable="false" name="config_wifi_operating_voltage_mv">4</integer>
|
||||
|
||||
<!-- Flag indicating whether the we should enable the automatic brightness in Settings.
|
||||
Software implementation will be used if config_hardware_auto_brightness_available is not set -->
|
||||
<bool name="config_automatic_brightness_available">false</bool>
|
||||
|
||||
@@ -249,10 +249,20 @@
|
||||
<string name="wfcRegErrorTitle">Wi-Fi Calling</string>
|
||||
<!-- WFC Operator Error Codes -->
|
||||
<string-array name="wfcOperatorErrorCodes" translatable="false" />
|
||||
<!-- WFC Operator Error Messages -->
|
||||
<string-array name="wfcOperatorErrorMessages" />
|
||||
<!-- WFC Operator Error Messages showed as alerts -->
|
||||
<string-array name="wfcOperatorErrorAlertMessages" />
|
||||
<!-- WFC Operator Error Messages showed as notifications -->
|
||||
<string-array name="wfcOperatorErrorNotificationMessages" />
|
||||
<!-- Template for showing cellular network operator name while WFC is active -->
|
||||
<string name="wfcSpnFormat">%s</string>
|
||||
<!-- WFC, summary for Disabled -->
|
||||
<string name="wifi_calling_off_summary">Off</string>
|
||||
<!-- WFC, summary for Wi-Fi Preferred -->
|
||||
<string name="wfc_mode_wifi_preferred_summary">Wi-Fi preferred</string>
|
||||
<!-- WFC, summary for Cellular Preferred -->
|
||||
<string name="wfc_mode_cellular_preferred_summary">Cellular preferred</string>
|
||||
<!-- WFC, summary for Wi-Fi Only -->
|
||||
<string name="wfc_mode_wifi_only_summary">Wi-Fi only</string>
|
||||
|
||||
<!--
|
||||
{0} is one of "bearerServiceCode*"
|
||||
|
||||
@@ -328,6 +328,10 @@
|
||||
<java-symbol type="integer" name="config_wifi_framework_current_network_boost" />
|
||||
<java-symbol type="string" name="config_wifi_random_mac_oui" />
|
||||
<java-symbol type="integer" name="config_wifi_network_switching_blacklist_time" />
|
||||
<java-symbol type="integer" name="config_wifi_idle_receive_cur_ma" />
|
||||
<java-symbol type="integer" name="config_wifi_active_rx_cur_ma" />
|
||||
<java-symbol type="integer" name="config_wifi_tx_cur_ma" />
|
||||
<java-symbol type="integer" name="config_wifi_operating_voltage_mv" />
|
||||
|
||||
<java-symbol type="bool" name="editable_voicemailnumber" />
|
||||
|
||||
@@ -759,8 +763,13 @@
|
||||
<java-symbol type="string" name="phoneTypeWorkPager" />
|
||||
<java-symbol type="string" name="wfcRegErrorTitle" />
|
||||
<java-symbol type="array" name="wfcOperatorErrorCodes" />
|
||||
<java-symbol type="array" name="wfcOperatorErrorMessages" />
|
||||
<java-symbol type="array" name="wfcOperatorErrorAlertMessages" />
|
||||
<java-symbol type="array" name="wfcOperatorErrorNotificationMessages" />
|
||||
<java-symbol type="string" name="wfcSpnFormat" />
|
||||
<java-symbol type="string" name="wifi_calling_off_summary" />
|
||||
<java-symbol type="string" name="wfc_mode_wifi_preferred_summary" />
|
||||
<java-symbol type="string" name="wfc_mode_cellular_preferred_summary" />
|
||||
<java-symbol type="string" name="wfc_mode_wifi_only_summary" />
|
||||
<java-symbol type="string" name="policydesc_disableCamera" />
|
||||
<java-symbol type="string" name="policydesc_encryptedStorage" />
|
||||
<java-symbol type="string" name="policydesc_expirePassword" />
|
||||
|
||||
@@ -104,6 +104,7 @@ public final class CachedBluetoothDevice implements Comparable<CachedBluetoothDe
|
||||
|
||||
// See mConnectAttempted
|
||||
private static final long MAX_UUID_DELAY_FOR_AUTO_CONNECT = 5000;
|
||||
private static final long MAX_HOGP_DELAY_FOR_AUTO_CONNECT = 30000;
|
||||
|
||||
/** Auto-connect after pairing only if locally initiated. */
|
||||
private boolean mConnectAfterPairing;
|
||||
@@ -525,9 +526,11 @@ public final class CachedBluetoothDevice implements Comparable<CachedBluetoothDe
|
||||
*/
|
||||
void onUuidChanged() {
|
||||
updateProfiles();
|
||||
ParcelUuid[] uuids = mDevice.getUuids();
|
||||
long timeout = MAX_UUID_DELAY_FOR_AUTO_CONNECT;
|
||||
|
||||
if (DEBUG) {
|
||||
Log.e(TAG, "onUuidChanged: Time since last connect"
|
||||
Log.d(TAG, "onUuidChanged: Time since last connect"
|
||||
+ (SystemClock.elapsedRealtime() - mConnectAttempted));
|
||||
}
|
||||
|
||||
@@ -535,9 +538,11 @@ public final class CachedBluetoothDevice implements Comparable<CachedBluetoothDe
|
||||
* If a connect was attempted earlier without any UUID, we will do the
|
||||
* connect now.
|
||||
*/
|
||||
if (BluetoothUuid.isUuidPresent(uuids, BluetoothUuid.Hogp)) {
|
||||
timeout = MAX_HOGP_DELAY_FOR_AUTO_CONNECT;
|
||||
}
|
||||
if (!mProfiles.isEmpty()
|
||||
&& (mConnectAttempted + MAX_UUID_DELAY_FOR_AUTO_CONNECT) > SystemClock
|
||||
.elapsedRealtime()) {
|
||||
&& (mConnectAttempted + timeout) > SystemClock.elapsedRealtime()) {
|
||||
connectWithoutResettingTimer(false);
|
||||
}
|
||||
dispatchAttributesChanged();
|
||||
|
||||
@@ -270,7 +270,7 @@ public class ImsCallProfile implements Parcelable {
|
||||
return "{ serviceType=" + mServiceType +
|
||||
", callType=" + mCallType +
|
||||
", restrictCause=" + mRestrictCause +
|
||||
", callExtras=" + mCallExtras.toString() +
|
||||
//", callExtras=" + mCallExtras.toString() +
|
||||
", mediaProfile=" + mMediaProfile.toString() + " }";
|
||||
}
|
||||
|
||||
|
||||
@@ -79,12 +79,13 @@ interface IImsUt {
|
||||
/**
|
||||
* Updates the configuration of the call forward.
|
||||
*/
|
||||
int updateCallForward(int action, int condition, String number, int timeSeconds);
|
||||
int updateCallForward(int action, int condition, String number,
|
||||
int serviceClass, int timeSeconds);
|
||||
|
||||
/**
|
||||
* Updates the configuration of the call waiting.
|
||||
*/
|
||||
int updateCallWaiting(boolean enable);
|
||||
int updateCallWaiting(boolean enable, int serviceClass);
|
||||
|
||||
/**
|
||||
* Updates the configuration of the CLIR supplementary service.
|
||||
|
||||
@@ -141,6 +141,7 @@ public final class WifiActivityEnergyInfo implements Parcelable {
|
||||
return (int)mControllerIdleTimeMs;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* product of current(mA), voltage(V) and time(ms)
|
||||
* @return energy used
|
||||
|
||||
@@ -235,8 +235,10 @@ public class WifiEnterpriseConfig implements Parcelable {
|
||||
public static final int SIM = 4;
|
||||
/** EAP-Authentication and Key Agreement */
|
||||
public static final int AKA = 5;
|
||||
/** EAP-Authentication and Key Agreement Prime */
|
||||
public static final int AKA_PRIME = 6;
|
||||
/** @hide */
|
||||
public static final String[] strings = { "PEAP", "TLS", "TTLS", "PWD", "SIM", "AKA" };
|
||||
public static final String[] strings = { "PEAP", "TLS", "TTLS", "PWD", "SIM", "AKA", "AKA'" };
|
||||
|
||||
/** Prevent initialization */
|
||||
private Eap() {}
|
||||
@@ -286,6 +288,7 @@ public class WifiEnterpriseConfig implements Parcelable {
|
||||
case Eap.TTLS:
|
||||
case Eap.SIM:
|
||||
case Eap.AKA:
|
||||
case Eap.AKA_PRIME:
|
||||
mFields.put(EAP_KEY, Eap.strings[eapMethod]);
|
||||
mFields.put(OPP_KEY_CACHING, "1");
|
||||
break;
|
||||
|
||||
@@ -861,6 +861,14 @@ public class WifiManager {
|
||||
public static final int WIFI_FEATURE_TDLS_OFFCHANNEL = 0x2000; // Support for TDLS off channel
|
||||
/** @hide */
|
||||
public static final int WIFI_FEATURE_EPR = 0x4000; // Enhanced power reporting
|
||||
/** @hide */
|
||||
public static final int WIFI_FEATURE_AP_STA = 0x8000; // Support for AP STA Concurrency
|
||||
/** @hide */
|
||||
public static final int WIFI_FEATURE_LINK_LAYER_STATS = 0x10000; // Link layer stats collection
|
||||
/** @hide */
|
||||
public static final int WIFI_FEATURE_LOGGER = 0x20000; // WiFi Logger
|
||||
/** @hide */
|
||||
public static final int WIFI_FEATURE_HAL_EPNO = 0x40000; // WiFi PNO enhanced
|
||||
|
||||
private int getSupportedFeatures() {
|
||||
try {
|
||||
@@ -972,7 +980,7 @@ public class WifiManager {
|
||||
* @return true if this adapter supports advanced power/performance counters
|
||||
*/
|
||||
public boolean isEnhancedPowerReportingSupported() {
|
||||
return isFeatureSupported(WIFI_FEATURE_EPR);
|
||||
return isFeatureSupported(WIFI_FEATURE_LINK_LAYER_STATS);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user