Răsfoiți Sursa

修复hicar的界面问题

onecold 8 luni în urmă
părinte
comite
c3971ef1eb
1 a modificat fișierele cu 5 adăugiri și 5 ștergeri
  1. 5 5
      entry/src/main/ets/view/LocalMusic.ets

+ 5 - 5
entry/src/main/ets/view/LocalMusic.ets

@@ -6123,7 +6123,7 @@ export struct LocalMusic {
         }
         .width(this.getGridWight())
         .borderRadius(12)
-        .backgroundImage(StrUtil.isEmpty(item.pixelMapPath)?undefined:item.pixelMapPath)
+        .backgroundImage(StrUtil.isEmpty(item.pixelMapPath)?$r('app.media.alt'):item.pixelMapPath)
         .backgroundImageSize({ height: '100%', width: '100%' })
         .backgroundBlurStyle(BlurStyle.BACKGROUND_ULTRA_THICK)
         .animation({ curve: Curve.Sharp, duration: 300 })
@@ -10955,8 +10955,8 @@ export struct LocalMusic {
         Column() {
           if (this.isCoverTop  && this.isCoverRectangle) {
             Image(this.cover)
-              .height(this.isHiCar()?(px2vp(this.windowHeight)*0.46):
-                this.isCoverOpacity()?(px2vp(this.windowHeight)*0.55):'auto')
+              .height(this.isHiCar()?(px2vp(this.windowHeight)*0.43):
+                this.isCoverOpacity()?(px2vp(this.windowHeight)*0.54):'auto')
               .width(this.isHiCar()||this.isCoverOpacity()?'auto':this.isBigScreen() ? '72%' : this.isCoverTopBig ? '100%' : '88%')
               .objectFit(this.isCoverRectangle ? ImageFit.Contain : ImageFit.Auto)
               .alt($r('app.media.alt'))
@@ -11075,7 +11075,7 @@ export struct LocalMusic {
           .align(Alignment.Top)
           .rotate({ angle: this.rotateAngle2, centerX: 0, centerY: 0 })
           .opacity(this.isCoverOpacity() || this.isCoverRectangle ? 0 : 1)
-          .visibility(this.isCoverOpacity() || this.isCoverRectangle ? Visibility.None : Visibility.Visible)
+          .visibility(this.isHiCar()||this.isCoverOpacity() || this.isCoverRectangle ? Visibility.None : Visibility.Visible)
 
 
         Column({ space: 8 }) {
@@ -11182,7 +11182,7 @@ export struct LocalMusic {
     }
     .width(this.isLandscape?'83%':'90%')
     .scale({ x: this.scaleValueText, y: this.scaleValueText }) // 添加缩放效果
-    .margin({ top: this.isCoverOpacity() ? 10 : isHidden ? 20 : 10 })
+    .margin({ top:this.isCoverTop?10: 15 })
     .visibility(this.isCoverOpacity() || isHidden ? Visibility.None : Visibility.Visible)
   }