[6.7.0][数据上车] feat: 调整司机端通用事件弹框样式 & 替换各场景icon ;

feat: 接驳/公交 司机端增加通用事件弹框view ;
This commit is contained in:
aibingbing
2024-09-24 18:42:36 +08:00
parent d08f1fcd60
commit f7d14e5ca6
13 changed files with 58 additions and 23 deletions

View File

@@ -206,7 +206,7 @@ class RoadV2NEventWindowView @JvmOverloads constructor(
} else {
val layoutParam =
roundRoadV2NEventContainer.layoutParams as ConstraintLayout.LayoutParams
layoutParam.width = AutoSizeUtils.dp2px(context, (600 + 0 + 0).toFloat())
layoutParam.width = AutoSizeUtils.dp2px(context, (654 + 0 + 0).toFloat())
layoutParam.height = ConstraintLayout.LayoutParams.WRAP_CONTENT
roundRoadV2NEventContainer.layoutParams = layoutParam
roundRoadV2NEventContainer.background =
@@ -219,23 +219,23 @@ class RoadV2NEventWindowView @JvmOverloads constructor(
containerIconHintLayoutParams.width = LayoutParams.MATCH_PARENT
containerIconHintLayoutParams.height = LayoutParams.WRAP_CONTENT
containerIconHintLayoutParams.setMargins(
AutoSizeUtils.dp2px(context, 30f - 22f),
AutoSizeUtils.dp2px(context, 31f - 15f),
AutoSizeUtils.dp2px(context, 30f - 22f),
AutoSizeUtils.dp2px(context, 30f - 16f),
AutoSizeUtils.dp2px(context, 30f - 14f),
AutoSizeUtils.dp2px(context, 30f - 16f),
0
)
containerIconHint.layoutParams = containerIconHintLayoutParams
val ivV2XImageLayoutParams = ivV2XImage.layoutParams as RelativeLayout.LayoutParams
ivV2XImageLayoutParams.width = AutoSizeUtils.dp2px(context, 84f + 22f + 22f)
ivV2XImageLayoutParams.height = AutoSizeUtils.dp2px(context, 84f + 15f + 29f)
ivV2XImageLayoutParams.width = AutoSizeUtils.dp2px(context, 120f + 16f + 16f)
ivV2XImageLayoutParams.height = AutoSizeUtils.dp2px(context, 120f + 16f + 16f)
ivV2XImage.layoutParams = ivV2XImageLayoutParams
val tvV2XHintContentLayoutParams =
tvV2XHintContent.layoutParams as RelativeLayout.LayoutParams
tvV2XHintContentLayoutParams.setMargins(
AutoSizeUtils.dp2px(context, 20f - 22f),
AutoSizeUtils.dp2px(context, (42f + 15f) - (46f / 2f)),
AutoSizeUtils.dp2px(context, 30f - 14f),
AutoSizeUtils.dp2px(context, (60f + 16f) - (50f / 2f)),
AutoSizeUtils.dp2px(context, 5f),
0
)
@@ -249,11 +249,11 @@ class RoadV2NEventWindowView @JvmOverloads constructor(
val containerImageAndLiveVideoLayoutParams =
containerImageAndLiveVideo.layoutParams as ConstraintLayout.LayoutParams
containerImageAndLiveVideoLayoutParams.width = AutoSizeUtils.dp2px(context, 540f)
containerImageAndLiveVideoLayoutParams.height = AutoSizeUtils.dp2px(context, 300f)
containerImageAndLiveVideoLayoutParams.width = AutoSizeUtils.dp2px(context, 593f)
containerImageAndLiveVideoLayoutParams.height = AutoSizeUtils.dp2px(context, 330f)
containerImageAndLiveVideoLayoutParams.setMargins(
AutoSizeUtils.dp2px(context, 30f),
AutoSizeUtils.dp2px(context, 30f - 29f),
AutoSizeUtils.dp2px(context, 20f - 16f),
AutoSizeUtils.dp2px(context, 30f),
0
)
@@ -266,16 +266,16 @@ class RoadV2NEventWindowView @JvmOverloads constructor(
tvV2XTimeStrLayoutParams.width = LayoutParams.MATCH_PARENT
tvV2XTimeStrLayoutParams.height = LayoutParams.WRAP_CONTENT
tvV2XTimeStrLayoutParams.setMargins(
AutoSizeUtils.dp2px(context, 29f),
AutoSizeUtils.dp2px(context, 25f),
AutoSizeUtils.dp2px(context, 29f),
AutoSizeUtils.dp2px(context, 30f)
AutoSizeUtils.dp2px(context, 30f),
AutoSizeUtils.dp2px(context, 12f),
AutoSizeUtils.dp2px(context, 30f),
AutoSizeUtils.dp2px(context, 24f)
)
tvV2XTimeStr.layoutParams = tvV2XTimeStrLayoutParams
tvV2XTimeStr.setTextColor(Color.parseColor("#66FFFFFF"))
tvV2XTimeStr.setTextColor(Color.parseColor("#999999"))
tvV2XTimeStr.setTextSize(
TypedValue.COMPLEX_UNIT_PX,
AutoSizeUtils.dp2px(context, 22f).toFloat()
AutoSizeUtils.dp2px(context, 26f).toFloat()
)
ivClose.setImageResource(R.drawable.hmi_v2n_event_icon_close_driver)
@@ -285,6 +285,8 @@ class RoadV2NEventWindowView @JvmOverloads constructor(
ivCloseLayoutParams.height = AutoSizeUtils.dp2px(context, 50f)
ivCloseLayoutParams.setMargins(0, 0, 0, 0)
ivClose.layoutParams = ivCloseLayoutParams
// 6.7.0 UI 没设计关闭按钮
ivClose.visibility = View.GONE
containerEventContent.requestLayout()
roundRoadV2NEventContainer.requestLayout()

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 282 KiB