Improved multi-monitor handling. Improved performance by removing redundant function call
This commit is contained in:
parent
8b808e6a7a
commit
fc1a8c95b8
1 changed files with 2 additions and 4 deletions
|
@ -232,8 +232,7 @@ class WallpaperLogic(_ConfigLib):
|
||||||
# HACK on this to see if this logic can be simplified. It's very ugly to check it that way.
|
# HACK on this to see if this logic can be simplified. It's very ugly to check it that way.
|
||||||
# Check if the current time is between a given and the following changing time and if so, set that wallpaper. If not, keep trying.
|
# Check if the current time is between a given and the following changing time and if so, set that wallpaper. If not, keep trying.
|
||||||
if self._time_in_range(time(int(clean_time[0]), int(clean_time[1]), int(clean_time[2])), time(int(clean_time_two[0]), int(clean_time_two[1]), int(clean_time_two[2])), datetime.now().time()):
|
if self._time_in_range(time(int(clean_time[0]), int(clean_time[1]), int(clean_time[2])), time(int(clean_time_two[0]), int(clean_time_two[1]), int(clean_time_two[2])), datetime.now().time()):
|
||||||
system(f"feh --bg-scale --no-fehbg --quiet {self.wallpaper_list[time_range]}")
|
exitcode = system(f"feh --bg-tile --no-fehbg --quiet {self.wallpaper_list[time_range]}")
|
||||||
exitcode = system(f"feh --bg-scale --no-fehbg --quiet {self.wallpaper_list[time_range]}")
|
|
||||||
has_wallpaper_been_set = self._check_system_exitcode(exitcode)
|
has_wallpaper_been_set = self._check_system_exitcode(exitcode)
|
||||||
# TODO: Add this check to _notify_user.
|
# TODO: Add this check to _notify_user.
|
||||||
if self.config_notify:
|
if self.config_notify:
|
||||||
|
@ -242,8 +241,7 @@ class WallpaperLogic(_ConfigLib):
|
||||||
else:
|
else:
|
||||||
continue
|
continue
|
||||||
|
|
||||||
system(f"feh --bg-scale --no-fehbg {self.wallpaper_list[-1]}")
|
exitcode = system(f"feh --bg-tile --no-fehbg {self.wallpaper_list[-1]}")
|
||||||
exitcode = system(f"feh --bg-scale --no-fehbg {self.wallpaper_list[-1]}")
|
|
||||||
has_wallpaper_been_set = self._check_system_exitcode(exitcode)
|
has_wallpaper_been_set = self._check_system_exitcode(exitcode)
|
||||||
if self.config_notify:
|
if self.config_notify:
|
||||||
self._notify_user()
|
self._notify_user()
|
||||||
|
|
Loading…
Reference in a new issue