Skip to content

Commit d357082

Browse files
committed
[Android]perfect Custom Audio Source case.
1 parent 7346bde commit d357082

2 files changed

Lines changed: 4 additions & 0 deletions

File tree

Android/APIExample/app/src/main/java/io/agora/api/example/examples/advanced/customaudio/CustomAudioSource.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -238,6 +238,8 @@ public void onClick(View v) {
238238
join.setText(getString(R.string.join));
239239
mic.setEnabled(false);
240240
pcm.setEnabled(false);
241+
pcm.setChecked(false);
242+
mic.setChecked(true);
241243
if(audioPushingHelper != null){
242244
audioPushingHelper.stop();
243245
}

Android/APIExample/app/src/main/res/layout/fragment_custom_audio_source.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@
111111
android:layout_alignParentEnd="true"
112112
android:layout_alignParentBottom="true"
113113
android:checked="true"
114+
android:enabled="false"
114115
android:layout_marginEnd="16dp"
115116
android:layout_marginBottom="64dp"/>
116117

@@ -121,6 +122,7 @@
121122
android:layout_alignParentEnd="true"
122123
android:layout_alignParentBottom="true"
123124
android:layout_marginEnd="16dp"
125+
android:enabled="false"
124126
android:layout_marginBottom="110dp"
125127
android:text="@string/publish_local_audio" />
126128

0 commit comments

Comments
 (0)