Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b9ff6752 authored by Adnan Begovic's avatar Adnan Begovic Committed by Steve Kondik
Browse files

SystemUI: Add support for persistent usb drive notification.

  This option can be enabled via config_persistUsbDriveNotification

Change-Id: I331a759aeb914e46e3ef4842896d3465d894707a
TICKET: PAELLA-225
parent 7c9c8e7e
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -56,4 +56,6 @@
    <java-symbol type="array" name="app_ops_labels" />
    <java-symbol type="string" name="status_bar_su" />

    <!-- Usb drive persistent notification -->
    <java-symbol type="bool" name="config_persistUsbDriveNotification" />
</resources>
+2 −0
Original line number Diff line number Diff line
@@ -2756,4 +2756,6 @@
    <string-array name="config_forceEnabledComponents" translatable="false">
    </string-array>

    <!-- Whether to persist the notification for when a usb drive device is plugged in -->
    <bool name="config_persistUsbDriveNotification">false</bool>
</resources>
+2 −0
Original line number Diff line number Diff line
@@ -374,6 +374,8 @@ public class StorageNotification extends SystemUI {
                            mContext.getString(R.string.ext_media_unmount_action),
                            buildUnmountPendingIntent(vol)))
                    .setContentIntent(browseIntent)
                    .setOngoing(mContext.getResources().getBoolean(
                            R.bool.config_persistUsbDriveNotification))
                    .setCategory(Notification.CATEGORY_SYSTEM)
                    .setPriority(Notification.PRIORITY_LOW);
            // Non-adoptable disks can't be snoozed.