summaryrefslogtreecommitdiffstats
path: root/apps/files
diff options
context:
space:
mode:
authorJan-Christoph Borchardt <hey@jancborchardt.net>2014-09-23 12:39:06 +0200
committerJan-Christoph Borchardt <hey@jancborchardt.net>2014-09-23 12:39:06 +0200
commita062db4fd02feb1a0eff48eb130da7cc48c49899 (patch)
treeb0f7cd1bc321475363fbf897695c4f6824cd3c4a /apps/files
parent75593f87d547b8e24105ec18434bf5bdd0aa3447 (diff)
parent1583ae1ed65ca788868f5cb3e0e20d3f8b7b59dd (diff)
downloadnextcloud-server-a062db4fd02feb1a0eff48eb130da7cc48c49899.tar.gz
nextcloud-server-a062db4fd02feb1a0eff48eb130da7cc48c49899.zip
Merge pull request #11234 from owncloud/fix-icon-classes
Fix icon classes, disappeared delete icon
Diffstat (limited to 'apps/files')
-rw-r--r--apps/files/css/files.css9
-rw-r--r--apps/files/js/fileactions.js2
-rw-r--r--apps/files/js/filelist.js6
-rw-r--r--apps/files/tests/js/filelistSpec.js6
4 files changed, 16 insertions, 7 deletions
diff --git a/apps/files/css/files.css b/apps/files/css/files.css
index 4a8bd5bb30f..cbdfc672c87 100644
--- a/apps/files/css/files.css
+++ b/apps/files/css/files.css
@@ -393,6 +393,15 @@ table td.filename .uploadtext {
font-size: 11px;
}
+
+/* force show the loading icon, not only on hover */
+#fileList .icon-loading-small {
+ -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=100)";
+ filter:alpha(opacity=100);
+ opacity: 1 !important;
+ display: inline !important;
+}
+
#fileList img.move2trash { display:inline; margin:-8px 0; padding:16px 8px 16px 8px !important; float:right; }
#fileList a.action.delete {
position: absolute;
diff --git a/apps/files/js/fileactions.js b/apps/files/js/fileactions.js
index 4aefd61a19a..8ae0d8f1b2e 100644
--- a/apps/files/js/fileactions.js
+++ b/apps/files/js/fileactions.js
@@ -304,7 +304,7 @@
if (img.call) {
img = img(file);
}
- html = '<a href="#" original-title="' + escapeHTML(deleteTitle) + '" class="action delete delete-icon" />';
+ html = '<a href="#" original-title="' + escapeHTML(deleteTitle) + '" class="action delete icon-delete" />';
var element = $(html);
element.data('action', actions['Delete']);
element.on('click', {a: null, elem: parent, actionFunc: actions['Delete'].action}, actionHandler);
diff --git a/apps/files/js/filelist.js b/apps/files/js/filelist.js
index 1aabfb91f1f..86cba29e76c 100644
--- a/apps/files/js/filelist.js
+++ b/apps/files/js/filelist.js
@@ -1427,7 +1427,7 @@
if (files) {
for (var i=0; i<files.length; i++) {
var deleteAction = this.findFileEl(files[i]).children("td.date").children(".action.delete");
- deleteAction.removeClass('delete-icon').addClass('progress-icon');
+ deleteAction.removeClass('icon-delete').addClass('icon-loading-small');
}
}
// Finish any existing actions
@@ -1445,7 +1445,7 @@
// no files passed, delete all in current dir
params.allfiles = true;
// show spinner for all files
- this.$fileList.find('tr>td.date .action.delete').removeClass('delete-icon').addClass('progress-icon');
+ this.$fileList.find('tr>td.date .action.delete').removeClass('icon-delete').addClass('icon-loading-small');
}
$.post(OC.filePath('files', 'ajax', 'delete.php'),
@@ -1489,7 +1489,7 @@
else {
$.each(files,function(index,file) {
var deleteAction = self.findFileEl(file).find('.action.delete');
- deleteAction.removeClass('progress-icon').addClass('delete-icon');
+ deleteAction.removeClass('icon-loading-small').addClass('icon-delete');
});
}
}
diff --git a/apps/files/tests/js/filelistSpec.js b/apps/files/tests/js/filelistSpec.js
index 65a89ef85cd..94b52b395e5 100644
--- a/apps/files/tests/js/filelistSpec.js
+++ b/apps/files/tests/js/filelistSpec.js
@@ -421,15 +421,15 @@ describe('OCA.Files.FileList tests', function() {
fileList.setFiles(testFiles);
doDelete();
- expect(fileList.findFileEl('One.txt').find('.progress-icon:not(.delete-icon)').length).toEqual(1);
- expect(fileList.findFileEl('Three.pdf').find('.delete-icon:not(.progress-icon)').length).toEqual(1);
+ expect(fileList.findFileEl('One.txt').find('.icon-loading-small:not(.icon-delete)').length).toEqual(1);
+ expect(fileList.findFileEl('Three.pdf').find('.icon-delete:not(.icon-loading-small)').length).toEqual(1);
});
it('shows spinner on all files when deleting all', function() {
fileList.setFiles(testFiles);
fileList.do_delete();
- expect(fileList.$fileList.find('tr .progress-icon:not(.delete-icon)').length).toEqual(4);
+ expect(fileList.$fileList.find('tr .icon-loading-small:not(.icon-delete)').length).toEqual(4);
});
it('updates summary when deleting last file', function() {
var $summary;