mirror of
https://github.com/flynx/ImageGrid.git
synced 2025-10-29 10:20:08 +00:00
a better cleanup...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
b810a47fbb
commit
672bd773a6
@ -735,6 +735,7 @@ var StatusBarActions = actions.Actions({
|
|||||||
|
|
||||||
`,
|
`,
|
||||||
function(text, timeout, fadeout){
|
function(text, timeout, fadeout){
|
||||||
|
var that = this
|
||||||
timeout = timeout === true ?
|
timeout = timeout === true ?
|
||||||
1000
|
1000
|
||||||
: timeout
|
: timeout
|
||||||
@ -745,25 +746,19 @@ var StatusBarActions = actions.Actions({
|
|||||||
&& clearTimeout(this.__statusbar_info_timeout)
|
&& clearTimeout(this.__statusbar_info_timeout)
|
||||||
delete this.__statusbar_info_timeout
|
delete this.__statusbar_info_timeout
|
||||||
|
|
||||||
var bar = this.dom.find('.state-indicator-container.global-info')
|
var bar = this.dom.find('.state-indicator-container.global-info .info')
|
||||||
|
|
||||||
// update the element...
|
// update the element...
|
||||||
// show...
|
|
||||||
;(typeof(text) == typeof('str')
|
|
||||||
&& text.trim().length > 0) ?
|
|
||||||
bar.find('.info')
|
|
||||||
.empty()
|
|
||||||
.show()
|
|
||||||
.text(text)
|
|
||||||
// fadeout...
|
// fadeout...
|
||||||
: typeof(text) == typeof(123) ?
|
typeof(text) == typeof(123) ?
|
||||||
bar.find('.info')
|
bar.fadeOut(text, function(){
|
||||||
.fadeOut(text, function(){
|
that.showStatusBarInfo() })
|
||||||
$(this).empty() })
|
// show/hide...
|
||||||
// hide...
|
: bar
|
||||||
: bar.find('.info')
|
.text(text || '')
|
||||||
.empty()
|
.stop()
|
||||||
.show()
|
.show()
|
||||||
|
.css({opacity: ''})
|
||||||
|
|
||||||
// clear after timeout...
|
// clear after timeout...
|
||||||
timeout
|
timeout
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user