自动订阅的套餐列表,不显示倒计时,取消自动订阅的套餐才显示
This commit is contained in:
@@ -1 +1 @@
|
|||||||
#Thu Apr 09 17:00:19 CST 2026
|
#Thu Apr 16 16:49:17 CST 2026
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ android {
|
|||||||
targetSdkVersion 35
|
targetSdkVersion 35
|
||||||
versionCode 2202
|
versionCode 2202
|
||||||
// versionName "2.2.2"
|
// versionName "2.2.2"
|
||||||
versionName "2.2.2-Beta2"
|
versionName "2.2.2-Beta3"
|
||||||
|
|
||||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
|
|
||||||
|
|||||||
@@ -1,9 +1,11 @@
|
|||||||
package com.abbidot.tracker.ui.fragment.data
|
package com.abbidot.tracker.ui.fragment.data
|
||||||
|
|
||||||
|
import android.animation.ValueAnimator
|
||||||
import android.annotation.SuppressLint
|
import android.annotation.SuppressLint
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.view.MotionEvent
|
import android.view.MotionEvent
|
||||||
import android.view.View
|
import android.view.View
|
||||||
|
import android.view.animation.LinearInterpolator
|
||||||
import android.widget.SeekBar
|
import android.widget.SeekBar
|
||||||
import androidx.core.view.WindowInsetsCompat
|
import androidx.core.view.WindowInsetsCompat
|
||||||
import androidx.core.view.isVisible
|
import androidx.core.view.isVisible
|
||||||
@@ -144,7 +146,7 @@ class RouteV3Fragment : BaseFragment<FragmentRouteV3Binding>(FragmentRouteV3Bind
|
|||||||
|
|
||||||
llMapRouteLineV3ZoomingLayout.setOnTouchListener { _, event ->
|
llMapRouteLineV3ZoomingLayout.setOnTouchListener { _, event ->
|
||||||
if (rlMapRouteLineV3TimeLayout.isVisible) {
|
if (rlMapRouteLineV3TimeLayout.isVisible) {
|
||||||
if (mLastScrollViewHeight == 0) {
|
if (mTotalHeight == 0) {
|
||||||
mTotalHeight = cvHomeRouteV3Card.height + svHomeRouteMapScroll.height
|
mTotalHeight = cvHomeRouteV3Card.height + svHomeRouteMapScroll.height
|
||||||
mLastScrollViewHeight = svHomeRouteMapScroll.height
|
mLastScrollViewHeight = svHomeRouteMapScroll.height
|
||||||
}
|
}
|
||||||
@@ -176,18 +178,16 @@ class RouteV3Fragment : BaseFragment<FragmentRouteV3Binding>(FragmentRouteV3Bind
|
|||||||
|
|
||||||
MotionEvent.ACTION_UP -> {
|
MotionEvent.ACTION_UP -> {
|
||||||
LogUtil.e("ACTION_UP")
|
LogUtil.e("ACTION_UP")
|
||||||
val layoutParams = svHomeRouteMapScroll.layoutParams
|
// val layoutParams = svHomeRouteMapScroll.layoutParams
|
||||||
if (mDiffHeight > mTotalHeight / 2) {
|
if (mDiffHeight > mTotalHeight / 2) {
|
||||||
setSeekBarShowHide(false)
|
setSeekBarShowHide(false)
|
||||||
layoutParams.height = mTotalHeight
|
// layoutParams.height = mTotalHeight
|
||||||
svHomeRouteMapScroll.layoutParams = layoutParams
|
// svHomeRouteMapScroll.layoutParams = layoutParams
|
||||||
|
animateViewHeight(svHomeRouteMapScroll, mTotalHeight)
|
||||||
isListExpand = true
|
isListExpand = true
|
||||||
} else {
|
} else {
|
||||||
svHomeRouteMapScroll.postDelayed(
|
|
||||||
{ mHistoryDataMapCommon.setLatLngData(mHistoryDataList) }, 200
|
|
||||||
)
|
|
||||||
if (mDiffHeight > mLastScrollViewHeight) {
|
if (mDiffHeight > mLastScrollViewHeight) {
|
||||||
layoutParams.height = if (isSlideUp) {
|
val height = if (isSlideUp) {
|
||||||
isListExpand = true
|
isListExpand = true
|
||||||
setSeekBarShowHide(false)
|
setSeekBarShowHide(false)
|
||||||
mTotalHeight / 2
|
mTotalHeight / 2
|
||||||
@@ -203,8 +203,12 @@ class RouteV3Fragment : BaseFragment<FragmentRouteV3Binding>(FragmentRouteV3Bind
|
|||||||
}
|
}
|
||||||
mLastScrollViewHeight
|
mLastScrollViewHeight
|
||||||
}
|
}
|
||||||
|
animateViewHeight(svHomeRouteMapScroll, height, 300)
|
||||||
}
|
}
|
||||||
svHomeRouteMapScroll.layoutParams = layoutParams
|
// svHomeRouteMapScroll.layoutParams = layoutParams
|
||||||
|
svHomeRouteMapScroll.postDelayed(
|
||||||
|
{ mHistoryDataMapCommon.setLatLngData(mHistoryDataList) }, 500
|
||||||
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -231,6 +235,19 @@ class RouteV3Fragment : BaseFragment<FragmentRouteV3Binding>(FragmentRouteV3Bind
|
|||||||
initState()
|
initState()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private fun animateViewHeight(view: View, targetHeight: Int, duration: Long = 500) {
|
||||||
|
val animator = ValueAnimator.ofInt(view.height, targetHeight)
|
||||||
|
animator.duration = duration // 设置动画持续时间
|
||||||
|
animator.interpolator = LinearInterpolator() // 设置插值器
|
||||||
|
animator.addUpdateListener { animation ->
|
||||||
|
val animatedValue = animation.animatedValue as Int
|
||||||
|
val layoutParams = view.layoutParams
|
||||||
|
layoutParams.height = animatedValue
|
||||||
|
view.layoutParams = layoutParams
|
||||||
|
}
|
||||||
|
animator.start()
|
||||||
|
}
|
||||||
|
|
||||||
private fun getHomeV2Activity(): HomeV2Activity? {
|
private fun getHomeV2Activity(): HomeV2Activity? {
|
||||||
return if (null == activity) {
|
return if (null == activity) {
|
||||||
LogUtil.e("RouteV2Fragment,getHomeV2Activity,null == activity")
|
LogUtil.e("RouteV2Fragment,getHomeV2Activity,null == activity")
|
||||||
@@ -487,7 +504,7 @@ class RouteV3Fragment : BaseFragment<FragmentRouteV3Binding>(FragmentRouteV3Bind
|
|||||||
*/
|
*/
|
||||||
private fun setSeekBarShowHide(show: Boolean) {
|
private fun setSeekBarShowHide(show: Boolean) {
|
||||||
mViewBinding.apply {
|
mViewBinding.apply {
|
||||||
if (show && !isListExpand) {
|
if (show && !isListExpand && mHistoryDataList.isNotEmpty()) {
|
||||||
vsbMapRouteLineV3.visibility = View.VISIBLE
|
vsbMapRouteLineV3.visibility = View.VISIBLE
|
||||||
ivMapRouteLineV3LastBtn.visibility = View.VISIBLE
|
ivMapRouteLineV3LastBtn.visibility = View.VISIBLE
|
||||||
ivMapRouteLineV3NextBtn.visibility = View.VISIBLE
|
ivMapRouteLineV3NextBtn.visibility = View.VISIBLE
|
||||||
|
|||||||
@@ -125,7 +125,7 @@ class DeviceDFUViewModel(application: Application) : AndroidViewModel(applicatio
|
|||||||
override fun onUpgradeFailed(
|
override fun onUpgradeFailed(
|
||||||
state: FirmwareUpgradeManager.State?, error: McuMgrException?
|
state: FirmwareUpgradeManager.State?, error: McuMgrException?
|
||||||
) {
|
) {
|
||||||
LogUtil.e("DfuProgressListener -->> onError")
|
LogUtil.e("DfuProgressListener -->> onError${error.toString()}")
|
||||||
val stateBean =
|
val stateBean =
|
||||||
DFUStateBean(context.getString(R.string.txt_upgrade_fail), mDFUFailCode)
|
DFUStateBean(context.getString(R.string.txt_upgrade_fail), mDFUFailCode)
|
||||||
mDfuStateLiveData.value = stateBean
|
mDfuStateLiveData.value = stateBean
|
||||||
|
|||||||
Reference in New Issue
Block a user