|
|
@@ -140,7 +140,7 @@ interface GeneratedObjectLiteralInterface_1 {
|
|
|
}
|
|
|
|
|
|
const ITEM_HEIGHT_SMALL: number = 48; // 列表项小高度
|
|
|
-const ITEM_HEIGHT: number = 58; // 列表项中高度
|
|
|
+const ITEM_HEIGHT: number = 65; // 列表项中高度
|
|
|
const ITEM_HEIGHT_BIG: number = 78; // 列表项大高度
|
|
|
|
|
|
//功能强大的音乐播放器
|
|
|
@@ -719,7 +719,7 @@ export struct LocalMusic {
|
|
|
this.isMemoryLastPlay = PreferencesUtil.getBooleanSync(SettingPage.iS_MEMORY_LAST_PLAY, false)
|
|
|
this.isShowTitleBar = PreferencesUtil.getBooleanSync(SettingPage.IS_SHOW_TITLTBAR, true)
|
|
|
this.isShowAllBar = PreferencesUtil.getBooleanSync(SettingPage.IS_SHOW_ALLBAR, true)
|
|
|
- this.twoFingerType = PreferencesUtil.getNumberSync(SettingPage.TWO_FINGER_TYPE, 3)
|
|
|
+ this.twoFingerType = PreferencesUtil.getNumberSync(SettingPage.TWO_FINGER_TYPE, 2)
|
|
|
this.isCoverTop = PreferencesUtil.getBooleanSync(SettingPage.IS_COVER_TOP, true)
|
|
|
this.isCircleBtn = PreferencesUtil.getBooleanSync(SettingPage.IS_CIRCLE_BTN, true)
|
|
|
this.isShowPlayPageBack = PreferencesUtil.getBooleanSync(SettingPage.IS_SHOW_PLAYPAGE_BACK, true)
|
|
|
@@ -2699,8 +2699,8 @@ export struct LocalMusic {
|
|
|
Row() {
|
|
|
Image(this.modeType !== 0 && StrUtil.isNotEmpty(item.pixelMapPath) ? item.pixelMapPath :
|
|
|
$r('app.media.music_group'))
|
|
|
- .height(this.twoFingerType == 3 ? 55 : this.twoFingerType == 2 ? 35 : 30)
|
|
|
- .width(this.twoFingerType == 3 ? 55 : this.twoFingerType == 2 ? 35 : 30)
|
|
|
+ .height(this.twoFingerType == 3 ? 55 : this.twoFingerType == 2 ? 50 : 40)
|
|
|
+ .width(this.twoFingerType == 3 ? 55 : this.twoFingerType == 2 ? 50 : 40)
|
|
|
.fillColor(this.themeColor)// .fontSize(33)
|
|
|
.alt($r('app.media.music_group'))
|
|
|
.borderRadius('100%')
|
|
|
@@ -2792,8 +2792,8 @@ export struct LocalMusic {
|
|
|
|
|
|
Image(StrUtil.isEmpty(item.pixelMapPath) ? $r('app.media.music_red') : item.pixelMapPath)
|
|
|
.fillColor(this.themeColor)
|
|
|
- .height(this.twoFingerType == 3 ? 55 : this.twoFingerType == 2 ? 35 : 30)
|
|
|
- .width(this.twoFingerType == 3 ? 55 : this.twoFingerType == 2 ? 35 : 30)
|
|
|
+ .height(this.twoFingerType == 3 ? 55 : this.twoFingerType == 2 ? 50 : 40)
|
|
|
+ .width(this.twoFingerType == 3 ? 55 : this.twoFingerType == 2 ? 50 : 40)
|
|
|
.alt($r('app.media.music_red'))
|
|
|
.borderRadius('100%')
|
|
|
.clip(true)
|
|
|
@@ -2891,14 +2891,14 @@ export struct LocalMusic {
|
|
|
.padding({ top: 8 })
|
|
|
Text(StrUtil.isEmpty(item.artist) ? item.duration
|
|
|
:this.twoFingerType==2? item.artist +' ' + item.duration
|
|
|
- : item.artist + ' ' + item?.album)
|
|
|
+ : item.artist + ' ' + item?.duration)
|
|
|
.fontSize(this.twoFingerType == 1 ? 11 : this.twoFingerType == 2 ? 12 : 14)
|
|
|
.padding({ top: 8 ,right:25})
|
|
|
.visibility(this.isShowFileName?Visibility.None:Visibility.Visible)
|
|
|
.maxLines(1)
|
|
|
.textOverflow({ overflow: this.isLongNameRoLL?TextOverflow.MARQUEE:TextOverflow.Ellipsis })//超长滚动
|
|
|
.fontColor(this.currentSong?.filePath === item.filePath ? this.themeColor :
|
|
|
- $r('app.color.text_color'))
|
|
|
+ Color.Gray)
|
|
|
.margin({ left: this.twoFingerType == 3 ? 6 : 8 })
|
|
|
Blank()
|
|
|
Text(this.isShowFileName?item.duration:item.size)
|
|
|
@@ -2908,10 +2908,9 @@ export struct LocalMusic {
|
|
|
.visibility(this.isShowFileName?Visibility.Visible:StrUtil.isEmpty(item.artist)
|
|
|
? Visibility.Visible : Visibility.None)
|
|
|
.fontColor(this.currentSong?.filePath === item.filePath ? this.themeColor :
|
|
|
- $r('app.color.text_color'))
|
|
|
+ Color.Gray)
|
|
|
.margin({ left: 10 })
|
|
|
}
|
|
|
- .visibility(this.twoFingerType==1?Visibility.None:Visibility.Visible)
|
|
|
.gesture(LongPressGesture()
|
|
|
.onAction(async () => {
|
|
|
//如果是专辑和艺术家的首页,不能长按
|
|
|
@@ -2934,6 +2933,7 @@ export struct LocalMusic {
|
|
|
}
|
|
|
.height('100%')
|
|
|
.width('100%')
|
|
|
+ .margin({ right: 10 })
|
|
|
.justifyContent(FlexAlign.Center)
|
|
|
.alignItems(HorizontalAlign.Start)
|
|
|
|
|
|
@@ -4768,7 +4768,8 @@ export struct LocalMusic {
|
|
|
.swipeAction((
|
|
|
(this.isSwipe&&this.modeType == 0 || this.modeType == 1 || ((this.modeType == 3 || this.modeType == 2) && this.isCanBack))
|
|
|
&& item.type !== CommonConstants.TYPE_IS_CSJAD &&
|
|
|
- !this.isHistory) ? { end: this.DeleteButton(item, index, item.filePath) } : {}) //左滑
|
|
|
+ !this.isHistory) ? { end: this.DeleteButton(item, index, item.filePath),
|
|
|
+ start:null,edgeEffect: SwipeEdgeEffect.None } : {}) //左滑
|
|
|
.onClick(() => {
|
|
|
if (this.isMultiSelect && item.type !== CommonConstants.TYPE_IS_DIR) {
|
|
|
const isChecked = this.selectedFiles.some(x => x.filePath == item.filePath);
|
|
|
@@ -4885,6 +4886,7 @@ export struct LocalMusic {
|
|
|
}, (item: VideoItem) => item.filePath)
|
|
|
}
|
|
|
}
|
|
|
+ .scrollBar(BarState.Off)
|
|
|
.scale({ x: this.scaleValue, y: this.scaleValue, z: 1 })
|
|
|
.gesture(PinchGesture({ fingers: 2 })
|
|
|
.onActionEnd((event: GestureEvent) => {
|
|
|
@@ -4901,7 +4903,7 @@ export struct LocalMusic {
|
|
|
this.isHiCar()&&(this.windowWidth>1800&&this.windowHeight>=1200)?{bottom:this.bottomBarHeight+98}:
|
|
|
{
|
|
|
bottom: this.isCoverOpacity() ? (this.isShowCoverHeader() ? this.topBarHeight+25 : this.topBarHeight+80)
|
|
|
- : (this.isShowCoverHeader() ? this.topBarHeight+35 : this.isHiCarSmall()?this.topBarHeight+90:this.topBarHeight+125)
|
|
|
+ : (this.isShowCoverHeader() ? this.topBarHeight+35 : this.isHiCarSmall()?this.topBarHeight+90:this.topBarHeight+165)
|
|
|
})
|
|
|
.cachedCount(6)
|
|
|
.reuseId('list_item')
|
|
|
@@ -5212,6 +5214,8 @@ export struct LocalMusic {
|
|
|
}else{
|
|
|
if (this.isGridMusic) {
|
|
|
this.scroller.scrollEdge(Edge.Top)
|
|
|
+ }else{
|
|
|
+ this.listScroller.scrollEdge(Edge.Top)
|
|
|
}
|
|
|
}
|
|
|
|
|
|
@@ -5267,6 +5271,8 @@ export struct LocalMusic {
|
|
|
}else{
|
|
|
if (this.isGridMusic) {
|
|
|
this.scroller.scrollEdge(Edge.Top)
|
|
|
+ }else{
|
|
|
+ this.listScroller.scrollEdge(Edge.Top)
|
|
|
}
|
|
|
}
|
|
|
break;
|
|
|
@@ -5622,6 +5628,7 @@ export struct LocalMusic {
|
|
|
setTimeout(() => {
|
|
|
this.getUIContext()?.animateTo({ duration: 555 }, () => {
|
|
|
this.playListScroller.scrollToIndex(this.curIndex,true, ScrollAlign.CENTER)
|
|
|
+ // this.playListScroller.scrollToIndex(1000,true, ScrollAlign.CENTER)
|
|
|
})
|
|
|
}, 123)
|
|
|
}catch (error) {
|
|
|
@@ -7295,8 +7302,7 @@ export struct LocalMusic {
|
|
|
}
|
|
|
.padding({ top: 8 })
|
|
|
Text(StrUtil.isEmpty(item.artist) ? item.duration :
|
|
|
- this.sonTwoFingerType<=2?" "+item?.duration:
|
|
|
- item.artist + ' ' + item?.album)
|
|
|
+ item.artist + ' ' + item?.duration)
|
|
|
.fontSize(this.sonTwoFingerType == 1 ? 11 : this.sonTwoFingerType == 2 ? 12 : 14)
|
|
|
.padding({ top: 8 })
|
|
|
.maxLines(1)
|
|
|
@@ -8396,12 +8402,17 @@ export struct LocalMusic {
|
|
|
Stack() {
|
|
|
|
|
|
Image(StrUtil.isEmpty(this.cover) ? this.imageLabel : this.cover)
|
|
|
- .height(55)
|
|
|
- .width(55)
|
|
|
+ .height(62)
|
|
|
+ .width(62)
|
|
|
.alt(this.imageLabel)
|
|
|
.borderRadius(8)
|
|
|
.clickEffect({ level: ClickEffectLevel.HEAVY })
|
|
|
.margin({ left: this.currentLyricAlignMode === 0 ? 28 : -15 })
|
|
|
+ .shadow({
|
|
|
+ radius: 22,
|
|
|
+ type: ShadowType.BLUR,
|
|
|
+ color: 'on_primary'
|
|
|
+ })
|
|
|
|
|
|
}
|
|
|
.width('18%')
|
|
|
@@ -9077,8 +9088,9 @@ export struct LocalMusic {
|
|
|
curve: Curve.Linear
|
|
|
})
|
|
|
.shadow({
|
|
|
- radius: 30,
|
|
|
- color: this.randomColor
|
|
|
+ radius: 22,
|
|
|
+ type: ShadowType.BLUR,
|
|
|
+ color: 'on_primary'
|
|
|
})
|
|
|
|
|
|
Column() {
|
|
|
@@ -9103,6 +9115,11 @@ export struct LocalMusic {
|
|
|
z: 1,
|
|
|
angle: this.rotateAngle
|
|
|
})
|
|
|
+ .shadow({
|
|
|
+ radius: 22,
|
|
|
+ type: ShadowType.BLUR,
|
|
|
+ color: 'on_primary'
|
|
|
+ })
|
|
|
.onClick(() => {
|
|
|
this.getImageColor()
|
|
|
})
|
|
|
@@ -9123,6 +9140,11 @@ export struct LocalMusic {
|
|
|
.clickEffect({ level: ClickEffectLevel.MIDDLE,scale:0.8 })
|
|
|
.align(Alignment.Center)//
|
|
|
.clip(true)
|
|
|
+ .shadow({
|
|
|
+ radius: 22,
|
|
|
+ type: ShadowType.BLUR,
|
|
|
+ color: 'on_primary'
|
|
|
+ })
|
|
|
.rotate({
|
|
|
x: 0,
|
|
|
y: 0,
|
|
|
@@ -13036,7 +13058,7 @@ function customPopupBuilder(dataBu: BubbleBean) {
|
|
|
})
|
|
|
})
|
|
|
}
|
|
|
-
|
|
|
+ .scrollBar(BarState.Off)
|
|
|
.width(120)
|
|
|
.divider({
|
|
|
strokeWidth: 1,
|
|
|
@@ -13117,7 +13139,7 @@ function cutPopupBuilder(dataBu: BubbleBean) {
|
|
|
})
|
|
|
})
|
|
|
}
|
|
|
-
|
|
|
+ .scrollBar(BarState.Off)
|
|
|
.width(150)
|
|
|
.divider({
|
|
|
strokeWidth: 1,
|