mirror of https://github.com/kivy/kivy.git
Merge pull request #633 from kivy/attribute_keep_data
Core: Image: skip keep_data check for images created from texture
This commit is contained in:
commit
5d6b2166fb
|
@ -569,7 +569,10 @@ class Image(EventDispatcher):
|
||||||
if image:
|
if image:
|
||||||
# we found an image, yeah ! but reset the texture now.
|
# we found an image, yeah ! but reset the texture now.
|
||||||
self.image = image
|
self.image = image
|
||||||
if not image.keep_data and self._keep_data:
|
# if image.__class__ is core image then it's a texture
|
||||||
|
# from atlas or other sources and has no data so skip
|
||||||
|
if (image.__class__ != self.__class__ and
|
||||||
|
not image.keep_data and self._keep_data):
|
||||||
self.remove_from_cache()
|
self.remove_from_cache()
|
||||||
self._filename = ''
|
self._filename = ''
|
||||||
self._set_filename(value)
|
self._set_filename(value)
|
||||||
|
|
Loading…
Reference in New Issue