如何在Windows Phone 7应用程序的一个版本缓存? [英] How does one release cache of application in Windows Phone 7?
问题描述
在我的项目,我创建图像的控制。我也有一个按钮,点击后删除图像。
In my project, I create an image control. I also have a button that, when clicked removes the image.
我设置图像的URL为空,并设置图像控件本身为null。然而,并非Image控件的所有内存被释放。如果我添加更多的图像控制,我的项目会很容易耗尽内存
I set the url of the image to null, and set the image control itself to null. However, not all memory of the Image control is released. If I add more Image controls, my project will be very prone to run out of memory.
- 当我启动应用程序:内存使用率= 5.218Kb
- 当我删除图像控制:内存使用率= 5.416Kb
如何当控制已被删除或重新加载到释放内存/缓存? ?
我如何管理应用程序的内存
How does one release the memory / cache when the control has been removed or loaded again? How can I manage the application's memory?
推荐答案
不知道,如果这仍然是实际的,但试试这个: 图片下载,自动清洗。示例项目在这里: https://simca.codeplex.com/
Not sure, if this is still actual, but try this: Image downloader with auto cleaning. Sample project here: https://simca.codeplex.com/
这篇关于如何在Windows Phone 7应用程序的一个版本缓存?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!