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

Commit a69487e3 authored by 2bllw8's avatar 2bllw8 Committed by luca020400
Browse files

Recorder: set appropriate notification title

Change-Id: I5b13f12ccd05bfdba45447f3ba03529ec4e7af91
parent f57c1460
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -448,7 +448,6 @@ public class SoundRecorderService extends Service {
        String duration = DateUtils.formatElapsedTime(elapsedTime);
        NotificationCompat.Builder nb = new NotificationCompat.Builder(this, NOTIFICATION_CHANNEL)
                .setOngoing(true)
                .setContentTitle(getString(R.string.sound_notification_title))
                .setContentText(getString(R.string.sound_notification_message, duration))
                .setSmallIcon(R.drawable.ic_notification_sound)
                .setColor(ContextCompat.getColor(this, R.color.colorAccent))
@@ -459,12 +458,14 @@ public class SoundRecorderService extends Service {
                    new Intent(this, SoundRecorderService.class)
                            .setAction(ACTION_RESUME),
                    PendingIntent.FLAG_IMMUTABLE);
            nb.setContentTitle(getString(R.string.sound_recording_title_paused));
            nb.addAction(R.drawable.ic_resume, getString(R.string.resume), resumePIntent);
        } else {
            PendingIntent pausePIntent = PendingIntent.getService(this, 0,
                    new Intent(this, SoundRecorderService.class)
                            .setAction(ACTION_PAUSE),
                    PendingIntent.FLAG_IMMUTABLE);
            nb.setContentTitle(getString(R.string.sound_recording_title_working));
            nb.addAction(R.drawable.ic_pause, getString(R.string.pause), pausePIntent);
        }
        nb.addAction(R.drawable.ic_stop, getString(R.string.stop), stopPIntent);