mirror of
https://github.com/FBukovina/Atoll.git
synced 2026-10-27 15:14:33 +00:00
Update LiquidGlassBackground to remove polling
This commit is contained in:
parent
4ec5c84b9c
commit
1d6cdf866a
8 changed files with 145 additions and 59 deletions
|
|
@ -792,10 +792,8 @@ struct LockScreenMusicPanel: View {
|
|||
|
||||
@ViewBuilder
|
||||
private var customLiquidPanelBackdrop: some View {
|
||||
TimelineView(.periodic(from: .now, by: 1.0 / 30.0)) { context in
|
||||
LiquidGlassBackground(variant: musicGlassVariant, cornerRadius: panelCornerRadius, trigger: context.date.timeIntervalSinceReferenceDate) {
|
||||
Color.white.opacity(0.04)
|
||||
}
|
||||
LiquidGlassBackground(variant: musicGlassVariant, cornerRadius: panelCornerRadius) {
|
||||
Color.white.opacity(0.04)
|
||||
}
|
||||
.frame(maxWidth: .infinity, maxHeight: .infinity)
|
||||
.allowsHitTesting(false)
|
||||
|
|
@ -873,10 +871,8 @@ struct LockScreenMusicPanel: View {
|
|||
|
||||
@ViewBuilder
|
||||
private func customLiquidAlbumArtBackground(cornerRadius: CGFloat) -> some View {
|
||||
TimelineView(.periodic(from: .now, by: 1.0 / 30.0)) { context in
|
||||
LiquidGlassBackground(variant: musicGlassVariant, cornerRadius: cornerRadius, trigger: context.date.timeIntervalSinceReferenceDate) {
|
||||
Color.clear
|
||||
}
|
||||
LiquidGlassBackground(variant: musicGlassVariant, cornerRadius: cornerRadius) {
|
||||
Color.clear
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue