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

Commit bcb854ee authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "Update Volume state for Unmounting Phase."

parents 1839fb7c 4e9ce287
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -679,6 +679,14 @@ public class Environment {
     */
    public static final String MEDIA_UNMOUNTABLE = "unmountable";

    /**
     * Storage state if the media is present and in unmounting state.
     *
     * @see #getStorageState(File)
     * @hide
     */
    public static final String MEDIA_UNMOUNTING = "unmounting";

    /**
     * Returns the current state of the primary "external" storage device.
     * 
+1 −0
Original line number Diff line number Diff line
@@ -951,6 +951,7 @@ class MountService extends IMountService.Stub
            action = Intent.ACTION_MEDIA_MOUNTED;
        } else if (newState == VolumeState.Unmounting) {
            action = Intent.ACTION_MEDIA_EJECT;
            updatePublicVolumeState(volume, Environment.MEDIA_UNMOUNTING);
        } else if (newState == VolumeState.Formatting) {
        } else if (newState == VolumeState.Shared) {
            if (DEBUG_EVENTS) Slog.i(TAG, "Updating volume state media mounted");