Prechádzať zdrojové kódy

去掉几处震动提醒,修改紧急呼叫无响应按钮问题

weizhengliang 2 rokov pred
rodič
commit
f15bf05f4b

+ 3 - 2
home/src/main/code/com/wdkl/ncs/android/component/home/adapter/NewEventItemAdapter.kt

@@ -83,11 +83,12 @@ class NewEventItemAdapter(var data:ArrayList<InteractionVO>, val activity: Activ
                 intent.putExtra(VoiceMsgActivity.TO_DEVICE_ID,toDeviceId)
                 activity.startActivity(intent)
             }*/
+            binding.eliEventResponse.visibility = View.GONE
 
             when (itemData.actionType){
                 TcpType.EVENT.name->{
                     binding.eliImRead.visibility = View.GONE
-                    binding.eliEventResponse.visibility = View.GONE
+                    binding.eliEventResponse.visibility = View.VISIBLE
                     binding.eliEventName.text = itemData.data
                     if (itemData.actionEnd!=null){
                         binding.eliEventResponse.visibility = View.GONE
@@ -157,7 +158,7 @@ class NewEventItemAdapter(var data:ArrayList<InteractionVO>, val activity: Activ
                     binding.eliMemberName.text = ""
                     binding.eliEventName.setTextColor(activity.resources.getColor(R.color.warn_orange))
                     binding.eliImRead.visibility = View.GONE
-                    binding.eliEventResponse.visibility = View.GONE
+                    binding.eliEventResponse.visibility = View.VISIBLE
                     binding.eliEventName.text = "SOS"
 //                    binding.eliEventName.setBackgroundResource(R.drawable.sos_96)
                     if (itemData.actionEnd!=null){

+ 2 - 2
home/src/main/code/com/wdkl/ncs/android/component/home/service/WdKeepAliveService.kt

@@ -486,7 +486,7 @@ class WdKeepAliveService : AbsWorkService() {
                     //语音播报处理
                     eventSpeechOut(tcpModel)
                     //震动提醒
-                    handleVibrator()
+                    //handleVibrator()
 
                     val interactionVO = Gson().fromJson(tcpModel.data.toString(), InteractionVO::class.java)
                     if (Constants.oldEvent) {
@@ -517,7 +517,7 @@ class WdKeepAliveService : AbsWorkService() {
                     //语音播报处理
                     eventSpeechOut(tcpModel)
                     //震动提醒
-                    handleVibrator()
+                    //handleVibrator()
                     //消除事件
                     val interactionVO = Gson().fromJson(tcpModel.data.toString(), InteractionVO::class.java)
                     var iterator = Constants.eventList.iterator()

+ 2 - 2
home/src/main/code/com/wdkl/ncs/android/component/home/ui/CallSingleActivity.java

@@ -270,12 +270,12 @@ public class CallSingleActivity extends AppCompatActivity {
 
             //MediaPlayHelper.getInstance().playResMusic(R.raw.incoming_call, 1.0f, true);
             //RingPlayHelper.playRingTone(this, R.raw.incoming_call, true);
-            long[] pattern = new long[]{100L, 2000L, 1000L, 2000L, 1000L, 2000L};
+            /*long[] pattern = new long[]{100L, 2000L, 1000L, 2000L, 1000L, 2000L};
             if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.O) {
                 mVibrator.vibrate(VibrationEffect.createWaveform(pattern, 0));
             } else {
                 mVibrator.vibrate(pattern, 0);
-            }
+            }*/
         }
 
         // 6,处理 publishers,每个publisher 包含 id (feedId) 和 display,attach 到发布者的 handler 上,准备接收视频流,每个发布者都要 attach 一遍,然后协商 sdp, SFU,subscribeAttach 到发布者的 handle 上 [janusClient.subscribeAttach(feedId)]。将publisher 放到Room对象中的publishers, 在 janusClient.subscribeAttach(feedId) 中回调 videoRoomCallback.onSubscribeAttached