Browse Source

提交人:jtm
提交内容:优化

江天明 1 year ago
parent
commit
ae1553d77f

BIN
BusinessCommon/src/main/res/drawable-xxxhdpi/ic_grid_adapted_cooking.webp


BIN
BusinessCommon/src/main/res/drawable-xxxhdpi/ic_grid_boil_water.webp


BIN
BusinessCommon/src/main/res/drawable-xxxhdpi/ic_grid_chop.webp


BIN
BusinessCommon/src/main/res/drawable-xxxhdpi/ic_grid_ferment.webp


BIN
BusinessCommon/src/main/res/drawable-xxxhdpi/ic_grid_food_processor.webp


BIN
BusinessCommon/src/main/res/drawable-xxxhdpi/ic_grid_knead_dough.webp


BIN
BusinessCommon/src/main/res/drawable-xxxhdpi/ic_grid_slow_cook.webp


BIN
BusinessCommon/src/main/res/drawable-xxxhdpi/ic_grid_steam.webp


BIN
BusinessCommon/src/main/res/drawable-xxxhdpi/ic_grid_turbo.webp


BIN
BusinessCommon/src/main/res/drawable-xxxhdpi/ic_grid_weight.webp


+ 12 - 8
BusinessStep/src/main/java/com/develop/step/ui/ModesDetailActivity.kt

@@ -511,13 +511,17 @@ class ModesDetailActivity : CommonBVMActivity<ActivityModeDetailBinding, ModesVi
         }
         if (!isNightTheme()) {
             if (workMode == null) {
-                binding.ivBanner.background_drawable = com.develop.common.R.drawable.ic_mode_diy
+                Glide.with(this).load(com.develop.common.R.drawable.ic_mode_diy)
+                    .into(binding.ivBanner)
             } else {
-                binding.ivBanner.background_drawable = resources.getIdentifier(
-                    workMode.bg,
-                    "drawable",
-                    this.packageName
+                Glide.with(this).load(
+                    resources.getIdentifier(
+                        workMode.bg,
+                        "drawable",
+                        this.packageName
+                    )
                 )
+                    .into(binding.ivBanner)
             }
         }
 //        // 获取ImageView的宽度和高度
@@ -1581,7 +1585,7 @@ class ModesDetailActivity : CommonBVMActivity<ActivityModeDetailBinding, ModesVi
         binding.tvModeName.text = viewModel.getModeTitle(resources)
 
         if (!isNightTheme()) {
-            binding.ivBanner.setBackgroundResource(viewModel.getBanner())
+            Glide.with(this).load(viewModel.getBanner()).into(binding.ivBanner)
         }
     }
 
@@ -1603,7 +1607,7 @@ class ModesDetailActivity : CommonBVMActivity<ActivityModeDetailBinding, ModesVi
         Log.d("dddddd", "llTurboView===VISIBLE")
         binding.llTurboView.visibility = View.VISIBLE
         if (!isNightTheme()) {
-            binding.ivBanner.setBackgroundResource(viewModel.getBanner())
+            Glide.with(this).load(viewModel.getBanner()).into(binding.ivBanner)
         }
     }
 
@@ -1643,7 +1647,7 @@ class ModesDetailActivity : CommonBVMActivity<ActivityModeDetailBinding, ModesVi
                     getString(resources.getIdentifier(workMode?.name, "string", this.packageName))
 
                 if (!isNightTheme()) {
-                    binding.ivBanner.background_drawable = viewModel.getBanner()
+                    Glide.with(this).load(viewModel.getBanner()).into(binding.ivBanner)
                 }
                 modeChange = false
                 Log.d("dddddd", "llTurboView===GONE")