修复分享设备还可以直播的bug
This commit is contained in:
@@ -30,7 +30,7 @@ android {
|
|||||||
targetSdkVersion 35
|
targetSdkVersion 35
|
||||||
versionCode 2106
|
versionCode 2106
|
||||||
// versionName "2.1.6"
|
// versionName "2.1.6"
|
||||||
versionName "2.1.6-Beta1"
|
versionName "2.1.6-Beta3"
|
||||||
|
|
||||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
|
|
||||||
|
|||||||
@@ -551,10 +551,6 @@ class MapV3Fragment : BaseFragment<FragmentMapV3Binding>(FragmentMapV3Binding::i
|
|||||||
R.color.grey_color
|
R.color.grey_color
|
||||||
}
|
}
|
||||||
tvHomeMapLiveTitle.setTextColor(ContextCompat.getColor(mContext!!, tColor))
|
tvHomeMapLiveTitle.setTextColor(ContextCompat.getColor(mContext!!, tColor))
|
||||||
val share = MMKVUtil.getInt(MMKVKey.Shared)
|
|
||||||
if (share != ConstantInt.NoShare) {
|
|
||||||
homeMapLiveBtn.visibility = View.GONE
|
|
||||||
}
|
|
||||||
|
|
||||||
ivHomeMapLiveImage.let {
|
ivHomeMapLiveImage.let {
|
||||||
val bg = if (canLive) {
|
val bg = if (canLive) {
|
||||||
@@ -576,12 +572,19 @@ class MapV3Fragment : BaseFragment<FragmentMapV3Binding>(FragmentMapV3Binding::i
|
|||||||
|
|
||||||
private fun setMapDeviceBean(mapDeviceBean: MapDeviceBean) {
|
private fun setMapDeviceBean(mapDeviceBean: MapDeviceBean) {
|
||||||
mapDeviceBean.apply {
|
mapDeviceBean.apply {
|
||||||
//分钟后无上报、没有lte信号或在wifi中隐藏直播按钮
|
val share = MMKVUtil.getInt(MMKVKey.Shared)
|
||||||
isCanLive =
|
mViewBinding.homeMapLiveBtn.visibility = if (share != ConstantInt.NoShare) {
|
||||||
!(Util.isTimeoutReport(updateTime) || powerSwitch == ConstantInt.Type0 || powerSwitch == ConstantInt.Type2 || powerSwitch == ConstantInt.Type3 || inWifiZone == ConstantInt.Type1)
|
View.GONE
|
||||||
setLiveBtnState(isCanLive)
|
} else {
|
||||||
mViewBinding.homeMapLiveBtn.visibility = if (liveFlag == ConstantInt.Type1) View.GONE
|
if (liveFlag == ConstantInt.Type1) View.GONE
|
||||||
else View.VISIBLE
|
else {
|
||||||
|
//分钟后无上报、没有lte信号或在wifi中隐藏直播按钮
|
||||||
|
isCanLive =
|
||||||
|
!(Util.isTimeoutReport(updateTime) || powerSwitch == ConstantInt.Type0 || powerSwitch == ConstantInt.Type2 || powerSwitch == ConstantInt.Type3 || inWifiZone == ConstantInt.Type1)
|
||||||
|
setLiveBtnState(isCanLive)
|
||||||
|
View.VISIBLE
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
mViewBinding.ilHomeMapDeviceBatteryLayout.let {
|
mViewBinding.ilHomeMapDeviceBatteryLayout.let {
|
||||||
mMapViewModel.setMapDeviceBattery(
|
mMapViewModel.setMapDeviceBattery(
|
||||||
|
|||||||
Reference in New Issue
Block a user