Replace delete icon with spinner

This commit is contained in:
Victor Dubiniuk 2013-07-29 19:27:11 +03:00
parent 2a42021815
commit 33fe24dc3d
2 changed files with 5 additions and 7 deletions

View File

@ -371,9 +371,7 @@ var FileList={
}
for (var i=0; i<files.length; i++) {
var deleteAction = $('tr').filterAttr('data-file',files[i]).children("td.date").children(".action.delete");
var oldHTML = deleteAction.html();
var newHTML = '<img class="move2trash" data-action="Delete" title="'+t('files', 'perform delete operation')+'" src="'+ OC.imagePath('core', 'loading.gif') +'"></a>';
deleteAction.html(newHTML);
deleteAction.removeClass('delete-icon').addClass('progress-icon');
}
// Finish any existing actions
if (FileList.lastAction) {
@ -394,8 +392,8 @@ var FileList={
procesSelection();
} else {
$.each(files,function(index,file) {
var deleteAction = $('tr').filterAttr('data-file',file).children("td.date").children(".move2trash");
deleteAction.html(oldHTML);
var deleteAction = $('tr').filterAttr('data-file',files[i]).children("td.date").children(".action.delete");
deleteAction.removeClass('progress-icon').addClass('delete-icon');
});
}
});

View File

@ -659,7 +659,7 @@ div.crumb:active {
}
/* icons */
.folder-icon, .delete-icon, .edit-icon {
.folder-icon, .delete-icon, .edit-icon, .progress-icon {
background-repeat: no-repeat;
background-position: center;
}
@ -669,7 +669,7 @@ div.crumb:active {
background-image: url('../img/actions/delete-hover.svg');
}
.edit-icon { background-image: url('../img/actions/rename.svg'); }
.progress-icon { background-image: url('../img/loading.gif'); }
/* buttons */
button.loading {