mirror of
https://github.com/python-pillow/Pillow.git
synced 2024-12-26 09:56:17 +03:00
Merge pull request #2742 from radarhere/player
Fixed bug where player script was skipping the first image
This commit is contained in:
commit
f3867f99f8
|
@ -22,13 +22,10 @@ from PIL import Image, ImageTk
|
|||
class UI(tkinter.Label):
|
||||
|
||||
def __init__(self, master, im):
|
||||
if isinstance(im, list):
|
||||
# list of images
|
||||
self.im = im[1:]
|
||||
im = self.im[0]
|
||||
else:
|
||||
# sequence
|
||||
self.im = im
|
||||
if isinstance(self.im, list):
|
||||
# list of images
|
||||
im = self.im.pop(0)
|
||||
|
||||
if im.mode == "1":
|
||||
self.image = ImageTk.BitmapImage(im, foreground="white")
|
||||
|
|
Loading…
Reference in New Issue
Block a user