From 807737ddf3667c12a0e358480eb7ca6989782a66 Mon Sep 17 00:00:00 2001 From: Alexey Kuznetsov Date: Fri, 16 Jun 2017 19:23:17 +0300 Subject: [PATCH] fix double tap --- app/build.gradle | 2 +- .../axet/audiorecorder/activities/RecordingActivity.java | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/app/build.gradle b/app/build.gradle index 8270b99..598fffe 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -43,5 +43,5 @@ android { dependencies { compile fileTree(dir: 'libs', include: ['*.jar']) testCompile 'junit:junit:4.12' - compile 'com.github.axet:android-audio-library:0.0.53' // compile project(':android-audio-library') + compile 'com.github.axet:android-audio-library:0.0.54' // compile project(':android-audio-library') } diff --git a/app/src/main/java/com/github/axet/audiorecorder/activities/RecordingActivity.java b/app/src/main/java/com/github/axet/audiorecorder/activities/RecordingActivity.java index 2152572..613af6e 100644 --- a/app/src/main/java/com/github/axet/audiorecorder/activities/RecordingActivity.java +++ b/app/src/main/java/com/github/axet/audiorecorder/activities/RecordingActivity.java @@ -222,7 +222,8 @@ public class RecordingActivity extends AppCompatActivity { done.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { - done.setClickable(false); + if (encoder != null) + return; stopRecording(getString(R.string.encoding)); try { encoding(new Runnable() { @@ -800,7 +801,7 @@ public class RecordingActivity extends AppCompatActivity { RecordingService.startService(this, targetFile.getName(), thread != null, encoder != null); final ProgressDialog d = new ProgressDialog(this); - d.setTitle(getString(R.string.encoding_title)); + d.setTitle(R.string.encoding_title); d.setMessage(".../" + targetFile.getName()); d.setMax(100); d.setCancelable(false);