From dab25b08b93ab3cbda6fd72cc9fa9f56795e1720 Mon Sep 17 00:00:00 2001 From: tibbi Date: Thu, 5 Nov 2020 18:31:22 +0100 Subject: [PATCH] show the Pause button on Android 7+, there is no pause before that --- .../voicerecorder/fragments/RecorderFragment.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/voicerecorder/fragments/RecorderFragment.kt b/app/src/main/kotlin/com/simplemobiletools/voicerecorder/fragments/RecorderFragment.kt index bdfc84f..d3363ba 100644 --- a/app/src/main/kotlin/com/simplemobiletools/voicerecorder/fragments/RecorderFragment.kt +++ b/app/src/main/kotlin/com/simplemobiletools/voicerecorder/fragments/RecorderFragment.kt @@ -5,6 +5,7 @@ import android.content.Intent import android.graphics.drawable.Drawable import android.util.AttributeSet import com.simplemobiletools.commons.extensions.* +import com.simplemobiletools.commons.helpers.isNougatPlus import com.simplemobiletools.voicerecorder.R import com.simplemobiletools.voicerecorder.extensions.config import com.simplemobiletools.voicerecorder.helpers.* @@ -115,7 +116,7 @@ class RecorderFragment(context: Context, attributeSet: AttributeSet) : MyViewPag fun gotStatusEvent(event: Events.RecordingStatus) { status = event.status toggle_recording_button.setImageDrawable(getToggleButtonIcon()) - toggle_pause_button.beVisibleIf(status != RECORDING_STOPPED) + toggle_pause_button.beVisibleIf(status != RECORDING_STOPPED && isNougatPlus()) if (status == RECORDING_RUNNING) { recorder_visualizer.recreate() }