Windows 8手机 - 动态显示图像 [英] Windows 8 phone - displaying images dynamically

查看:77
本文介绍了Windows 8手机 - 动态显示图像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我们正在开发一个wp8应用程序,它显示来自REST服务的图像数量。


假设我们要显示500张图片。当我们下载所有图像时,我们将失去内存异常。我们想要显示例如同时10-20张图片。当用户向下或向上滚动时,下载更多图像。


问题是否有任何API可用于处理缓存机制?有没有其他想法来解决这个问题?


谢谢,



问候,


Thaya N

解决方案

您好,


VirtualizingStackPanel应该执行技巧。


VirtualizingStackPanel


http://msdn.microsoft.com/en-us/library/windowsphone/develop/windows.ui.xaml.controls.virtualizingstackpanel.aspx


我希望这有帮助,


James


Hi,

We are developing a wp8 app which is displaying number of images, which coming from via a REST service.

Let say that we have 500 images to display. And we are getting out of memory exception when we download all images. And we want to display e.g. 10-20 images at the same time. And when a user scroll Down or Up, further images download.

Question is there any API we can use to handle caching mechanism? Any other idea to solv this problem?

Thanks,

Regards,

Thaya N

解决方案

Hello,

The VirtualizingStackPanel should do the trick.

VirtualizingStackPanel

http://msdn.microsoft.com/en-us/library/windowsphone/develop/windows.ui.xaml.controls.virtualizingstackpanel.aspx

I hope this helps,

James


这篇关于Windows 8手机 - 动态显示图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆