- show a spinner while decrypting files if the encryption app was disabled

- don't fade-out the decryption result
This commit is contained in:
Bjoern Schiessle 2013-11-20 12:23:10 +01:00
parent 8bc339413b
commit caf486d6e7

View File

@ -190,7 +190,7 @@ $(document).ready(function(){
var privateKeyPassword = $('#decryptAll input:password[id="privateKeyPassword"]').val(); var privateKeyPassword = $('#decryptAll input:password[id="privateKeyPassword"]').val();
OC.Encryption.decryptAll(privateKeyPassword); OC.Encryption.decryptAll(privateKeyPassword);
}); });
$('#decryptAll input:password[name="privateKeyPassword"]').keyup(function(event) { $('#decryptAll input:password[name="privateKeyPassword"]').keyup(function(event) {
var privateKeyPassword = $('#decryptAll input:password[id="privateKeyPassword"]').val(); var privateKeyPassword = $('#decryptAll input:password[id="privateKeyPassword"]').val();
if (privateKeyPassword !== '' ) { if (privateKeyPassword !== '' ) {
@ -202,7 +202,7 @@ $(document).ready(function(){
$('#decryptAll button:button[name="submitDecryptAll"]').attr("disabled", "true"); $('#decryptAll button:button[name="submitDecryptAll"]').attr("disabled", "true");
} }
}); });
var uploadparms = { var uploadparms = {
done: function(e, data) { done: function(e, data) {
avatarResponseHandler(data.result); avatarResponseHandler(data.result);
@ -261,8 +261,9 @@ OC.Encryption = {
OC.Encryption.msg={ OC.Encryption.msg={
startDecrypting:function(selector){ startDecrypting:function(selector){
var spinner = '<img src="'+ OC.imagePath('core', 'loading-small.gif') +'">';
$(selector) $(selector)
.html( t('files_encryption', 'Decrypting files... Please wait, this can take some time.') ) .html( t('files_encryption', 'Decrypting files... Please wait, this can take some time.') + ' ' + spinner )
.removeClass('success') .removeClass('success')
.removeClass('error') .removeClass('error')
.stop(true, true) .stop(true, true)
@ -273,8 +274,7 @@ OC.Encryption.msg={
$(selector).html( data.data.message ) $(selector).html( data.data.message )
.addClass('success') .addClass('success')
.stop(true, true) .stop(true, true)
.delay(3000) .delay(3000);
.fadeOut(900);
}else{ }else{
$(selector).html( data.data.message ).addClass('error'); $(selector).html( data.data.message ).addClass('error');
} }