I have made sure that both my config and system packages are up to date
Linux distro:
Arch Linux
The issue
When watching videos in a browser, my Waybar module displays the video title and pause/play state. However, when the video is closed or the player vanishes, the Waybar does not return to its previous state (e.g., showing CPU information), and the space reserved for the video details remains empty, resulting in the layout being stuck.
Steps to Reproduce:
Play a video in a browser.
Observe that the video details are displayed on Waybar.
Close the video or the browser.
Notice that the Waybar does not return to its original state, leaving an empty space.
Proposed Solution:
The issue can be resolved by ensuring the Waybar module properly resets to the previous state when the player vanishes. Specifically:
Modify the clear_output function to restore the previous module (e.g., CPU information) instead of writing an empty string.
Update the on_player_vanished function to check if there are no active players, and if so, call the clear_output to restore the default view.
I have read the Usage and Troubleshooting pages of the wiki:
https://end-4.github.io/dots-hyprland-wiki/en/i-i/03troubleshooting/
I have made sure that both my config and system packages are up to date
Linux distro:
Arch Linux
The issue
When watching videos in a browser, my Waybar module displays the video title and pause/play state. However, when the video is closed or the player vanishes, the Waybar does not return to its previous state (e.g., showing CPU information), and the space reserved for the video details remains empty, resulting in the layout being stuck.
Steps to Reproduce:
Proposed Solution:
The issue can be resolved by ensuring the Waybar module properly resets to the previous state when the player vanishes. Specifically:
clear_output
function to restore the previous module (e.g., CPU information) instead of writing an empty string.on_player_vanished
function to check if there are no active players, and if so, call theclear_output
to restore the default view.Code changes:
File
.config/waybar/scripts/mediaplayer.py
Update
clear_output
to display CPU data:Modify
on_player_vanished
to check for active players and reset if none exist:This resolves the issue by resetting the Waybar module back to its previous state when no players are active.