Issue 2444. Minor UI update.

git-svn-id: http://xe-core.googlecode.com/svn/branches/maserati@11427 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
ChanMyeong 2012-09-21 05:39:05 +00:00
parent 273684f942
commit 6cd35aba63

View file

@ -1029,22 +1029,17 @@ setTimeout(function(){
$('input[type="file"]').change(function(){
$(this).closest('form').submit();
});
var $fileBtn = $('.fileTrigger, .fileRemover');
$fileBtn.click(function(){
var $this = $(this);
var $fileRemover = $this.parent('.btnBoth').children('.fileRemover');
setTimeout(function(){
var imgLength = $this.closest('form').find('>figure>img').length; // hasImage
if(imgLength){
$fileRemover.show(); // Show remover
function fileRemoverToggle(){ // fileRemover toggle
$('.fileRemover').each(function(){
var $this = $(this);
if($this.closest('form').find('>figure>img').length){
$this.show(); // Show remover
} else {
$fileRemover.hide(); // Hide remover
$this.hide(); // Hide remover
}
}, 1000);
});
$(window).load(function(){
$fileBtn.trigger('click');
});
});
}
fileRemoverToggle();
// Theme(layout | skin) list toggle
$('.theme .list').each(function(){
var $this = $(this);