feat: 优化代码

pull/145/head
kunfei 5 years ago
parent 23a718a795
commit 5d7716ecef
  1. 6
      app/src/main/java/io/legado/app/ui/widget/TitleBar.kt

@ -144,10 +144,10 @@ class TitleBar(context: Context, attrs: AttributeSet?) : AppBarLayout(context, a
backgroundColor = context.primaryColor
// targetElevation = context.elevation
stateListAnimator = null
if (AppConfig.elevation < 0) {
elevation = context.elevation
elevation = if (AppConfig.elevation < 0) {
context.elevation
} else {
elevation = AppConfig.elevation.toFloat()
AppConfig.elevation.toFloat()
}
a.recycle()

Loading…
Cancel
Save