mirror of
https://github.com/flynx/ImageGrid.git
synced 2025-10-28 18:00:09 +00:00
some tweaking...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
dc4eaa2973
commit
0aeb494a6b
@ -2538,7 +2538,7 @@ var FileSystemWriterUIActions = actions.Actions({
|
|||||||
var data = that.config['export-dialog-modes'][mode].data
|
var data = that.config['export-dialog-modes'][mode].data
|
||||||
|
|
||||||
// mode selector...
|
// mode selector...
|
||||||
make(['Export mode: ',
|
make(['Export $mode: ',
|
||||||
function(){ return mode }])
|
function(){ return mode }])
|
||||||
.on('open',
|
.on('open',
|
||||||
widgets.makeNestedConfigListEditor(that, o,
|
widgets.makeNestedConfigListEditor(that, o,
|
||||||
@ -2564,7 +2564,7 @@ var FileSystemWriterUIActions = actions.Actions({
|
|||||||
// Start action...
|
// Start action...
|
||||||
make([function(){
|
make([function(){
|
||||||
// XXX indicate export state: index, crop, image...
|
// XXX indicate export state: index, crop, image...
|
||||||
return 'Export'}])
|
return '$Export'}])
|
||||||
.on('open', function(){
|
.on('open', function(){
|
||||||
var mode =
|
var mode =
|
||||||
that.config['export-dialog-modes'][that.config['export-dialog-mode']]
|
that.config['export-dialog-modes'][that.config['export-dialog-mode']]
|
||||||
|
|||||||
@ -343,9 +343,13 @@ var MetadataUIActions = actions.Actions({
|
|||||||
|
|
||||||
// helpers...
|
// helpers...
|
||||||
var _cmp = function(a, b){
|
var _cmp = function(a, b){
|
||||||
a = field_order.indexOf(a[0].replace(/^- |: $/g, ''))
|
a = field_order.indexOf(a[0]
|
||||||
|
.replace(/\$(\w)/g, '$1')
|
||||||
|
.replace(/^- |: $/g, ''))
|
||||||
a = a == -1 ? x : a
|
a = a == -1 ? x : a
|
||||||
b = field_order.indexOf(b[0].replace(/^- |: $/g, ''))
|
b = field_order.indexOf(b[0]
|
||||||
|
.replace(/\$(\w)/g, '$1')
|
||||||
|
.replace(/^- |: $/g, ''))
|
||||||
b = b == -1 ? x : b
|
b = b == -1 ? x : b
|
||||||
return a - b
|
return a - b
|
||||||
}
|
}
|
||||||
@ -354,7 +358,7 @@ var MetadataUIActions = actions.Actions({
|
|||||||
// XXX move these to an info feature...
|
// XXX move these to an info feature...
|
||||||
// base fields...
|
// base fields...
|
||||||
var base = [
|
var base = [
|
||||||
['GID: ', image],
|
['$GID: ', image],
|
||||||
// NOTE: these are 1-based and not 0-based...
|
// NOTE: these are 1-based and not 0-based...
|
||||||
['Index (ribbon): ',
|
['Index (ribbon): ',
|
||||||
that.data.getImageOrder('ribbon', image) + 1
|
that.data.getImageOrder('ribbon', image) + 1
|
||||||
@ -393,11 +397,11 @@ var MetadataUIActions = actions.Actions({
|
|||||||
|
|
||||||
// paths...
|
// paths...
|
||||||
img.path
|
img.path
|
||||||
&& base.push(['File Name: ',
|
&& base.push(['File $Name: ',
|
||||||
_basename(img.path)])
|
_basename(img.path)])
|
||||||
&& base.push(['Parent Directory: ',
|
&& base.push(['Parent $Directory: ',
|
||||||
_dirname((img.base_path || '.') +'/'+ img.path)])
|
_dirname((img.base_path || '.') +'/'+ img.path)])
|
||||||
&& base.push(['Full Path: ',
|
&& base.push(['Full $Path: ',
|
||||||
_normalize((img.base_path || '.') +'/'+ img.path)])
|
_normalize((img.base_path || '.') +'/'+ img.path)])
|
||||||
|
|
||||||
// times...
|
// times...
|
||||||
@ -416,10 +420,10 @@ var MetadataUIActions = actions.Actions({
|
|||||||
}
|
}
|
||||||
|
|
||||||
// comment and tags...
|
// comment and tags...
|
||||||
info.push(['Comment: ',
|
info.push(['$Comment: ',
|
||||||
function(){ return img && img.comment || '' }])
|
function(){ return img && img.comment || '' }])
|
||||||
|
|
||||||
info.push(['Tags: ',
|
info.push(['$Tags: ',
|
||||||
function(){ return that.data.getTags().join(', ') || '' }])
|
function(){ return that.data.getTags().join(', ') || '' }])
|
||||||
|
|
||||||
// build fields...
|
// build fields...
|
||||||
|
|||||||
@ -2249,6 +2249,8 @@ var ControlActions = actions.Actions({
|
|||||||
}],
|
}],
|
||||||
|
|
||||||
|
|
||||||
|
// XXX make the enable handling check a bit more general...
|
||||||
|
// ...allow ui features to control this...
|
||||||
toggleSwipeHandling: ['Interface/Swipe handling',
|
toggleSwipeHandling: ['Interface/Swipe handling',
|
||||||
toggler.Toggler(null,
|
toggler.Toggler(null,
|
||||||
function(_, state){
|
function(_, state){
|
||||||
@ -2272,7 +2274,13 @@ var ControlActions = actions.Actions({
|
|||||||
|
|
||||||
viewer.data('hammer')
|
viewer.data('hammer')
|
||||||
.get('swipe')
|
.get('swipe')
|
||||||
.set({direction: Hammer.DIRECTION_ALL})
|
.set({
|
||||||
|
direction: Hammer.DIRECTION_ALL,
|
||||||
|
// do not handle swipes when a modal
|
||||||
|
// dialog is open...
|
||||||
|
// XXX make this more general...
|
||||||
|
enable: function(){ return !that.modal },
|
||||||
|
})
|
||||||
|
|
||||||
if(!viewer.hasClass('swipable')){
|
if(!viewer.hasClass('swipable')){
|
||||||
viewer
|
viewer
|
||||||
|
|||||||
@ -371,7 +371,7 @@ function(text, options){
|
|||||||
// skipDisabledItems: false,
|
// skipDisabledItems: false,
|
||||||
//
|
//
|
||||||
// // if true, group the items into a <span> element...
|
// // if true, group the items into a <span> element...
|
||||||
// groupList: true,
|
// groupList: false,
|
||||||
//
|
//
|
||||||
// // see: make(..) for additional option info.
|
// // see: make(..) for additional option info.
|
||||||
// ...
|
// ...
|
||||||
@ -420,7 +420,7 @@ function(data, options){
|
|||||||
res.push(elem[0])
|
res.push(elem[0])
|
||||||
})
|
})
|
||||||
|
|
||||||
options.groupList !== false
|
options.groupList
|
||||||
&& $(res).parent()
|
&& $(res).parent()
|
||||||
.append($('<div>')
|
.append($('<div>')
|
||||||
.addClass('item-group')
|
.addClass('item-group')
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user