def set_wallpaper(self): """Set the wallpaper which is being previewed.""" image = self.images[self.index] change_background(image)
def change_random(self): filename = random.choice(os.listdir(self.directory)) path = os.path.join(self.directory, filename) print("changing desktop wallpaper to: ", path) change_background(path)
def change_random(self): directory = os.path.join(CURR_DIR, PICS_FOLDER) filename = random.choice(os.listdir(directory)) path = os.path.join(directory, filename) print("changing desktop wallpaper to: ", path) change_background(path)