我正在设置ImageUrl
a StyledStringElement
,但不知道 url 是否存在。我想放入一个placeholder image
在成功下载图像之前使用的:
var item = new StyledStringElement(n.Title);
item.ImageUri = new Uri(n.ImageThumbUrl);
我现在明白了:
我正在设置ImageUrl
a StyledStringElement
,但不知道 url 是否存在。我想放入一个placeholder image
在成功下载图像之前使用的:
var item = new StyledStringElement(n.Title);
item.ImageUri = new Uri(n.ImageThumbUrl);
我现在明白了:
有帮助:http: //yusinto.blogspot.ca/2012/05/background-image-downloading-with.html
我将其复制StyledStringElement
到一个新的StyledStringElementLoader
并编辑了此代码:
if (extraInfo.Uri != null)
{ img = ImageLoader.DefaultRequestImage (extraInfo.Uri, this);
if(img==null)
img=myLoaderImagePassedToConstructor;
}