[Modify]声音签名svga实现
This commit is contained in:
@@ -265,9 +265,6 @@ dependencies {
|
|||||||
|
|
||||||
implementation 'com.github.yalantis:ucrop:2.2.7'
|
implementation 'com.github.yalantis:ucrop:2.2.7'
|
||||||
|
|
||||||
implementation 'com.github.SheTieJun.Mp3Recorder:recorder-mix:1.7.1'
|
|
||||||
implementation 'com.github.SheTieJun.Mp3Recorder:recorder-core:1.7.1'
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
channel {
|
channel {
|
||||||
|
BIN
app/src/main/assets/svga/sound_record.svga
Normal file
BIN
app/src/main/assets/svga/sound_record.svga
Normal file
Binary file not shown.
BIN
app/src/main/assets/svga/user_in_live.svga
Normal file
BIN
app/src/main/assets/svga/user_in_live.svga
Normal file
Binary file not shown.
@@ -13,6 +13,10 @@ import android.widget.Chronometer.OnChronometerTickListener
|
|||||||
import androidx.activity.viewModels
|
import androidx.activity.viewModels
|
||||||
import androidx.core.content.ContextCompat
|
import androidx.core.content.ContextCompat
|
||||||
import com.netease.nim.uikit.StatusBarUtil
|
import com.netease.nim.uikit.StatusBarUtil
|
||||||
|
import com.opensource.svgaplayer.SVGADrawable
|
||||||
|
import com.opensource.svgaplayer.SVGAImageView
|
||||||
|
import com.opensource.svgaplayer.SVGAParser
|
||||||
|
import com.opensource.svgaplayer.SVGAVideoEntity
|
||||||
import com.yizhuan.erban.R
|
import com.yizhuan.erban.R
|
||||||
import com.yizhuan.erban.audio.helper.AudioPlayerHelper
|
import com.yizhuan.erban.audio.helper.AudioPlayerHelper
|
||||||
import com.yizhuan.erban.audio.presenter.RecordingVoicePresenter
|
import com.yizhuan.erban.audio.presenter.RecordingVoicePresenter
|
||||||
@@ -238,6 +242,7 @@ class SoundSignatureActivity : BaseViewBindingActivity<ActivitySoundSignatureBin
|
|||||||
binding.groupSaveSound.visibility = View.INVISIBLE
|
binding.groupSaveSound.visibility = View.INVISIBLE
|
||||||
binding.groupDeleteSound.visibility = View.INVISIBLE
|
binding.groupDeleteSound.visibility = View.INVISIBLE
|
||||||
binding.tvUnderReview.visibility = View.INVISIBLE
|
binding.tvUnderReview.visibility = View.INVISIBLE
|
||||||
|
binding.svgRecorder.stopAnimation()
|
||||||
}
|
}
|
||||||
SoundViewModel.STATE_RECORD_RECORDING -> {
|
SoundViewModel.STATE_RECORD_RECORDING -> {
|
||||||
binding.ivSoundStatus.post { binding.ivSoundStatus.setImageResource(R.drawable.ic_start_record) }
|
binding.ivSoundStatus.post { binding.ivSoundStatus.setImageResource(R.drawable.ic_start_record) }
|
||||||
@@ -246,6 +251,7 @@ class SoundSignatureActivity : BaseViewBindingActivity<ActivitySoundSignatureBin
|
|||||||
binding.groupSaveSound.visibility = View.INVISIBLE
|
binding.groupSaveSound.visibility = View.INVISIBLE
|
||||||
binding.groupDeleteSound.visibility = View.INVISIBLE
|
binding.groupDeleteSound.visibility = View.INVISIBLE
|
||||||
binding.tvUnderReview.visibility = View.INVISIBLE
|
binding.tvUnderReview.visibility = View.INVISIBLE
|
||||||
|
playSvgaBg(binding.svgRecorder,"svga/sound_record.svga")
|
||||||
}
|
}
|
||||||
SoundViewModel.STATE_RECORD_SUCCESS -> {
|
SoundViewModel.STATE_RECORD_SUCCESS -> {
|
||||||
binding.ivSoundStatus.post { binding.ivSoundStatus.setImageResource(R.drawable.ic_pause_record) }
|
binding.ivSoundStatus.post { binding.ivSoundStatus.setImageResource(R.drawable.ic_pause_record) }
|
||||||
@@ -254,6 +260,7 @@ class SoundSignatureActivity : BaseViewBindingActivity<ActivitySoundSignatureBin
|
|||||||
binding.groupSaveSound.visibility = View.VISIBLE
|
binding.groupSaveSound.visibility = View.VISIBLE
|
||||||
binding.groupDeleteSound.visibility = View.INVISIBLE
|
binding.groupDeleteSound.visibility = View.INVISIBLE
|
||||||
binding.tvUnderReview.visibility = View.INVISIBLE
|
binding.tvUnderReview.visibility = View.INVISIBLE
|
||||||
|
binding.svgRecorder.stopAnimation()
|
||||||
}
|
}
|
||||||
SoundViewModel.STATE_RECORD_SAVE_SUCCESS -> {
|
SoundViewModel.STATE_RECORD_SAVE_SUCCESS -> {
|
||||||
binding.ivSoundStatus.post { binding.ivSoundStatus.setImageResource(R.drawable.ic_pause_record) }
|
binding.ivSoundStatus.post { binding.ivSoundStatus.setImageResource(R.drawable.ic_pause_record) }
|
||||||
@@ -262,10 +269,26 @@ class SoundSignatureActivity : BaseViewBindingActivity<ActivitySoundSignatureBin
|
|||||||
binding.groupSaveSound.visibility = View.INVISIBLE
|
binding.groupSaveSound.visibility = View.INVISIBLE
|
||||||
binding.groupDeleteSound.visibility = View.VISIBLE
|
binding.groupDeleteSound.visibility = View.VISIBLE
|
||||||
binding.tvUnderReview.visibility = View.VISIBLE
|
binding.tvUnderReview.visibility = View.VISIBLE
|
||||||
|
binding.svgRecorder.stopAnimation()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private fun playSvgaBg(svgaBg: SVGAImageView, assets: String) {
|
||||||
|
val mSVGAParser = SVGAParser(svgaBg.context)
|
||||||
|
mSVGAParser.decodeFromAssets(assets, object : SVGAParser.ParseCompletion {
|
||||||
|
override fun onComplete(videoItem: SVGAVideoEntity) {
|
||||||
|
val drawable = SVGADrawable(videoItem)
|
||||||
|
svgaBg.setImageDrawable(drawable)
|
||||||
|
svgaBg.stepToFrame(0, true)
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onError() {
|
||||||
|
}
|
||||||
|
|
||||||
|
},null)
|
||||||
|
}
|
||||||
|
|
||||||
private fun startChronometer() {
|
private fun startChronometer() {
|
||||||
binding.tvSoundTime.onChronometerTickListener =
|
binding.tvSoundTime.onChronometerTickListener =
|
||||||
OnChronometerTickListener { chronometer: Chronometer ->
|
OnChronometerTickListener { chronometer: Chronometer ->
|
||||||
@@ -300,6 +323,11 @@ class SoundSignatureActivity : BaseViewBindingActivity<ActivitySoundSignatureBin
|
|||||||
binding.ivSoundStatus.post {
|
binding.ivSoundStatus.post {
|
||||||
if (isPlaying) binding.ivSoundStatus.setImageResource(R.drawable.ic_resume_record)
|
if (isPlaying) binding.ivSoundStatus.setImageResource(R.drawable.ic_resume_record)
|
||||||
else binding.ivSoundStatus.setImageResource(R.drawable.ic_pause_record)
|
else binding.ivSoundStatus.setImageResource(R.drawable.ic_pause_record)
|
||||||
|
if(isPlaying){
|
||||||
|
playSvgaBg(binding.svgRecorder,"svga/sound_record.svga")
|
||||||
|
}else{
|
||||||
|
binding.svgRecorder.stopAnimation()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -336,6 +364,8 @@ class SoundSignatureActivity : BaseViewBindingActivity<ActivitySoundSignatureBin
|
|||||||
override fun onDestroy() {
|
override fun onDestroy() {
|
||||||
super.onDestroy()
|
super.onDestroy()
|
||||||
soundViewModel.releaseResource()
|
soundViewModel.releaseResource()
|
||||||
|
binding.svgRecorder.stopAnimation()
|
||||||
|
binding.svgRecorder.clear()
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun needSteepStateBar(): Boolean {
|
override fun needSteepStateBar(): Boolean {
|
||||||
|
@@ -25,6 +25,10 @@ import com.netease.nim.uikit.StatusBarUtil;
|
|||||||
import com.netease.nim.uikit.impl.cache.NimUserInfoCache;
|
import com.netease.nim.uikit.impl.cache.NimUserInfoCache;
|
||||||
import com.netease.nimlib.sdk.RequestCallbackWrapper;
|
import com.netease.nimlib.sdk.RequestCallbackWrapper;
|
||||||
import com.netease.nimlib.sdk.uinfo.model.NimUserInfo;
|
import com.netease.nimlib.sdk.uinfo.model.NimUserInfo;
|
||||||
|
import com.opensource.svgaplayer.SVGADrawable;
|
||||||
|
import com.opensource.svgaplayer.SVGAImageView;
|
||||||
|
import com.opensource.svgaplayer.SVGAParser;
|
||||||
|
import com.opensource.svgaplayer.SVGAVideoEntity;
|
||||||
import com.yizhuan.erban.R;
|
import com.yizhuan.erban.R;
|
||||||
import com.yizhuan.erban.UIHelper;
|
import com.yizhuan.erban.UIHelper;
|
||||||
import com.yizhuan.erban.audio.helper.AudioPlayerHelper;
|
import com.yizhuan.erban.audio.helper.AudioPlayerHelper;
|
||||||
@@ -91,6 +95,8 @@ import java.util.ArrayList;
|
|||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
import lombok.val;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* create by lvzebiao on 2018/8/31
|
* create by lvzebiao on 2018/8/31
|
||||||
*/
|
*/
|
||||||
@@ -190,7 +196,29 @@ public class UserInfoActivity extends BaseBindingActivity<ActivityUserInfoBindin
|
|||||||
* 找到TA, 主态不展示
|
* 找到TA, 主态不展示
|
||||||
*/
|
*/
|
||||||
private void setWhereVisible() {
|
private void setWhereVisible() {
|
||||||
mBinding.groupLive.setVisibility(viewModel.getMRoomUid() != 0 ? View.VISIBLE : View.GONE);
|
if(AuthModel.get().getCurrentUid() != userId && viewModel.getMRoomUid() != 0){
|
||||||
|
mBinding.groupLive.setVisibility(View.VISIBLE);
|
||||||
|
playSvgaBg(mBinding.svgLive,"svga/user_in_live.svga");
|
||||||
|
}else {
|
||||||
|
mBinding.groupLive.setVisibility(View.GONE);
|
||||||
|
mBinding.svgLive.stopAnimation();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static void playSvgaBg(SVGAImageView svgaRoomBg, String asstets) {
|
||||||
|
SVGAParser mSVGAParser = new SVGAParser(svgaRoomBg.getContext());
|
||||||
|
mSVGAParser.decodeFromAssets(asstets, new SVGAParser.ParseCompletion() {
|
||||||
|
@Override
|
||||||
|
public void onComplete(SVGAVideoEntity svgaVideoEntity) {
|
||||||
|
SVGADrawable drawable = new SVGADrawable(svgaVideoEntity);
|
||||||
|
svgaRoomBg.setImageDrawable(drawable);
|
||||||
|
svgaRoomBg.stepToFrame(0, true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onError() {
|
||||||
|
}
|
||||||
|
}, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void initViewPager() {
|
private void initViewPager() {
|
||||||
|
BIN
app/src/main/res/drawable-xhdpi/ic_live.webp
Normal file
BIN
app/src/main/res/drawable-xhdpi/ic_live.webp
Normal file
Binary file not shown.
After Width: | Height: | Size: 178 B |
@@ -7,18 +7,83 @@
|
|||||||
android:background="@color/white"
|
android:background="@color/white"
|
||||||
tools:context=".audio.SoundSignatureActivity">
|
tools:context=".audio.SoundSignatureActivity">
|
||||||
|
|
||||||
|
<Chronometer
|
||||||
|
android:id="@+id/tvSoundTime"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="@dimen/dp_30"
|
||||||
|
android:textColor="@color/text_title_color"
|
||||||
|
android:textSize="14sp"
|
||||||
|
app:layout_constraintEnd_toEndOf="@+id/ivSoundTranscribe"
|
||||||
|
app:layout_constraintStart_toStartOf="@+id/ivSoundTranscribe"
|
||||||
|
app:layout_constraintTop_toBottomOf="@+id/ivSoundTranscribe" />
|
||||||
|
|
||||||
|
<FrameLayout
|
||||||
|
android:id="@+id/frRestartBg"
|
||||||
|
android:layout_width="42dp"
|
||||||
|
android:layout_height="42dp"
|
||||||
|
android:layout_marginTop="@dimen/dp_16"
|
||||||
|
android:background="@drawable/bg_ffffff_r360"
|
||||||
|
android:elevation="1dp"
|
||||||
|
app:layout_constraintEnd_toStartOf="@+id/frPlayBg"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toTopOf="@+id/frPlayBg">
|
||||||
|
|
||||||
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
|
android:id="@+id/ivRestartRecord"
|
||||||
|
android:layout_width="@dimen/dp_18"
|
||||||
|
android:layout_height="@dimen/dp_18"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
android:src="@drawable/ic_restart_record" />
|
||||||
|
|
||||||
|
</FrameLayout>
|
||||||
|
|
||||||
|
<androidx.cardview.widget.CardView
|
||||||
|
android:id="@+id/frPlayBg"
|
||||||
|
android:layout_width="64dp"
|
||||||
|
android:layout_height="64dp"
|
||||||
|
app:cardCornerRadius="360dp"
|
||||||
|
app:cardBackgroundColor="@color/color_white"
|
||||||
|
app:cardElevation="10dp"
|
||||||
|
app:layout_constraintBottom_toTopOf="@+id/tvRecordTip"
|
||||||
|
app:layout_constraintEnd_toEndOf="@+id/ivSoundTranscribe"
|
||||||
|
app:layout_constraintStart_toStartOf="@+id/ivSoundTranscribe"
|
||||||
|
app:layout_constraintTop_toBottomOf="@+id/tvTip"
|
||||||
|
app:layout_constraintVertical_chainStyle="packed">
|
||||||
|
|
||||||
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
|
android:id="@+id/ivSoundStatus"
|
||||||
|
android:layout_width="@dimen/dp_28"
|
||||||
|
android:layout_height="@dimen/dp_28"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
android:src="@drawable/ic_prepare_record" />
|
||||||
|
|
||||||
|
</androidx.cardview.widget.CardView>
|
||||||
|
|
||||||
|
<FrameLayout
|
||||||
|
android:id="@+id/frDeleteBg"
|
||||||
|
android:layout_width="42dp"
|
||||||
|
android:layout_height="42dp"
|
||||||
|
android:background="@drawable/bg_ffffff_r360"
|
||||||
|
android:elevation="1dp"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@+id/ivSaveRecord"
|
||||||
|
app:layout_constraintEnd_toEndOf="@+id/ivSaveRecord"
|
||||||
|
app:layout_constraintStart_toStartOf="@+id/ivSaveRecord"
|
||||||
|
app:layout_constraintTop_toTopOf="@+id/ivSaveRecord">
|
||||||
|
|
||||||
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
|
android:layout_width="@dimen/dp_18"
|
||||||
|
android:layout_height="@dimen/dp_18"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
android:src="@drawable/ic_delete_sound" />
|
||||||
|
|
||||||
|
</FrameLayout>
|
||||||
|
|
||||||
<View
|
<View
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="0dp"
|
android:layout_height="0dp"
|
||||||
android:background="@drawable/bg_gradient_dbe3fc_f2f1ff"
|
android:background="@drawable/bg_gradient_dbe3fc_f2f1ff"
|
||||||
app:layout_constraintDimensionRatio="1.74:1"
|
app:layout_constraintDimensionRatio="1.74:1"
|
||||||
app:layout_constraintTop_toTopOf="parent"/>
|
|
||||||
|
|
||||||
<com.yizhuan.erban.base.TitleBar
|
|
||||||
android:id="@+id/title_bar"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginTop="@dimen/dp_30"
|
|
||||||
app:layout_constraintTop_toTopOf="parent" />
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
@@ -31,26 +96,15 @@
|
|||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/title_bar" />
|
app:layout_constraintTop_toBottomOf="@+id/title_bar" />
|
||||||
|
|
||||||
<com.opensource.svgaplayer.SVGAImageView
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
android:id="@+id/svgRecorder"
|
android:id="@+id/ivSaveRecord"
|
||||||
android:layout_width="110dp"
|
android:layout_width="42dp"
|
||||||
android:layout_height="110dp"
|
android:layout_height="42dp"
|
||||||
app:layout_constraintBottom_toBottomOf="@+id/ivSoundTranscribe"
|
android:layout_marginTop="@dimen/dp_16"
|
||||||
app:layout_constraintEnd_toEndOf="@+id/ivSoundTranscribe"
|
android:src="@drawable/ic_save_record"
|
||||||
app:layout_constraintStart_toStartOf="@+id/ivSoundTranscribe"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="@+id/ivSoundTranscribe"
|
app:layout_constraintStart_toEndOf="@+id/frPlayBg"
|
||||||
android:src="@drawable/ic_sound_record" />
|
app:layout_constraintTop_toTopOf="@+id/frPlayBg" />
|
||||||
|
|
||||||
<Chronometer
|
|
||||||
android:id="@+id/tvSoundTime"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginTop="@dimen/dp_30"
|
|
||||||
android:textColor="@color/text_title_color"
|
|
||||||
android:textSize="14sp"
|
|
||||||
app:layout_constraintEnd_toEndOf="@+id/ivSoundTranscribe"
|
|
||||||
app:layout_constraintStart_toStartOf="@+id/ivSoundTranscribe"
|
|
||||||
app:layout_constraintTop_toBottomOf="@+id/ivSoundTranscribe" />
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/tvTip"
|
android:id="@+id/tvTip"
|
||||||
@@ -64,155 +118,104 @@
|
|||||||
app:layout_constraintStart_toStartOf="@+id/ivSoundTranscribe"
|
app:layout_constraintStart_toStartOf="@+id/ivSoundTranscribe"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/tvSoundTime" />
|
app:layout_constraintTop_toBottomOf="@+id/tvSoundTime" />
|
||||||
|
|
||||||
<FrameLayout
|
|
||||||
android:id="@+id/frRestartBg"
|
|
||||||
android:background="@drawable/bg_ffffff_r360"
|
|
||||||
android:layout_width="42dp"
|
|
||||||
android:layout_height="42dp"
|
|
||||||
android:elevation="1dp"
|
|
||||||
android:layout_marginTop="@dimen/dp_16"
|
|
||||||
app:layout_constraintTop_toTopOf="@+id/frPlayBg"
|
|
||||||
app:layout_constraintEnd_toStartOf="@+id/frPlayBg"
|
|
||||||
app:layout_constraintStart_toStartOf="parent">
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
|
||||||
android:id="@+id/ivRestartRecord"
|
|
||||||
android:layout_width="@dimen/dp_18"
|
|
||||||
android:layout_height="@dimen/dp_18"
|
|
||||||
android:layout_gravity="center"
|
|
||||||
android:src="@drawable/ic_restart_record" />
|
|
||||||
|
|
||||||
</FrameLayout>
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/tvRsRecord"
|
android:id="@+id/tvRsRecord"
|
||||||
android:text="@string/restart_record"
|
|
||||||
android:textSize="@dimen/sp_12"
|
|
||||||
android:textColor="@color/color_6D6B89"
|
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="@dimen/dp_10"
|
android:layout_marginTop="@dimen/dp_10"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/frRestartBg"
|
android:text="@string/restart_record"
|
||||||
|
android:textColor="@color/color_6D6B89"
|
||||||
|
android:textSize="@dimen/sp_12"
|
||||||
|
app:layout_constraintEnd_toEndOf="@+id/frRestartBg"
|
||||||
app:layout_constraintStart_toStartOf="@+id/frRestartBg"
|
app:layout_constraintStart_toStartOf="@+id/frRestartBg"
|
||||||
app:layout_constraintEnd_toEndOf="@+id/frRestartBg"/>
|
app:layout_constraintTop_toBottomOf="@+id/frRestartBg" />
|
||||||
|
|
||||||
<FrameLayout
|
|
||||||
android:id="@+id/frPlayBg"
|
|
||||||
android:background="@drawable/bg_ffffff_r360"
|
|
||||||
android:layout_width="64dp"
|
|
||||||
android:layout_height="64dp"
|
|
||||||
android:elevation="1dp"
|
|
||||||
app:layout_constraintVertical_chainStyle="packed"
|
|
||||||
app:layout_constraintEnd_toEndOf="@+id/ivSoundTranscribe"
|
|
||||||
app:layout_constraintStart_toStartOf="@+id/ivSoundTranscribe"
|
|
||||||
app:layout_constraintTop_toBottomOf="@+id/tvTip"
|
|
||||||
app:layout_constraintBottom_toTopOf="@+id/tvRecordTip">
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
|
||||||
android:id="@+id/ivSoundStatus"
|
|
||||||
android:layout_width="@dimen/dp_28"
|
|
||||||
android:layout_height="@dimen/dp_28"
|
|
||||||
android:layout_gravity="center"
|
|
||||||
android:src="@drawable/ic_prepare_record" />
|
|
||||||
|
|
||||||
</FrameLayout>
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/tvRecordTip"
|
android:id="@+id/tvRecordTip"
|
||||||
android:text="@string/start_record"
|
|
||||||
android:textSize="@dimen/sp_14"
|
|
||||||
android:textColor="@color/color_6D6B89"
|
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="@dimen/dp_15"
|
android:layout_marginTop="@dimen/dp_15"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/frPlayBg"
|
android:text="@string/start_record"
|
||||||
|
android:textColor="@color/color_6D6B89"
|
||||||
|
android:textSize="@dimen/sp_14"
|
||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="@+id/frPlayBg"
|
||||||
app:layout_constraintStart_toStartOf="@+id/frPlayBg"
|
app:layout_constraintStart_toStartOf="@+id/frPlayBg"
|
||||||
app:layout_constraintEnd_toEndOf="@+id/frPlayBg"/>
|
app:layout_constraintTop_toBottomOf="@+id/frPlayBg" />
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
|
||||||
android:id="@+id/ivSaveRecord"
|
|
||||||
android:src="@drawable/ic_save_record"
|
|
||||||
android:layout_width="42dp"
|
|
||||||
android:layout_height="42dp"
|
|
||||||
android:layout_marginTop="@dimen/dp_16"
|
|
||||||
app:layout_constraintTop_toTopOf="@+id/frPlayBg"
|
|
||||||
app:layout_constraintStart_toEndOf="@+id/frPlayBg"
|
|
||||||
app:layout_constraintEnd_toEndOf="parent"/>
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/tvSaveSound"
|
android:id="@+id/tvSaveSound"
|
||||||
android:text="@string/save_record"
|
|
||||||
android:textSize="@dimen/sp_12"
|
|
||||||
android:textColor="@color/color_6D6B89"
|
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="@dimen/dp_10"
|
android:layout_marginTop="@dimen/dp_10"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/ivSaveRecord"
|
android:text="@string/save_record"
|
||||||
app:layout_constraintStart_toStartOf="@+id/ivSaveRecord"
|
android:textColor="@color/color_6D6B89"
|
||||||
app:layout_constraintEnd_toEndOf="@+id/ivSaveRecord"/>
|
android:textSize="@dimen/sp_12"
|
||||||
|
|
||||||
<FrameLayout
|
|
||||||
android:id="@+id/frDeleteBg"
|
|
||||||
android:background="@drawable/bg_ffffff_r360"
|
|
||||||
android:layout_width="42dp"
|
|
||||||
android:layout_height="42dp"
|
|
||||||
android:elevation="1dp"
|
|
||||||
app:layout_constraintEnd_toEndOf="@+id/ivSaveRecord"
|
app:layout_constraintEnd_toEndOf="@+id/ivSaveRecord"
|
||||||
app:layout_constraintStart_toStartOf="@+id/ivSaveRecord"
|
app:layout_constraintStart_toStartOf="@+id/ivSaveRecord"
|
||||||
app:layout_constraintTop_toTopOf="@+id/ivSaveRecord"
|
app:layout_constraintTop_toBottomOf="@+id/ivSaveRecord" />
|
||||||
app:layout_constraintBottom_toBottomOf="@+id/ivSaveRecord">
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
|
||||||
android:layout_width="@dimen/dp_18"
|
|
||||||
android:layout_height="@dimen/dp_18"
|
|
||||||
android:layout_gravity="center"
|
|
||||||
android:src="@drawable/ic_delete_sound" />
|
|
||||||
|
|
||||||
</FrameLayout>
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/tvDeleteSound"
|
android:id="@+id/tvDeleteSound"
|
||||||
android:text="@string/delete_sound"
|
|
||||||
android:textSize="@dimen/sp_12"
|
|
||||||
android:textColor="@color/color_6D6B89"
|
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginTop="@dimen/dp_10"
|
android:layout_marginTop="@dimen/dp_10"
|
||||||
app:layout_constraintStart_toStartOf="@+id/frDeleteBg"
|
android:text="@string/delete_sound"
|
||||||
|
android:textColor="@color/color_6D6B89"
|
||||||
|
android:textSize="@dimen/sp_12"
|
||||||
app:layout_constraintEnd_toEndOf="@+id/frDeleteBg"
|
app:layout_constraintEnd_toEndOf="@+id/frDeleteBg"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/frDeleteBg"/>
|
app:layout_constraintStart_toStartOf="@+id/frDeleteBg"
|
||||||
|
app:layout_constraintTop_toBottomOf="@+id/frDeleteBg" />
|
||||||
|
|
||||||
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
|
android:id="@+id/tvUnderReview"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="@string/sound_audit_in_progress"
|
||||||
|
android:visibility="invisible"
|
||||||
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toBottomOf="@+id/tvRecordTip" />
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.Group
|
<androidx.constraintlayout.widget.Group
|
||||||
android:id="@+id/groupRsRecord"
|
android:id="@+id/groupRsRecord"
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
android:visibility="gone"
|
||||||
app:constraint_referenced_ids="frRestartBg,tvRsRecord" />
|
app:constraint_referenced_ids="frRestartBg,tvRsRecord" />
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.Group
|
<androidx.constraintlayout.widget.Group
|
||||||
android:id="@+id/groupSaveSound"
|
android:id="@+id/groupSaveSound"
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
android:visibility="gone"
|
||||||
app:constraint_referenced_ids="ivSaveRecord,tvSaveSound" />
|
app:constraint_referenced_ids="ivSaveRecord,tvSaveSound" />
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.Group
|
<androidx.constraintlayout.widget.Group
|
||||||
android:id="@+id/groupDeleteSound"
|
android:id="@+id/groupDeleteSound"
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
|
android:visibility="gone"
|
||||||
app:constraint_referenced_ids="frDeleteBg,tvDeleteSound" />
|
app:constraint_referenced_ids="frDeleteBg,tvDeleteSound" />
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<com.opensource.svgaplayer.SVGAImageView
|
||||||
android:id="@+id/tvUnderReview"
|
android:id="@+id/svgRecorder"
|
||||||
android:text="@string/sound_audit_in_progress"
|
android:layout_width="110dp"
|
||||||
android:layout_width="wrap_content"
|
android:layout_height="110dp"
|
||||||
|
android:scaleType="centerCrop"
|
||||||
|
android:src="@drawable/ic_sound_record"
|
||||||
|
app:autoPlay="true"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@+id/ivSoundTranscribe"
|
||||||
|
app:layout_constraintEnd_toEndOf="@+id/ivSoundTranscribe"
|
||||||
|
app:layout_constraintStart_toStartOf="@+id/ivSoundTranscribe"
|
||||||
|
app:layout_constraintTop_toTopOf="@+id/ivSoundTranscribe" />
|
||||||
|
|
||||||
|
<com.yizhuan.erban.base.TitleBar
|
||||||
|
android:id="@+id/title_bar"
|
||||||
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:visibility="invisible"
|
android:layout_marginTop="@dimen/dp_30"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintTop_toTopOf="parent" />
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
|
||||||
app:layout_constraintTop_toBottomOf="@+id/tvRecordTip"
|
|
||||||
app:layout_constraintBottom_toBottomOf="parent"/>
|
|
||||||
|
|
||||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
@@ -112,16 +112,29 @@
|
|||||||
app:layout_constraintEnd_toEndOf="@+id/iv_user_head"
|
app:layout_constraintEnd_toEndOf="@+id/iv_user_head"
|
||||||
app:layout_constraintStart_toStartOf="@+id/iv_user_head" />
|
app:layout_constraintStart_toStartOf="@+id/iv_user_head" />
|
||||||
|
|
||||||
|
<com.opensource.svgaplayer.SVGAImageView
|
||||||
|
android:id="@+id/svgLive"
|
||||||
|
app:autoPlay="true"
|
||||||
|
app:clearsAfterDetached="true"
|
||||||
|
android:layout_width="@dimen/dp_12"
|
||||||
|
android:layout_height="@dimen/dp_12"
|
||||||
|
android:src="@drawable/ic_live"
|
||||||
|
app:layout_constraintHorizontal_chainStyle="packed"
|
||||||
|
app:layout_constraintStart_toStartOf="@+id/viewLive"
|
||||||
|
app:layout_constraintEnd_toStartOf="@+id/tvLive"
|
||||||
|
app:layout_constraintTop_toTopOf="@+id/viewLive"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@+id/viewLive"/>
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/tvLive"
|
android:id="@+id/tvLive"
|
||||||
android:text="@string/me_in_live"
|
android:text="@string/me_in_live"
|
||||||
android:textSize="@dimen/sp_11"
|
android:textSize="@dimen/sp_10"
|
||||||
android:textColor="@color/white"
|
android:textColor="@color/white"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
app:layout_constraintTop_toTopOf="@+id/viewLive"
|
app:layout_constraintTop_toTopOf="@+id/viewLive"
|
||||||
app:layout_constraintBottom_toBottomOf="@+id/viewLive"
|
app:layout_constraintBottom_toBottomOf="@+id/viewLive"
|
||||||
app:layout_constraintStart_toStartOf="@+id/viewLive"
|
app:layout_constraintStart_toEndOf="@+id/svgLive"
|
||||||
app:layout_constraintEnd_toEndOf="@+id/viewLive"/>
|
app:layout_constraintEnd_toEndOf="@+id/viewLive"/>
|
||||||
|
|
||||||
<androidx.constraintlayout.widget.Group
|
<androidx.constraintlayout.widget.Group
|
||||||
@@ -129,7 +142,7 @@
|
|||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
app:constraint_referenced_ids="viewLive,tvLive" />
|
app:constraint_referenced_ids="viewLive,tvLive,svgLive" />
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/iv_vip_icon"
|
android:id="@+id/iv_vip_icon"
|
||||||
|
Reference in New Issue
Block a user