Commit b1089cef by 杨凯

Merge branch 'feature/yk_release' into 'd/v4.4.07'

Feature/yk release

See merge request app_android_lib/YDL-Component!297
parents b530ece9 3a45711a
...@@ -674,12 +674,12 @@ class AudioHomeActivity : ...@@ -674,12 +674,12 @@ class AudioHomeActivity :
tv_name.text = expertName tv_name.text = expertName
// tv_tips.text = expertTips // tv_tips.text = expertTips
var time = totalDuration?.minus(remainTime!!.toInt()) val time = totalDuration?.minus(remainTime!!.toInt())
tv_remain_time.text = DateUtils.formatTime((time).toString()) tv_remain_time.text = DateUtils.formatTime((time).toString())
val timeTotal= totalDuration?.div(60); val timeTotal= totalDuration?.div(60);
tv_totalDuration.text="(满${timeTotal}分钟自动挂断,限24小时内拨打)" tv_totalDuration.text="(满${timeTotal}分钟自动挂断,限24小时内拨打)"
if (!TextUtils.isEmpty(expertHeadUrl)) { if (!TextUtils.isEmpty(expertHeadUrl)) {
var option = SimpleImageOpConfiger() val option = SimpleImageOpConfiger()
option.errorPic = R.drawable.audioim_head_place_hold_pic option.errorPic = R.drawable.audioim_head_place_hold_pic
option.loadingPic = R.drawable.audioim_head_place_hold_pic option.loadingPic = R.drawable.audioim_head_place_hold_pic
option.transform = 0 option.transform = 0
...@@ -1426,7 +1426,7 @@ class AudioHomeActivity : ...@@ -1426,7 +1426,7 @@ class AudioHomeActivity :
null, null,
channelId channelId
) )
var cmd = NoticePushCommand() val cmd = NoticePushCommand()
cmd.data = msgBean cmd.data = msgBean
cmd.pushId = listenerUid cmd.pushId = listenerUid
if (isCall) { if (isCall) {
...@@ -1453,6 +1453,8 @@ class AudioHomeActivity : ...@@ -1453,6 +1453,8 @@ class AudioHomeActivity :
LogUtil.e("播放结束音频") LogUtil.e("播放结束音频")
//播放结束音频 //播放结束音频
playFinishMusic() playFinishMusic()
// 声网离开房间
voiceManage?.getVoiceApi()?.leaveChannel()
} }
} }
...@@ -1578,11 +1580,11 @@ class AudioHomeActivity : ...@@ -1578,11 +1580,11 @@ class AudioHomeActivity :
eventType: String = "99", eventType: String = "99",
callback: YDLavManager.UploadExceptionCallback? callback: YDLavManager.UploadExceptionCallback?
) { ) {
var time: String = (System.currentTimeMillis() / 1000).toString() val time: String = (System.currentTimeMillis() / 1000).toString()
var uid: String = val uid: String =
ModularServiceManager.provide(IUserService::class.java).getUserInfo()?.uid!! ModularServiceManager.provide(IUserService::class.java).getUserInfo()?.uid!!
var payLoad = PayLoad(channelId ?: "0", time, uid, "1", "999", message) val payLoad = PayLoad(channelId ?: "0", time, uid, "1", "999", message)
var connectException = val connectException =
ConnectExceptionCommand(time + zhu, "2", eventType, payLoad, callStatus) ConnectExceptionCommand(time + zhu, "2", eventType, payLoad, callStatus)
YDLavManager.instances.uploadException(connectException, callback) YDLavManager.instances.uploadException(connectException, callback)
} }
...@@ -1598,10 +1600,6 @@ class AudioHomeActivity : ...@@ -1598,10 +1600,6 @@ class AudioHomeActivity :
} }
} }
override fun finishActivity() {
leaveChannel()
}
override fun onDestroy() { override fun onDestroy() {
super.onDestroy() super.onDestroy()
findRouteService(IImService::class.java).unregisterObserveCustomNotification(notificationCallback) findRouteService(IImService::class.java).unregisterObserveCustomNotification(notificationCallback)
...@@ -1641,7 +1639,10 @@ class AudioHomeActivity : ...@@ -1641,7 +1639,10 @@ class AudioHomeActivity :
localPowerManager = null localPowerManager = null
if (null != voiceManage && null != voiceManage?.getVoiceApi()) { if (null != voiceManage && null != voiceManage?.getVoiceApi()) {
voiceManage?.getVoiceApi()?.leaveChannel() if (!isLeavelChannel) {
// 声网离开房间
voiceManage?.getVoiceApi()?.leaveChannel()
}
voiceManage?.getVoiceApi()?.destroy() voiceManage?.getVoiceApi()?.destroy()
voiceManage = null voiceManage = null
} }
......
...@@ -4,7 +4,6 @@ import com.ydl.audioim.bean.ConnectBean ...@@ -4,7 +4,6 @@ import com.ydl.audioim.bean.ConnectBean
import com.ydl.audioim.http.command.* import com.ydl.audioim.http.command.*
import com.ydl.ydlcommon.data.http.BaseAPIResponse import com.ydl.ydlcommon.data.http.BaseAPIResponse
import com.ydl.ydlcommon.data.http.BaseResponse import com.ydl.ydlcommon.data.http.BaseResponse
import com.ydl.ydlcommon.mvp.base.BasePresenter
import com.ydl.ydlcommon.mvp.base.IModel import com.ydl.ydlcommon.mvp.base.IModel
import com.ydl.ydlcommon.mvp.base.IPresenter import com.ydl.ydlcommon.mvp.base.IPresenter
import com.ydl.ydlcommon.mvp.base.IView import com.ydl.ydlcommon.mvp.base.IView
...@@ -29,10 +28,6 @@ interface IAudioHomeActivityContract { ...@@ -29,10 +28,6 @@ interface IAudioHomeActivityContract {
*/ */
fun dismissProgressView() fun dismissProgressView()
/**
* 关闭窗口
*/
fun finishActivity()
/** /**
*切换axb回调 *切换axb回调
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment