فهرست منبع

专辑详情显示 风格和发行时间

onecold 1 سال پیش
والد
کامیت
c2b974a5b1
1فایلهای تغییر یافته به همراه37 افزوده شده و 18 حذف شده
  1. 37 18
      entry/src/main/ets/view/LocalMusic.ets

+ 37 - 18
entry/src/main/ets/view/LocalMusic.ets

@@ -2796,7 +2796,7 @@ export struct LocalMusic {
 
           }
           .alignItems(HorizontalAlign.Start)
-          .margin({ left: 30, top: 10, bottom: 15 })
+          .margin({ left: 30, top: 3, bottom: 15 })
 
           Column() {
             Column() {
@@ -2808,32 +2808,51 @@ export struct LocalMusic {
                 .margin({ left: this.currentLyricAlignMode === 0 ? 18 : 0 })
               if (this.modeType == 3 && ArrayUtil.isNotEmpty(this.videoLocalList)) {
                 Text(`艺术家:${this.videoLocalList[0].artist}`)
-                  .fontSize(16)
+                  .fontSize(14)
                   .padding({ top: 8 })
                   .maxLines(1)
                   .fontWeight(FontWeight.Bold)
                   .fontColor($r('app.color.text_color'))
                   .margin({ left: this.currentLyricAlignMode === 0 ? 18 : 0 })
+                if(this.videoLocalList[0].genre){
+                  Text(`风格:${this.videoLocalList[0].genre}`)
+                    .fontSize(14)
+                    .padding({ top: 8 })
+                    .maxLines(1)
+                    .visibility(StrUtil.isEmpty(this.videoLocalList[0].genre)||
+                    this.videoLocalList[0].genre.includes('unknown')?Visibility.None:Visibility.Visible)
+                    .fontWeight(FontWeight.Bold)
+                    .fontColor($r('app.color.text_color'))
+                    .margin({ left: this.currentLyricAlignMode === 0 ? 18 : 0 })
+                }
+                if(this.videoLocalList[0].year){
+                  Text(`发行时间:${this.videoLocalList[0].year}`)
+                    .fontSize(14)
+                    .padding({ top: 8 })
+                    .maxLines(1)
+                    .visibility(StrUtil.isEmpty(this.videoLocalList[0].year)||
+                    this.videoLocalList[0].year.includes('unknown')?Visibility.None:Visibility.Visible)
+                    .fontWeight(FontWeight.Bold)
+                    .fontColor($r('app.color.text_color'))
+                    .margin({ left: this.currentLyricAlignMode === 0 ? 18 : 0 })
+                }
+
 
-                Text(this.currentYear)
-                  .fontSize(16)
-                  .padding({ top: 8 })
-                  .maxLines(1)
-                  .fontWeight(FontWeight.Bold)
-                  .fontColor($r('app.color.text_color'))
-                  .margin({ left: this.currentLyricAlignMode === 0 ? 18 : 0 })
               }
-              Row() {
-                Text(`共${this.videoLocalList.length}首歌`)
-                  .fontSize(13)
-                  .fontWeight(FontWeight.Bold)
-                  .padding({ top: 8 })
-                  .fontColor($r('app.color.text_color'))
-                  .margin({ left: this.currentLyricAlignMode === 0 ? 18 : 0 })
-                Blank()
+              if(this.modeType != 3){
+                Row() {
+                  Text(`共${this.videoLocalList.length}首歌`)
+                    .fontSize(13)
+                    .fontWeight(FontWeight.Bold)
+                    .padding({ top: 8 })
+                    .fontColor($r('app.color.text_color'))
+                    .margin({ left: this.currentLyricAlignMode === 0 ? 18 : 0 })
+                  Blank()
 
+                }
               }
 
+
             }
             .height('100%')
             .width('100%')
@@ -4456,7 +4475,7 @@ export struct LocalMusic {
             })
               .color(this.themeColor)// 进度条前景色为灰色
               .backgroundColor($r('app.color.index_background'))
-              .height(36)
+              .height(40)
               .aspectRatio(CommonConstants.ASPECT_RATIO)
             Image(this.CONTROL_PlayStatus === PlayStatus.PLAY ? $r('app.media.hm_pause') : $r('app.media.hm_play2'))
               .height(38)