|
@@ -8,6 +8,7 @@ import android.widget.RelativeLayout
|
|
|
import com.develop.base.ext.load
|
|
|
import com.develop.base.R.*
|
|
|
import com.develop.base.ext.background_drawable
|
|
|
+import com.develop.base.ext.isNightTheme
|
|
|
import com.develop.base.ext.resId2Dimension
|
|
|
import com.develop.base.ext.src
|
|
|
import com.develop.base.ext.updateText
|
|
@@ -43,6 +44,12 @@ class HomeFunctionTopBar : RelativeLayout, View.OnClickListener {
|
|
|
binding.ivWifi.setImageLevel(0)
|
|
|
binding.ivFunction.background_drawable = R.drawable.ic_home
|
|
|
|
|
|
+ if (isNightTheme()) {
|
|
|
+ val params = binding.ivFunction.layoutParams as RelativeLayout.LayoutParams
|
|
|
+ params.width = dp50
|
|
|
+ params.height = dp50
|
|
|
+ binding.ivFunction.layoutParams = params
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
fun setHomeOrBack(type: HomeOrBack) {
|
|
@@ -120,6 +127,7 @@ class HomeFunctionTopBar : RelativeLayout, View.OnClickListener {
|
|
|
var dp35 = (R.dimen.convert_35px).resId2Dimension().toInt()
|
|
|
var dp60 = (R.dimen.convert_60px).resId2Dimension().toInt()
|
|
|
var dp120 = (R.dimen.convert_120px).resId2Dimension().toInt()
|
|
|
+ var dp50 = (R.dimen.convert_50px).resId2Dimension().toInt()
|
|
|
}
|
|
|
}
|
|
|
|