Loading core/res/res/values-watch/config.xml +3 −0 Original line number Diff line number Diff line Loading @@ -51,4 +51,7 @@ <!-- Scale factor threshold used by the screen magnifier to determine when to switch from panning to scaling the magnification viewport. --> <item name="config_screen_magnification_scaling_threshold" format="float" type="dimen">0.1</item> <!-- Do not show the message saying USB is connected in charging mode. --> <bool name="config_usbChargingMessage">false</bool> </resources> core/res/res/values/config.xml +4 −1 Original line number Diff line number Diff line Loading @@ -248,7 +248,7 @@ <integer name="config_networkTransitionTimeout">60000</integer> <!-- List of regexpressions describing the interface (if any) that represent tetherable USB interfaces. If the device doesn't want to support tething over USB this should USB interfaces. If the device doesn't want to support tethering over USB this should be empty. An example would be "usb.*" --> <string-array translatable="false" name="config_tether_usb_regexs"> </string-array> Loading Loading @@ -543,6 +543,9 @@ <!-- If this is true, the screen will come on when you unplug usb/power/whatever. --> <bool name="config_unplugTurnsOnScreen">false</bool> <!-- If this is true, the message that USB is only being used for charging will be shown. --> <bool name="config_usbChargingMessage">true</bool> <!-- Set this true only if the device has separate attention and notification lights. --> <bool name="config_useAttentionLight">false</bool> Loading core/res/res/values/symbols.xml +1 −0 Original line number Diff line number Diff line Loading @@ -1633,6 +1633,7 @@ <java-symbol type="bool" name="config_enableNetworkLocationOverlay" /> <java-symbol type="bool" name="config_sf_limitedAlpha" /> <java-symbol type="bool" name="config_unplugTurnsOnScreen" /> <java-symbol type="bool" name="config_usbChargingMessage" /> <java-symbol type="bool" name="config_allowAutoBrightnessWhileDozing" /> <java-symbol type="bool" name="config_allowTheaterModeWakeFromUnplug" /> <java-symbol type="bool" name="config_allowTheaterModeWakeFromGesture" /> Loading services/usb/java/com/android/server/usb/UsbDeviceManager.java +2 −1 Original line number Diff line number Diff line Loading @@ -233,7 +233,8 @@ public class UsbDeviceManager { final StorageManager storageManager = StorageManager.from(mContext); final StorageVolume primary = storageManager.getPrimaryVolume(); massStorageSupported = primary != null && primary.allowMassStorage(); mUseUsbNotification = !massStorageSupported; mUseUsbNotification = !massStorageSupported && mContext.getResources().getBoolean( com.android.internal.R.bool.config_usbChargingMessage); // make sure the ADB_ENABLED setting value matches the current state try { Loading Loading
core/res/res/values-watch/config.xml +3 −0 Original line number Diff line number Diff line Loading @@ -51,4 +51,7 @@ <!-- Scale factor threshold used by the screen magnifier to determine when to switch from panning to scaling the magnification viewport. --> <item name="config_screen_magnification_scaling_threshold" format="float" type="dimen">0.1</item> <!-- Do not show the message saying USB is connected in charging mode. --> <bool name="config_usbChargingMessage">false</bool> </resources>
core/res/res/values/config.xml +4 −1 Original line number Diff line number Diff line Loading @@ -248,7 +248,7 @@ <integer name="config_networkTransitionTimeout">60000</integer> <!-- List of regexpressions describing the interface (if any) that represent tetherable USB interfaces. If the device doesn't want to support tething over USB this should USB interfaces. If the device doesn't want to support tethering over USB this should be empty. An example would be "usb.*" --> <string-array translatable="false" name="config_tether_usb_regexs"> </string-array> Loading Loading @@ -543,6 +543,9 @@ <!-- If this is true, the screen will come on when you unplug usb/power/whatever. --> <bool name="config_unplugTurnsOnScreen">false</bool> <!-- If this is true, the message that USB is only being used for charging will be shown. --> <bool name="config_usbChargingMessage">true</bool> <!-- Set this true only if the device has separate attention and notification lights. --> <bool name="config_useAttentionLight">false</bool> Loading
core/res/res/values/symbols.xml +1 −0 Original line number Diff line number Diff line Loading @@ -1633,6 +1633,7 @@ <java-symbol type="bool" name="config_enableNetworkLocationOverlay" /> <java-symbol type="bool" name="config_sf_limitedAlpha" /> <java-symbol type="bool" name="config_unplugTurnsOnScreen" /> <java-symbol type="bool" name="config_usbChargingMessage" /> <java-symbol type="bool" name="config_allowAutoBrightnessWhileDozing" /> <java-symbol type="bool" name="config_allowTheaterModeWakeFromUnplug" /> <java-symbol type="bool" name="config_allowTheaterModeWakeFromGesture" /> Loading
services/usb/java/com/android/server/usb/UsbDeviceManager.java +2 −1 Original line number Diff line number Diff line Loading @@ -233,7 +233,8 @@ public class UsbDeviceManager { final StorageManager storageManager = StorageManager.from(mContext); final StorageVolume primary = storageManager.getPrimaryVolume(); massStorageSupported = primary != null && primary.allowMassStorage(); mUseUsbNotification = !massStorageSupported; mUseUsbNotification = !massStorageSupported && mContext.getResources().getBoolean( com.android.internal.R.bool.config_usbChargingMessage); // make sure the ADB_ENABLED setting value matches the current state try { Loading