protected virtual void GetImageSource(OnImageSourceCompleted onCompleted)
{
string imgUrl = this.GetImageUrl();
if (string.IsNullOrEmpty(imgUrl))
{
onCompleted(null);
}
else
{
if (imgUrl.Length > 0)
{
#if SILVERLIGHT
if (Credential.CREDENTIAL.GetUrlParameters() != null)
{
imgUrl += "&" + Credential.CREDENTIAL.GetUrlParameters();
}
#endif
BitmapImage imgSrc = null;
imgSrc = new BitmapImage
{
UriSource = new Uri(imgUrl, UriKind.Absolute),
};
onCompleted(imgSrc);
}
}
}