fix location (#19764)

This commit is contained in:
coulsonwang 2019-05-28 10:14:55 +08:00 committed by minggo
parent 23a21ef298
commit 000a5e124b
1 changed files with 8 additions and 0 deletions

View File

@ -146,6 +146,10 @@ TextureInfo& TextureInfo::operator=(TextureInfo&& rhs)
//release the textures before cleaning the vertor
rhs.releaseTextures();
rhs.textures.clear();
#if CC_ENABLE_CACHE_TEXTURE_DATA
location = rhs.location;
#endif
}
return *this;
}
@ -157,6 +161,10 @@ TextureInfo& TextureInfo::operator=(const TextureInfo& rhs)
slot = rhs.slot;
textures = rhs.textures;
retainTextures();
#if CC_ENABLE_CACHE_TEXTURE_DATA
location = rhs.location;
#endif
}
return *this;
}