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

Commit f43ff474 authored by Wenyi Wang's avatar Wenyi Wang
Browse files

Modify play method to handle silent ringtone

Bug: 12800232
Change-Id: I4ab30c04e0c38c58c9bd04222cea730b4aaaecec
parent 04eba18d
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -59,6 +59,10 @@ class AsyncRingtonePlayer {
    /** Plays the ringtone. */
    void play(Uri ringtone) {
        Log.d(this, "Posting play.");
        if (ringtone == Uri.EMPTY) {
            Log.i(this, "Uri.EMPTY (silence -- not playing anything)");
            return;
        }
        postMessage(EVENT_PLAY, true /* shouldCreateHandler */, ringtone);
    }