bool TryGetUriProperty(object imageSource, out AbstractProperty uriProperty) { uriProperty = null; if (imageSource == null) { return(false); } MultiImageSource miSource = imageSource as MultiImageSource; if (miSource != null) { uriProperty = miSource.UriSourceProperty; return(true); } BitmapImageSource bSource = imageSource as BitmapImageSource; if (bSource != null) { uriProperty = bSource.UriSourceProperty; return(true); } return(false); }
public override void DeepCopy(IDeepCopyable source, ICopyManager copyManager) { base.DeepCopy(source, copyManager); Detach(); MultiImageSource mis = (MultiImageSource)source; UriSource = mis.UriSource; DecodePixelWidth = mis.DecodePixelWidth; DecodePixelHeight = mis.DecodePixelHeight; Thumbnail = mis.Thumbnail; ThumbnailDimension = mis.ThumbnailDimension; Attach(); FreeData(); }