mirror of
https://github.com/dylanaraps/pywal.git
synced 2025-05-22 01:00:56 +02:00
wallpaper: revert changes
This commit is contained in:
parent
05ef9be124
commit
e03ad5c70e
@ -31,8 +31,6 @@ def get_desktop_env():
|
|||||||
if desktop:
|
if desktop:
|
||||||
return "SWAY"
|
return "SWAY"
|
||||||
|
|
||||||
return "WM"
|
|
||||||
|
|
||||||
|
|
||||||
def xfconf(path, img):
|
def xfconf(path, img):
|
||||||
"""Call xfconf to set the wallpaper on XFCE."""
|
"""Call xfconf to set the wallpaper on XFCE."""
|
||||||
@ -66,10 +64,7 @@ def set_desktop_wallpaper(desktop, img):
|
|||||||
"""Set the wallpaper for the desktop environment."""
|
"""Set the wallpaper for the desktop environment."""
|
||||||
desktop = str(desktop).lower()
|
desktop = str(desktop).lower()
|
||||||
|
|
||||||
if desktop == "wm":
|
if "xfce" in desktop or "xubuntu" in desktop:
|
||||||
set_wm_wallpaper(img)
|
|
||||||
|
|
||||||
elif "xfce" in desktop or "xubuntu" in desktop:
|
|
||||||
# XFCE requires two commands since they differ between versions.
|
# XFCE requires two commands since they differ between versions.
|
||||||
xfconf("/backdrop/screen0/monitor0/image-path", img)
|
xfconf("/backdrop/screen0/monitor0/image-path", img)
|
||||||
xfconf("/backdrop/screen0/monitor0/workspace0/last-image", img)
|
xfconf("/backdrop/screen0/monitor0/workspace0/last-image", img)
|
||||||
@ -91,6 +86,9 @@ def set_desktop_wallpaper(desktop, img):
|
|||||||
elif "sway" in desktop:
|
elif "sway" in desktop:
|
||||||
util.disown(["swaymsg", "output", "*", "bg", img, "fill"])
|
util.disown(["swaymsg", "output", "*", "bg", img, "fill"])
|
||||||
|
|
||||||
|
else:
|
||||||
|
set_wm_wallpaper(img)
|
||||||
|
|
||||||
|
|
||||||
def set_mac_wallpaper(img):
|
def set_mac_wallpaper(img):
|
||||||
"""Set the wallpaper on macOS."""
|
"""Set the wallpaper on macOS."""
|
||||||
|
Loading…
Reference in New Issue
Block a user