mirror of
https://github.com/flynx/ImageGrid.git
synced 2025-10-30 19:00:09 +00:00
cleanup...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
79543ea851
commit
936b076e9f
@ -40,22 +40,6 @@ var makeStateIndicatorItem = function(container, type, text){
|
|||||||
return item
|
return item
|
||||||
}
|
}
|
||||||
|
|
||||||
// XXX should we use this or makeStateIndicatorItem(..)???
|
|
||||||
// ...investigate the features of the above...
|
|
||||||
// - .attr('text')???
|
|
||||||
var makeExpandingInfoItem = function(container, cls, align, full_only){
|
|
||||||
var e = $('<span>')
|
|
||||||
.addClass(cls + ' expanding-text ')
|
|
||||||
.append($('<span class="shown">'))
|
|
||||||
.append($('<span class="hidden">'))
|
|
||||||
return e
|
|
||||||
}
|
|
||||||
var makeInfoItem = function(container, cls, align, full_only){
|
|
||||||
var e = $('<span>')
|
|
||||||
.addClass(cls)
|
|
||||||
return e
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||||
|
|
||||||
@ -99,6 +83,7 @@ var ImageStateIndicatorActions = actions.Actions({
|
|||||||
// NOTE: alias loops are ignored.
|
// NOTE: alias loops are ignored.
|
||||||
//
|
//
|
||||||
// XXX make this visible to the user???
|
// XXX make this visible to the user???
|
||||||
|
// XXX is this too complex???
|
||||||
__state_indicator_elements__: {
|
__state_indicator_elements__: {
|
||||||
index: function(action, container, elem, gid){
|
index: function(action, container, elem, gid){
|
||||||
// construct...
|
// construct...
|
||||||
@ -187,7 +172,6 @@ var ImageStateIndicatorActions = actions.Actions({
|
|||||||
bookmark: 'mark',
|
bookmark: 'mark',
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
updateStateIndicators: ['- Interface/',
|
updateStateIndicators: ['- Interface/',
|
||||||
function(gid){
|
function(gid){
|
||||||
gid = gid || this.current
|
gid = gid || this.current
|
||||||
@ -204,7 +188,7 @@ var ImageStateIndicatorActions = actions.Actions({
|
|||||||
|| (ImageStateIndicatorActions.__state_indicator_elements__ || {})[key]
|
|| (ImageStateIndicatorActions.__state_indicator_elements__ || {})[key]
|
||||||
|
|
||||||
if(handler == null){
|
if(handler == null){
|
||||||
return handler
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
// handle aliases...
|
// handle aliases...
|
||||||
@ -247,9 +231,9 @@ var ImageStateIndicatorActions = actions.Actions({
|
|||||||
if(elem == '---'){
|
if(elem == '---'){
|
||||||
align = 'float-right'
|
align = 'float-right'
|
||||||
|
|
||||||
|
// handlers...
|
||||||
} else {
|
} else {
|
||||||
var handler = _getHandler(elem)
|
var handler = _getHandler(elem)
|
||||||
|
|
||||||
// do the call...
|
// do the call...
|
||||||
if(handler != null){
|
if(handler != null){
|
||||||
res = handler.call(that, 'make', global, elem, gid)
|
res = handler.call(that, 'make', global, elem, gid)
|
||||||
@ -262,9 +246,8 @@ var ImageStateIndicatorActions = actions.Actions({
|
|||||||
.appendTo(global)
|
.appendTo(global)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
// add and init in the correct state...
|
||||||
global.appendTo(this.ribbons.viewer)
|
global.appendTo(this.ribbons.viewer)
|
||||||
|
|
||||||
// init in the correct state...
|
|
||||||
if(this.config['global-state-indicator-mode']){
|
if(this.config['global-state-indicator-mode']){
|
||||||
this.toggleStateIndicator(this.config['global-state-indicator-mode'])
|
this.toggleStateIndicator(this.config['global-state-indicator-mode'])
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user