修改直播等于1,隐藏直播按钮
This commit is contained in:
@@ -248,6 +248,10 @@ class MapV3Fragment : BaseFragment<FragmentMapV3Binding>(FragmentMapV3Binding::i
|
|||||||
XEventBus.observe(this, EventName.RefreshFences) {
|
XEventBus.observe(this, EventName.RefreshFences) {
|
||||||
updateMapDeviceStatus()
|
updateMapDeviceStatus()
|
||||||
}
|
}
|
||||||
|
//删除设备
|
||||||
|
XEventBus.observe(this, EventName.DeleteDevice) {
|
||||||
|
mMapViewModel.stopGetData()
|
||||||
|
}
|
||||||
//直播自动结束提示
|
//直播自动结束提示
|
||||||
XEventBus.observe(this, EventName.LiveAutoEnd) {
|
XEventBus.observe(this, EventName.LiveAutoEnd) {
|
||||||
CommonDialog1(
|
CommonDialog1(
|
||||||
@@ -576,6 +580,8 @@ class MapV3Fragment : BaseFragment<FragmentMapV3Binding>(FragmentMapV3Binding::i
|
|||||||
isCanLive =
|
isCanLive =
|
||||||
!(Util.isTimeoutReport(updateTime) || powerSwitch == ConstantInt.Type0 || powerSwitch == ConstantInt.Type2 || powerSwitch == ConstantInt.Type3 || inWifiZone == ConstantInt.Type1)
|
!(Util.isTimeoutReport(updateTime) || powerSwitch == ConstantInt.Type0 || powerSwitch == ConstantInt.Type2 || powerSwitch == ConstantInt.Type3 || inWifiZone == ConstantInt.Type1)
|
||||||
setLiveBtnState(isCanLive)
|
setLiveBtnState(isCanLive)
|
||||||
|
mViewBinding.homeMapLiveBtn.visibility = if (liveFlag == ConstantInt.Type1) View.GONE
|
||||||
|
else View.VISIBLE
|
||||||
|
|
||||||
mViewBinding.ilHomeMapDeviceBatteryLayout.let {
|
mViewBinding.ilHomeMapDeviceBatteryLayout.let {
|
||||||
mMapViewModel.setMapDeviceBattery(
|
mMapViewModel.setMapDeviceBattery(
|
||||||
@@ -681,7 +687,7 @@ class MapV3Fragment : BaseFragment<FragmentMapV3Binding>(FragmentMapV3Binding::i
|
|||||||
} else {
|
} else {
|
||||||
mShowCenterLocationType = ConstantInt.PetLocationType
|
mShowCenterLocationType = ConstantInt.PetLocationType
|
||||||
isMoveCamera = true
|
isMoveCamera = true
|
||||||
updateMapDeviceStatus(useBleLocation = true)
|
updateMapDeviceStatus(useBleLocation = false)
|
||||||
}
|
}
|
||||||
ViewUtil.instance.setMapSwitchLocationButtonImage(
|
ViewUtil.instance.setMapSwitchLocationButtonImage(
|
||||||
homeMapRefreshBtn, mShowCenterLocationType
|
homeMapRefreshBtn, mShowCenterLocationType
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ class MapViewModel : ViewModel() {
|
|||||||
private var mCountDownTimer: CountDownTimer? = null
|
private var mCountDownTimer: CountDownTimer? = null
|
||||||
|
|
||||||
//几分钟倒计时(min)
|
//几分钟倒计时(min)
|
||||||
private var mRefreshDataMin = 0.5f
|
private var mRefreshDataMin = 0.35f
|
||||||
private var mDeviceId = ""
|
private var mDeviceId = ""
|
||||||
|
|
||||||
var mDeviceMsgType = ConstantInt.SpecialType
|
var mDeviceMsgType = ConstantInt.SpecialType
|
||||||
|
|||||||
Reference in New Issue
Block a user