Skip to content

Commit 19f10c0

Browse files
committed
fixed album centering
1 parent e1398b8 commit 19f10c0

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/mediaplayer

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -504,14 +504,15 @@ def update_progressbar(manager, player):
504504
if t == lyrics_ix:
505505
curr_line = len(s) - 1
506506
# -- Tooltip
507+
# Check if album is empty before centering
508+
has_album = s[2].strip() != ""
507509
center_text(s, text_len)
508510
if curr_line:
509511
s[curr_line] = "<b>" + s[curr_line] + "</b>"
510512
tooltip = f"<span variant='title-caps' font_weight='bold'>{s[0]}</span>"
511513
tooltip += f"\n{s[1]}"
512514
# Skip album in tooltip if we don't have it
513-
s[2] = s[2].strip()
514-
if s[2]:
515+
if has_album:
515516
tooltip += f"\n<i>{s[2]}</i>"
516517
if len(s) >= 4 and s[3].strip():
517518
tooltip += "\n"

0 commit comments

Comments
 (0)