From: 백근훈 [mailto:knhoon.baik@samsung.com]
authorraster <raster@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Fri, 3 Dec 2010 09:36:17 +0000 (09:36 +0000)
committerraster <raster@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Fri, 3 Dec 2010 09:36:17 +0000 (09:36 +0000)
Subject: evas scalecache 관련 패치 검토 요청
...

There is the report that evas_engine_dump() does not dump scalecache.
Knhoon made a patch for that.

git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/evas@55178 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/lib/engines/common/evas_image_main.c
src/lib/engines/common/evas_image_scalecache.c

index a0f6df9..0e8d7a3 100644 (file)
@@ -124,7 +124,7 @@ evas_common_image_shutdown(void)
 EAPI void
 evas_common_image_image_all_unload(void)
 {
-   evas_common_rgba_image_scalecache_flush();
+   evas_common_rgba_image_scalecache_dump();
    evas_cache_image_unload_all(eci);
 }
 
index 8c50587..c096119 100644 (file)
@@ -360,6 +360,20 @@ evas_common_rgba_image_scalecache_size_get(void)
 }
 
 EAPI void
+evas_common_rgba_image_scalecache_dump(void)
+{
+#ifdef SCALECACHE
+   int t;
+   LKL(cache_lock);
+   t = max_cache_size;
+   max_cache_size = 0;
+   _cache_prune(NULL, 0);
+   max_cache_size = t;
+   LKU(cache_lock);
+#endif   
+}
+
+EAPI void
 evas_common_rgba_image_scalecache_flush(void)
 {
 #ifdef SCALECACHE