private void CreateGifAnimation(MemoryStream memoryStream) { _gifAnimation = new GifAnimation(); _gifAnimation.CreateGifAnimation(memoryStream); _gifAnimation.Stretch = Stretch; _gifAnimation.StretchDirection = StretchDirection; AddChild(_gifAnimation); }
private void DeletePreviousImage() { if (_image != null) { RemoveLogicalChild(_image); _image = null; } if (_gifAnimation != null) { RemoveLogicalChild(_gifAnimation); _gifAnimation = null; } }