mirror of
https://github.com/flynx/ImageGrid.git
synced 2025-10-29 10:20:08 +00:00
experimenting with iteration...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
8079465018
commit
d47af07fd9
@ -1916,6 +1916,18 @@ var BaseBrowserPrototype = {
|
|||||||
return false },
|
return false },
|
||||||
|
|
||||||
|
|
||||||
|
// XXX EXPERIMENTAL -- an attempt to simplify walking...
|
||||||
|
walk2: function(func, options){
|
||||||
|
return this.items
|
||||||
|
.map(function(elem){
|
||||||
|
return elem instanceof BaseBrowser ?
|
||||||
|
: elem instanceof BaseItem ?
|
||||||
|
: elem.children ?
|
||||||
|
: elem
|
||||||
|
})
|
||||||
|
.flat() },
|
||||||
|
|
||||||
|
|
||||||
// Data access and iteration...
|
// Data access and iteration...
|
||||||
|
|
||||||
// Walk the browser...
|
// Walk the browser...
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user