[3.4.0] code opt of array and non use code

This commit is contained in:
zhongchao
2023-07-31 16:11:37 +08:00
parent 4999779b7a
commit c81e1bb564
4 changed files with 58 additions and 58 deletions

View File

@@ -93,8 +93,8 @@ class ConsultVideoPlayer : StandardGSYVideoPlayer {
// layoutParams.height = 320
// mTopContainer.layoutParams = layoutParams
val background = layoutBottom.background as GradientDrawable
val x = arrayOf(12f, 12f,12f, 12f,12f, 12f,12f, 12f)
background.cornerRadii = x.toFloatArray()
val x = floatArrayOf(12f, 12f,12f, 12f,12f, 12f,12f, 12f)
background.cornerRadii = x
layoutBottom.background = background
//fullscreenButton.setPadding(0,0,0,0)

View File

@@ -193,57 +193,57 @@ class CommonAmapNaviVIew @JvmOverloads constructor(
amapNaviView.onDestroy()
}
var array = arrayOf(
"直行车道",
"左转车道",
"左转或直行车道",
"右转车道",
"右转或直行车道",
"左掉头车道",
"左转或者右转车道",
" 左转或右转或直行车道",
"右转掉头车道",
"直行或左转掉头车道",
"直行或右转掉头车道",
"左转或左掉头车道",
"右转或右掉头车道",
"直行并且车道扩展",
"左转+左掉头+扩展",
"不可以选择该车道",
"直行+左转+左掉头车道",
"右转+左掉头",
"左转+右转+左掉头",
"直行+右转+左掉头",
"左转+右掉头",
"公交车道",
"空车道",
"可变车道"
)
// var array = arrayOf(
// "直行车道",
// "左转车道",
// "左转或直行车道",
// "右转车道",
// "右转或直行车道",
// "左掉头车道",
// "左转或者右转车道",
// " 左转或右转或直行车道",
// "右转掉头车道",
// "直行或左转掉头车道",
// "直行或右转掉头车道",
// "左转或左掉头车道",
// "右转或右掉头车道",
// "直行并且车道扩展",
// "左转+左掉头+扩展",
// "不可以选择该车道",
// "直行+左转+左掉头车道",
// "右转+左掉头",
// "左转+右转+左掉头",
// "直行+右转+左掉头",
// "左转+右掉头",
// "公交车道",
// "空车道",
// "可变车道"
// )
var actions = arrayOf(
"直行",
"左转",
"左转或直行",
"右转",
"右转或这行",
"左掉头",
"左转或者右转",
" 左转或右转或直行",
"右转掉头",
"直行或左转掉头",
"直行或右转掉头",
"左转或左掉头",
"右转或右掉头",
"直行并且车道扩展",
"左转+左掉头+扩展",
"不可以选择",
"直行+左转+左掉头",
"右转+左掉头",
"左转+右转+左掉头",
"直行+右转+左掉头",
"左转+右掉头",
"公交车道",
"空车道",
"可变车道"
)
// var actions = arrayOf(
// "直行",
// "左转",
// "左转或直行",
// "右转",
// "右转或这行",
// "左掉头",
// "左转或者右转",
// " 左转或右转或直行",
// "右转掉头",
// "直行或左转掉头",
// "直行或右转掉头",
// "左转或左掉头",
// "右转或右掉头",
// "直行并且车道扩展",
// "左转+左掉头+扩展",
// "不可以选择",
// "直行+左转+左掉头",
// "右转+左掉头",
// "左转+右转+左掉头",
// "直行+右转+左掉头",
// "左转+右掉头",
// "公交车道",
// "空车道",
// "可变车道"
// )
}

View File

@@ -17,7 +17,7 @@ class MineGradientDrawable(colorStart: Int = Color.BLUE,colorEnd:Int = Color.RED
private var colorWith = 4f
private var transparentWidth = 4f
private var index = arrayOf(0.53,0.76,0.92)
private var index = doubleArrayOf(0.53,0.76,0.92)
private var tartHeight = 0
private var heightDex = 0
@@ -29,7 +29,7 @@ class MineGradientDrawable(colorStart: Int = Color.BLUE,colorEnd:Int = Color.RED
this.colorEnd = colorEnd
this.tartHeight = height
mPaint.isAntiAlias = true
index.forEachIndexed { index, d ->
index.forEachIndexed { _, d ->
currendDex += (1-d)/2
}
}

View File

@@ -98,8 +98,8 @@ class ConsultVideoPlayer : StandardGSYVideoPlayer {
layoutParams.height = 320
mTopContainer.layoutParams = layoutParams
val background = layoutBottom.background as GradientDrawable
val x = arrayOf(12f, 12f,12f, 12f,12f, 12f,12f, 12f)
background.cornerRadii = x.toFloatArray()
val x = floatArrayOf(12f, 12f,12f, 12f,12f, 12f,12f, 12f)
background.cornerRadii = x
layoutBottom.background = background