Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
YDL-Component-Medical
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
杨凯
YDL-Component-Medical
Commits
2fb167a1
Commit
2fb167a1
authored
Aug 10, 2022
by
YKai
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 修复倾诉挂断延迟执行问题
parent
cebfc34e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
9 deletions
+14
-9
AudioHomeActivity.kt
m-audioim/src/main/java/com/ydl/audioim/AudioHomeActivity.kt
+14
-9
No files found.
m-audioim/src/main/java/com/ydl/audioim/AudioHomeActivity.kt
View file @
2fb167a1
...
...
@@ -673,12 +673,12 @@ class AudioHomeActivity :
tv_name
.
text
=
expertName
// tv_tips.text = expertTips
va
r
time
=
totalDuration
?.
minus
(
remainTime
!!
.
toInt
())
va
l
time
=
totalDuration
?.
minus
(
remainTime
!!
.
toInt
())
tv_remain_time
.
text
=
DateUtils
.
formatTime
((
time
).
toString
())
val
timeTotal
=
totalDuration
?.
div
(
60
);
tv_totalDuration
.
text
=
"(满${timeTotal}分钟自动挂断,限24小时内拨打)"
if
(!
TextUtils
.
isEmpty
(
expertHeadUrl
))
{
va
r
option
=
SimpleImageOpConfiger
()
va
l
option
=
SimpleImageOpConfiger
()
option
.
errorPic
=
R
.
drawable
.
audioim_head_place_hold_pic
option
.
loadingPic
=
R
.
drawable
.
audioim_head_place_hold_pic
option
.
transform
=
0
...
...
@@ -1425,7 +1425,7 @@ class AudioHomeActivity :
null
,
channelId
)
va
r
cmd
=
NoticePushCommand
()
va
l
cmd
=
NoticePushCommand
()
cmd
.
data
=
msgBean
cmd
.
pushId
=
listenerUid
if
(
isCall
)
{
...
...
@@ -1452,6 +1452,8 @@ class AudioHomeActivity :
LogUtil
.
e
(
"播放结束音频"
)
//播放结束音频
playFinishMusic
()
// 声网离开房间
voiceManage
?.
getVoiceApi
()
?.
leaveChannel
()
}
}
...
...
@@ -1577,11 +1579,11 @@ class AudioHomeActivity :
eventType
:
String
=
"99"
,
callback
:
YDLavManager
.
UploadExceptionCallback
?
)
{
va
r
time
:
String
=
(
System
.
currentTimeMillis
()
/
1000
).
toString
()
va
r
uid
:
String
=
va
l
time
:
String
=
(
System
.
currentTimeMillis
()
/
1000
).
toString
()
va
l
uid
:
String
=
ModularServiceManager
.
provide
(
IUserService
::
class
.
java
).
getUserInfo
()
?.
uid
!!
va
r
payLoad
=
PayLoad
(
channelId
?:
"0"
,
time
,
uid
,
"1"
,
"999"
,
message
)
va
r
connectException
=
va
l
payLoad
=
PayLoad
(
channelId
?:
"0"
,
time
,
uid
,
"1"
,
"999"
,
message
)
va
l
connectException
=
ConnectExceptionCommand
(
time
+
zhu
,
"2"
,
eventType
,
payLoad
,
callStatus
)
YDLavManager
.
instances
.
uploadException
(
connectException
,
callback
)
}
...
...
@@ -1598,7 +1600,7 @@ class AudioHomeActivity :
}
override
fun
finishActivity
()
{
leaveChannel
()
//
leaveChannel()
}
override
fun
onDestroy
()
{
...
...
@@ -1640,7 +1642,10 @@ class AudioHomeActivity :
localPowerManager
=
null
if
(
null
!=
voiceManage
&&
null
!=
voiceManage
?.
getVoiceApi
())
{
voiceManage
?.
getVoiceApi
()
?.
leaveChannel
()
if
(!
isLeavelChannel
)
{
// 声网离开房间
voiceManage
?.
getVoiceApi
()
?.
leaveChannel
()
}
voiceManage
?.
getVoiceApi
()
?.
destroy
()
voiceManage
=
null
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment