mirror of
https://github.com/flynx/ImageGrid.git
synced 2025-11-01 11:50:07 +00:00
minor cleanup and tweaking...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
f1c9bdce93
commit
435961d596
@ -235,12 +235,14 @@ module.makeImageSeqOrNameCmp = function(data, get, seq){
|
|||||||
|
|
||||||
var ImagesClassPrototype =
|
var ImagesClassPrototype =
|
||||||
module.ImagesClassPrototype = {
|
module.ImagesClassPrototype = {
|
||||||
|
// XXX populate the image doc better...
|
||||||
fromArray: function(data){
|
fromArray: function(data){
|
||||||
var images = new this()
|
var images = new this()
|
||||||
// XXX stub...
|
// XXX stub...
|
||||||
var i = 0
|
var i = 0
|
||||||
data.forEach(function(path){
|
data.forEach(function(path){
|
||||||
var gid = hash('I'+i)
|
var gid = hash('I'+i)
|
||||||
|
// XXX populate the image doc better...
|
||||||
images[gid] = {
|
images[gid] = {
|
||||||
id: gid,
|
id: gid,
|
||||||
path: path,
|
path: path,
|
||||||
|
|||||||
@ -18,6 +18,7 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"fs.extra": "*",
|
"fs.extra": "*",
|
||||||
"glob": "^4.0.6",
|
"glob": "^4.0.6",
|
||||||
|
"promise": "^6.0.1",
|
||||||
"requirejs": "*"
|
"requirejs": "*"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -270,7 +270,7 @@ module.RibbonsPrototype = {
|
|||||||
// Get ribbon set scale...
|
// Get ribbon set scale...
|
||||||
//
|
//
|
||||||
getScale: function(){
|
getScale: function(){
|
||||||
return getElementScale(this.getRibbonSet())
|
return getElementScale(this.getRibbonSet()) || 1
|
||||||
},
|
},
|
||||||
|
|
||||||
// Set ribbon set scale...
|
// Set ribbon set scale...
|
||||||
@ -1113,7 +1113,9 @@ module.RibbonsPrototype = {
|
|||||||
return false
|
return false
|
||||||
})
|
})
|
||||||
// remove everything in one go...
|
// remove everything in one go...
|
||||||
unloaded.detach()
|
unloaded
|
||||||
|
.detach()
|
||||||
|
.removeClass('moving')
|
||||||
unloaded = unloaded.toArray()
|
unloaded = unloaded.toArray()
|
||||||
|
|
||||||
$(gids).each(function(i, gid){
|
$(gids).each(function(i, gid){
|
||||||
|
|||||||
@ -94,15 +94,28 @@ module.setupActions = function(viewer){
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
window.load2014 = function(){
|
/*********************************************************************/
|
||||||
return glob('l:/media/img/my/2014/*jpg')
|
// node.js specific stuff...
|
||||||
.on('end', function(l){ window.a.loadURLs(l) })
|
if(typeof(glob) != 'undefined'){
|
||||||
}
|
|
||||||
|
window.load2014 = function(){
|
||||||
|
return glob('l:/media/img/my/2014/*jpg')
|
||||||
|
.on('end', function(l){ window.a.loadURLs(l) })
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
window.loadInsta = function(){
|
window.loadInsta = function(){
|
||||||
return glob('l:/mnt/Dropbox/Instagram/fav/ALL/*+(jpg|png)')
|
return glob('l:/mnt/Dropbox/Instagram/fav/ALL/*+(jpg|png)')
|
||||||
.on('end', function(l){ window.a.loadURLs(l) })
|
.on('end', function(l){ window.a.loadURLs(l) })
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
window.loadSaved = function(){
|
||||||
|
a.data.loadJSON(require('fs').readFileSync('insta.json', 'utf-8'))
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user