[pitivi: 4/6] previewer: cache previews using the thumbnailcache
- From: Edward Hervey <edwardrv src gnome org>
- To: svn-commits-list gnome org
- Subject: [pitivi: 4/6] previewer: cache previews using the thumbnailcache
- Date: Sun, 8 Mar 2009 08:02:27 -0400 (EDT)
commit 065ce3af5e4ed743ec516de77b2b7c86b6beb785
Author: Brandon Lewis <brandon_lewis berkeley edu>
Date: Fri Mar 6 18:26:01 2009 -0800
previewer: cache previews using the thumbnailcache module
---
pitivi/previewer.py | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/pitivi/previewer.py b/pitivi/previewer.py
index d623189..d48d8b5 100644
--- a/pitivi/previewer.py
+++ b/pitivi/previewer.py
@@ -40,6 +40,7 @@ import pitivi.instance as instance
from pitivi.ui.zoominterface import Zoomable
from pitivi.log.loggable import Loggable
from pitivi.factories.file import PictureFileSourceFactory
+from pitivi.thumbnailcache import ThumbnailCache
GlobalSettings.addConfigSection("thumbnailing")
GlobalSettings.addConfigOption("thumbnailSpacingHint",
@@ -125,7 +126,7 @@ class RandomAccessPreviewer(Previewer):
def __init__(self, factory, stream_):
Previewer.__init__(self, factory, stream_)
self._queue = []
- self._cache = {}
+ self._cache = ThumbnailCache(size=100)
# FIXME:
# why doesn't this work?
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]