|
@@ -2566,6 +2566,19 @@ export struct LocalMusic {
|
|
|
})
|
|
})
|
|
|
)
|
|
)
|
|
|
Row() {
|
|
Row() {
|
|
|
|
|
+ Column(){
|
|
|
|
|
+ Text(item.md5Str?.includes('Lossless')?
|
|
|
|
|
+ Utility.resourceToString(this.context,$r('app.string.lossless')):item.md5Str)//音质
|
|
|
|
|
+ .fontSize(this.twoFingerType == 1 ? 8 : this.twoFingerType == 2 ? 9 : 11)
|
|
|
|
|
+ .padding({ top: 3,right:6,left:6,bottom:3 })
|
|
|
|
|
+ .fontColor(this.currentSong?.filePath === item.filePath ? this.themeColor :
|
|
|
|
|
+ $r('app.color.text_color'))
|
|
|
|
|
+ .fontWeight(500)
|
|
|
|
|
+ .borderRadius(12)
|
|
|
|
|
+ .margin({ left: this.twoFingerType == 3 ? 6 : 8 })
|
|
|
|
|
+ .backgroundColor('#FFC107')
|
|
|
|
|
+ }
|
|
|
|
|
+ .padding({ top: 8 })
|
|
|
Text(StrUtil.isEmpty(item.artist) ? item.cTime : item.artist + ' ' + item?.album)
|
|
Text(StrUtil.isEmpty(item.artist) ? item.cTime : item.artist + ' ' + item?.album)
|
|
|
.fontSize(this.twoFingerType == 1 ? 11 : this.twoFingerType == 2 ? 12 : 14)
|
|
.fontSize(this.twoFingerType == 1 ? 11 : this.twoFingerType == 2 ? 12 : 14)
|
|
|
.padding({ top: 8 })
|
|
.padding({ top: 8 })
|
|
@@ -3600,17 +3613,34 @@ export struct LocalMusic {
|
|
|
.fontSize(this.twoFingerType == 1 ? 10 : this.twoFingerType == 2 ? 12 : 14)
|
|
.fontSize(this.twoFingerType == 1 ? 10 : this.twoFingerType == 2 ? 12 : 14)
|
|
|
.visibility(this.modeType === 3 && !this.isCanBack ? Visibility.Visible : Visibility.None)
|
|
.visibility(this.modeType === 3 && !this.isCanBack ? Visibility.Visible : Visibility.None)
|
|
|
.fontColor($r('app.color.text_color'))
|
|
.fontColor($r('app.color.text_color'))
|
|
|
- Text(StrUtil.isEmpty(item.artist) ? 'Unknown' : item.artist)
|
|
|
|
|
- .fontSize(11)
|
|
|
|
|
- .fontSize(this.twoFingerType == 1 ? 10 : this.twoFingerType == 2 ? 12 : 14)
|
|
|
|
|
- .maxLines(1)
|
|
|
|
|
- .margin({ top: 2 })
|
|
|
|
|
- .visibility(item.type == CommonConstants.TYPE_IS_ARTIST
|
|
|
|
|
- || item.type == CommonConstants.TYPE_IS_ALBUM
|
|
|
|
|
- || item.type == CommonConstants.TYPE_IS_DIR ? Visibility.None : Visibility.Visible)
|
|
|
|
|
- .fontWeight(FontWeight.Medium)
|
|
|
|
|
- .fontColor(this.currentSong?.filePath === item.filePath ? this.themeColor :
|
|
|
|
|
- $r('app.color.text_color'))
|
|
|
|
|
|
|
+ Row(){
|
|
|
|
|
+ Column(){
|
|
|
|
|
+ Text(item.md5Str?.includes('Lossless')?
|
|
|
|
|
+ Utility.resourceToString(this.context,$r('app.string.lossless')):item.md5Str)//音质
|
|
|
|
|
+ .fontSize(this.twoFingerType == 1 ? 8 : this.twoFingerType == 2 ? 9 : 11)
|
|
|
|
|
+ .padding({ top: 3,right:6,left:6,bottom:3 })
|
|
|
|
|
+ .fontColor(this.currentSong?.filePath === item.filePath ? this.themeColor :
|
|
|
|
|
+ $r('app.color.text_color'))
|
|
|
|
|
+ .fontWeight(500)
|
|
|
|
|
+ .borderRadius(12)
|
|
|
|
|
+ .margin({ left: this.twoFingerType == 3 ? 6 : 8 })
|
|
|
|
|
+ .backgroundColor('#FFC107')
|
|
|
|
|
+ }
|
|
|
|
|
+ .margin({ top: 2 ,right:6})
|
|
|
|
|
+ Text(StrUtil.isEmpty(item.artist) ? 'Unknown' : item.artist)
|
|
|
|
|
+ .fontSize(11)
|
|
|
|
|
+ .fontSize(this.twoFingerType == 1 ? 10 : this.twoFingerType == 2 ? 12 : 14)
|
|
|
|
|
+ .maxLines(1)
|
|
|
|
|
+ .textOverflow({ overflow: TextOverflow.MARQUEE })//超长滚动
|
|
|
|
|
+ .margin({ top: 2 ,right:18})
|
|
|
|
|
+ .visibility(item.type == CommonConstants.TYPE_IS_ARTIST
|
|
|
|
|
+ || item.type == CommonConstants.TYPE_IS_ALBUM
|
|
|
|
|
+ || item.type == CommonConstants.TYPE_IS_DIR ? Visibility.None : Visibility.Visible)
|
|
|
|
|
+ .fontWeight(FontWeight.Medium)
|
|
|
|
|
+ .fontColor(this.currentSong?.filePath === item.filePath ? this.themeColor :
|
|
|
|
|
+ $r('app.color.text_color'))
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
|
|
|
}
|
|
}
|
|
|
.alignItems(HorizontalAlign.Center) // 关键:使内容水平居中
|
|
.alignItems(HorizontalAlign.Center) // 关键:使内容水平居中
|
|
@@ -5684,6 +5714,19 @@ export struct LocalMusic {
|
|
|
.maxLines(1)
|
|
.maxLines(1)
|
|
|
.margin({ left: this.twoFingerType == 3 ? 18 : 10 })
|
|
.margin({ left: this.twoFingerType == 3 ? 18 : 10 })
|
|
|
Row() {
|
|
Row() {
|
|
|
|
|
+ Column(){
|
|
|
|
|
+ Text(item.md5Str?.includes('Lossless')?
|
|
|
|
|
+ Utility.resourceToString(this.context,$r('app.string.lossless')):item.md5Str)//音质
|
|
|
|
|
+ .fontSize(this.twoFingerType == 1 ? 8 : this.twoFingerType == 2 ? 9 : 11)
|
|
|
|
|
+ .padding({ top: 3,right:6,left:6,bottom:3 })
|
|
|
|
|
+ .fontColor(this.currentSong?.filePath === item.filePath ? this.themeColor :
|
|
|
|
|
+ $r('app.color.text_color'))
|
|
|
|
|
+ .fontWeight(500)
|
|
|
|
|
+ .borderRadius(12)
|
|
|
|
|
+ .margin({ left: this.twoFingerType == 3 ? 6 : 8 })
|
|
|
|
|
+ .backgroundColor('#FFC107')
|
|
|
|
|
+ }
|
|
|
|
|
+ .padding({ top: 8 })
|
|
|
Text(StrUtil.isEmpty(item.artist) ? item.cTime : item.artist + ' ' + item?.album)
|
|
Text(StrUtil.isEmpty(item.artist) ? item.cTime : item.artist + ' ' + item?.album)
|
|
|
.fontSize(this.twoFingerType == 1 ? 11 : this.twoFingerType == 2 ? 12 : 14)
|
|
.fontSize(this.twoFingerType == 1 ? 11 : this.twoFingerType == 2 ? 12 : 14)
|
|
|
.padding({ top: 8 })
|
|
.padding({ top: 8 })
|