mirror of
https://github.com/flynx/ImageGrid.git
synced 2025-10-29 18:30:09 +00:00
minor fix and notes...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
a6052978a8
commit
ecbcfabb64
@ -1044,7 +1044,6 @@ var CollectionActions = actions.Actions({
|
|||||||
delete this.location.collection
|
delete this.location.collection
|
||||||
}],
|
}],
|
||||||
|
|
||||||
|
|
||||||
// Config and interface stuff...
|
// Config and interface stuff...
|
||||||
//
|
//
|
||||||
toggleCollectionCropRetention: ['Interface/Collection crop save mode',
|
toggleCollectionCropRetention: ['Interface/Collection crop save mode',
|
||||||
@ -1413,6 +1412,9 @@ module.Collection = core.ImageGridFeatures.Feature({
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
}],
|
}],
|
||||||
|
// XXX merge multiple collections...
|
||||||
|
// ...this can be called multiple times pre single load, once
|
||||||
|
// per merged index...
|
||||||
['prepareJSONForLoad',
|
['prepareJSONForLoad',
|
||||||
function(res, json, base_path){
|
function(res, json, base_path){
|
||||||
// collection index...
|
// collection index...
|
||||||
@ -2029,10 +2031,18 @@ var UICollectionActions = actions.Actions({
|
|||||||
}
|
}
|
||||||
|
|
||||||
// update collection list if changed externally...
|
// update collection list if changed externally...
|
||||||
collections.splice.apply(collections, [0, collections.length].concat(
|
collections.splice.apply(collections,
|
||||||
collections
|
// NOTE: if the length calculation here looks a "bit"
|
||||||
.concat(that.collection_order || [])
|
// convoluted, that's because it is, this fixes
|
||||||
.unique()))
|
// a really odd bug in old Chrome versions where
|
||||||
|
// L.splice(0, L.length, ...)
|
||||||
|
// in some odd conditions leaves an element
|
||||||
|
// in the original array...
|
||||||
|
// (is a jit error???)
|
||||||
|
[0, (that.collection_order || []).length + collections.length]
|
||||||
|
.concat(collections
|
||||||
|
.concat(that.collection_order || [])
|
||||||
|
.unique()))
|
||||||
|
|
||||||
// main collection...
|
// main collection...
|
||||||
!action
|
!action
|
||||||
@ -2349,6 +2359,12 @@ var FileSystemCollectionActions = actions.Actions({
|
|||||||
// }
|
// }
|
||||||
collections: null,
|
collections: null,
|
||||||
|
|
||||||
|
// XXX this does not work for merged indexes as each index has
|
||||||
|
// different gids and paths for same collection title...
|
||||||
|
// ...need to merge these correctly...
|
||||||
|
// - merge collections by title
|
||||||
|
// - multiple gids
|
||||||
|
// - multiple paths
|
||||||
collectionPathLoader: ['- Collections/',
|
collectionPathLoader: ['- Collections/',
|
||||||
{collectionFormat: 'path'},
|
{collectionFormat: 'path'},
|
||||||
function(title, state, logger){
|
function(title, state, logger){
|
||||||
@ -2368,6 +2384,7 @@ var FileSystemCollectionActions = actions.Actions({
|
|||||||
path = util.normalizePath([
|
path = util.normalizePath([
|
||||||
path,
|
path,
|
||||||
that.config['index-dir'],
|
that.config['index-dir'],
|
||||||
|
// XXX use index-specific path...
|
||||||
state.path,
|
state.path,
|
||||||
].join('/'))
|
].join('/'))
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user