Loading services/usb/java/com/android/server/usb/UsbDeviceManager.java +2 −1 Original line number Diff line number Diff line Loading @@ -540,7 +540,8 @@ public class UsbDeviceManager implements ActivityTaskManagerInternal.ScreenObser // We do not show the USB notification if the primary volume supports mass storage. // The legacy mass storage UI will be used instead. final StorageManager storageManager = StorageManager.from(mContext); final StorageVolume primary = storageManager.getPrimaryVolume(); final StorageVolume primary = storageManager != null ? storageManager.getPrimaryVolume() : null; boolean massStorageSupported = primary != null && primary.allowMassStorage(); mUseUsbNotification = !massStorageSupported && mContext.getResources().getBoolean( Loading Loading
services/usb/java/com/android/server/usb/UsbDeviceManager.java +2 −1 Original line number Diff line number Diff line Loading @@ -540,7 +540,8 @@ public class UsbDeviceManager implements ActivityTaskManagerInternal.ScreenObser // We do not show the USB notification if the primary volume supports mass storage. // The legacy mass storage UI will be used instead. final StorageManager storageManager = StorageManager.from(mContext); final StorageVolume primary = storageManager.getPrimaryVolume(); final StorageVolume primary = storageManager != null ? storageManager.getPrimaryVolume() : null; boolean massStorageSupported = primary != null && primary.allowMassStorage(); mUseUsbNotification = !massStorageSupported && mContext.getResources().getBoolean( Loading