Label the delete operation "unshare" for files in the "Shared" folder to reduce

confusion about the operation.
This commit is contained in:
Bjoern Schiessle 2012-06-12 16:27:24 +02:00
parent f6e7c633a0
commit 8626f04f5d
1 changed files with 5 additions and 1 deletions

View File

@ -91,7 +91,11 @@ FileActions={
if(img.call){
img=img(file);
}
var html='<a href="#" original-title="' + t('files', 'Delete') + '" class="action delete" style="display:none" />';
if ($('#dir').val().indexOf('Shared') != -1) {
var html='<a href="#" original-title="' + t('files', 'Unshare') + '" class="action delete" style="display:none" />';
} else {
var html='<a href="#" original-title="' + t('files', 'Delete') + '" class="action delete" style="display:none" />';
}
var element=$(html);
if(img){
element.append($('<img src="'+img+'"/>'));