wrapping action caching in a set of actions, still not done...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2018-04-10 17:05:59 +03:00
parent 43b82d1910
commit 5c3374fca5

View File

@ -702,6 +702,8 @@ var CacheActions = actions.Actions({
// NOTE: progress will only be displayed if .showProgress(..)
// action is available...
'pre-cache-progress': 3000,
// XXX handler cache..
},
// Cache utility method...
@ -807,6 +809,15 @@ var CacheActions = actions.Actions({
this
.clearCache()
.preCache(t) }],
toggleHandlerCache: ['System/Action handler cache',
makeConfigToggler('action-handler-cache',
['off', 'on']/*,
function(state){}*/)],
resetHanlerCache: ['System/Reset action handler cache',
function(){
delete this.__handler_cache }],
})
var Cache =
@ -831,6 +842,11 @@ module.Cache = ImageGridFeatures.Feature({
this.preCache()
: false
}],
['start',
function(){
// XXX this breaks loading...
//this.toggleHandlerCache(this.config['action-handler-cache'] || 'on')
}],
/*/ XXX clear cache when feature/action topology changes...
[[