1:修改音域我的,底部更多的布局
2:修改歌手认证展示
This commit is contained in:
@@ -242,6 +242,18 @@ public class SingerVerificationActivity extends BaseMvpActivity<SingerVerificati
|
||||
mBinding.playButton.setText("试听");
|
||||
mBinding.playButton.setCompoundDrawablesWithIntrinsicBounds(0, R.mipmap.but_st, 0, 0);
|
||||
} else {
|
||||
// 检查录音文件是否存在
|
||||
if (recordingFile == null || !recordingFile.exists()) {
|
||||
Toast.makeText(SingerVerificationActivity.this, "没有录制的文件", Toast.LENGTH_SHORT).show();
|
||||
return;
|
||||
}
|
||||
|
||||
// 检查录音时长
|
||||
if (recordingDuration <= 0) {
|
||||
Toast.makeText(SingerVerificationActivity.this, "没有可试听的内容", Toast.LENGTH_SHORT).show();
|
||||
return;
|
||||
}
|
||||
|
||||
// 未播放,点击开始播放
|
||||
startPlaying();
|
||||
// 更改按钮状态为"结束"
|
||||
@@ -480,18 +492,9 @@ public class SingerVerificationActivity extends BaseMvpActivity<SingerVerificati
|
||||
recordingFile = recordingSegments.get(0);
|
||||
}
|
||||
|
||||
if (recordingFile == null || !recordingFile.exists()) {
|
||||
Toast.makeText(this, "没有录制的文件", Toast.LENGTH_SHORT).show();
|
||||
return;
|
||||
}
|
||||
|
||||
// 移除试听时间限制,允许试听任何长度的录音
|
||||
if (recordingDuration <= 0) {
|
||||
Toast.makeText(this, "没有可试听的内容", Toast.LENGTH_SHORT).show();
|
||||
mBinding.playButton.setText("试听");
|
||||
mBinding.playButton.setCompoundDrawablesWithIntrinsicBounds(0, R.mipmap.but_st, 0, 0);
|
||||
return;
|
||||
}
|
||||
// 这些检查已经在点击事件中完成,这里不再需要重复检查
|
||||
// 如果需要保留日志记录,可以添加:
|
||||
LogUtils.d("SingerVerification", "开始播放录音文件: " + recordingFile.getAbsolutePath() + ", 时长: " + recordingDuration + "ms");
|
||||
|
||||
try {
|
||||
stopRecording();
|
||||
|
||||
Reference in New Issue
Block a user