|
@@ -218,6 +218,40 @@ public class AgoraModule extends ReactContextBaseJavaModule {
|
218
|
218
|
}
|
219
|
219
|
});
|
220
|
220
|
}
|
|
221
|
+
|
|
222
|
+ /**
|
|
223
|
+ * 用户mute音频回调
|
|
224
|
+ */
|
|
225
|
+ @Override
|
|
226
|
+ public void onUserMuteAudio(final int uid, boolean muted) {
|
|
227
|
+ runOnUiThread(new Runnable() {
|
|
228
|
+ @Override
|
|
229
|
+ public void run() {
|
|
230
|
+ WritableMap map = Arguments.createMap();
|
|
231
|
+ map.putString("type", "onUserMuteAudio");
|
|
232
|
+ map.putInt("uid", uid);
|
|
233
|
+ map.putBoolean("muted", muted);
|
|
234
|
+ commonEvent(map);
|
|
235
|
+ }
|
|
236
|
+ });
|
|
237
|
+ }
|
|
238
|
+
|
|
239
|
+ /**
|
|
240
|
+ * 用户mute视频回调
|
|
241
|
+ */
|
|
242
|
+ @Override
|
|
243
|
+ public void onUserMuteVideo(final int uid, boolean muted) {
|
|
244
|
+ runOnUiThread(new Runnable() {
|
|
245
|
+ @Override
|
|
246
|
+ public void run() {
|
|
247
|
+ WritableMap map = Arguments.createMap();
|
|
248
|
+ map.putString("type", "onUserMuteVideo");
|
|
249
|
+ map.putInt("uid", uid);
|
|
250
|
+ map.putBoolean("muted", muted);
|
|
251
|
+ commonEvent(map);
|
|
252
|
+ }
|
|
253
|
+ });
|
|
254
|
+ }
|
221
|
255
|
};
|
222
|
256
|
|
223
|
257
|
@ReactMethod
|