feat(bar): enhancing the media widget #1655
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The Media widget has been enhanced with a new MediaDisplayFormat configuration option that controls how the widget is displayed. It supports seven formats: Icon, Text, IconAndText (the default), ControlsOnly, IconAndControls, TextAndControls, and Full.
The widget now detects whether the Previous and Next buttons are actually available for the current media session using the Windows Media Control API. When a button is not available, it appears dimmed at 50 percent opacity and clicking it has no effect.
Tooltips were added to improve usability. Hovering over the media info label shows the full artist and title text, which is helpful when the text is truncated. The Play/Pause button also shows the media info on hover. The rendering logic was refactored to properly handle right-aligned widgets.
When the Media widget is placed in right_widgets, the UI renders items from right to left, so the code now renders elements in reverse order to ensure the visual appearance remains consistent regardless of which panel the widget is placed in.