3 namespace Tizen.NUI.Binding
5 [Xaml.TypeConversion(typeof(ImageSource))]
6 internal sealed class ImageSourceConverter : TypeConverter
8 public override object ConvertFromInvariantString(string value)
13 return Uri.TryCreate(value, UriKind.Absolute, out uri) && uri.Scheme != "file" ? ImageSource.FromUri(uri) : ImageSource.FromFile(value);
16 throw new InvalidOperationException(string.Format("Cannot convert \"{0}\" into {1}", value, typeof(ImageSource)));