mirror of
https://github.com/caelestia-dots/cli.git
synced 2026-06-12 03:49:59 -05:00
wallpaper: fix random for multi-monitor setup (#63)
This commit is contained in:
@@ -51,12 +51,7 @@ def get_wallpapers(args: Namespace) -> list[Path]:
|
|||||||
return walls
|
return walls
|
||||||
|
|
||||||
monitors = message("monitors")
|
monitors = message("monitors")
|
||||||
filter_size = monitors[0]["width"], monitors[0]["height"]
|
filter_size = min(m["width"] for m in monitors), min(m["height"] for m in monitors)
|
||||||
for monitor in monitors[1:]:
|
|
||||||
if filter_size[0] > monitor["width"]:
|
|
||||||
filter_size[0] = monitor["width"]
|
|
||||||
if filter_size[1] > monitor["height"]:
|
|
||||||
filter_size[1] = monitor["height"]
|
|
||||||
|
|
||||||
return [f for f in walls if check_wall(f, filter_size, args.threshold)]
|
return [f for f in walls if check_wall(f, filter_size, args.threshold)]
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user