mirror of
https://github.com/flynx/ImageGrid.git
synced 2025-10-30 19:00:09 +00:00
some cleanup...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
57b41d04a1
commit
5985e09465
@ -1721,25 +1721,25 @@ var ConfigLocalStorageActions = actions.Actions({
|
|||||||
function(key){
|
function(key){
|
||||||
var key = key || this.config['config-local-storage-key']
|
var key = key || this.config['config-local-storage-key']
|
||||||
|
|
||||||
// build a diff...
|
|
||||||
if(this.config['config-local-storage-save-diff']){
|
|
||||||
var base = this.__base_config || {}
|
|
||||||
var cur = this.config
|
|
||||||
var config = {}
|
|
||||||
Object.keys(cur)
|
|
||||||
.forEach(function(e){
|
|
||||||
if(cur.hasOwnProperty(e) && base[e] != cur[e]){
|
|
||||||
config[e] = cur[e]
|
|
||||||
}
|
|
||||||
})
|
|
||||||
console.log('!!!!', config)
|
|
||||||
|
|
||||||
// full save...
|
|
||||||
} else {
|
|
||||||
var config = this.config
|
|
||||||
}
|
|
||||||
|
|
||||||
if(key != null){
|
if(key != null){
|
||||||
|
// build a diff...
|
||||||
|
if(this.config['config-local-storage-save-diff']){
|
||||||
|
var base = this.__base_config || {}
|
||||||
|
var cur = this.config
|
||||||
|
var config = {}
|
||||||
|
Object.keys(cur)
|
||||||
|
.forEach(function(e){
|
||||||
|
if(cur.hasOwnProperty(e) && base[e] != cur[e]){
|
||||||
|
config[e] = cur[e]
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
// full save...
|
||||||
|
} else {
|
||||||
|
var config = this.config
|
||||||
|
}
|
||||||
|
|
||||||
|
// store...
|
||||||
localStorage[key] = JSON.stringify(config)
|
localStorage[key] = JSON.stringify(config)
|
||||||
}
|
}
|
||||||
}],
|
}],
|
||||||
@ -3690,7 +3690,6 @@ var AppControlActions = actions.Actions({
|
|||||||
'application-window': null,
|
'application-window': null,
|
||||||
|
|
||||||
'window-title': 'ImageGrid.Viewer (${VERSION}): ${FILENAME}',
|
'window-title': 'ImageGrid.Viewer (${VERSION}): ${FILENAME}',
|
||||||
'window-title': 'ImageGrid.Viewer (${VERSION}): ${FILENAME}',
|
|
||||||
},
|
},
|
||||||
|
|
||||||
// XXX revise these...
|
// XXX revise these...
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user