config/qtile: properly hide brightness widget when not supported

This commit is contained in:
Infinidoge 2023-10-31 09:34:44 -04:00
parent c1bca8235b
commit 1aaf38d3e6

View file

@ -628,7 +628,8 @@ def init_widget_list(main=True, laptop=False):
]
laptop_widgets = [
(
*(
[
[
widget.TextBox(text=" 🔆", padding=0, fontsize=14),
widget.Backlight(
@ -638,6 +639,7 @@ def init_widget_list(main=True, laptop=False):
padding=5,
),
]
]
if (backlight := run_command("brightnessctl -lm --class=backlight"))
else []
),