summaryrefslogtreecommitdiffstats
path: root/apps/files
diff options
context:
space:
mode:
authorRobin Appelman <robin@icewind.nl>2015-10-30 12:52:04 +0100
committerRobin Appelman <robin@icewind.nl>2015-10-30 12:52:04 +0100
commit3c01386a50a791f0b1f9959707354227d4b7b98d (patch)
treee078fdbb9c5ca9dfded1895ef3cf4f9e088b3485 /apps/files
parent2e5c1f3c8f3be41eddab9c30dfae13023646f21e (diff)
parent860e31a333ef075fe49a3e785fa19122600e895e (diff)
downloadnextcloud-server-3c01386a50a791f0b1f9959707354227d4b7b98d.tar.gz
nextcloud-server-3c01386a50a791f0b1f9959707354227d4b7b98d.zip
Merge pull request #20156 from owncloud/files-filter-triger-once
dont trigger the scroll event of every single item we filter in the file list
Diffstat (limited to 'apps/files')
-rw-r--r--apps/files/js/filelist.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/apps/files/js/filelist.js b/apps/files/js/filelist.js
index 99804b1b9be..d1f68d98eab 100644
--- a/apps/files/js/filelist.js
+++ b/apps/files/js/filelist.js
@@ -2133,15 +2133,16 @@
this.hideIrrelevantUIWhenNoFilesMatch();
}
var that = this;
+ filter = filter.toLowerCase();
this.$fileList.find('tr').each(function(i,e) {
var $e = $(e);
- if ($e.data('file').toString().toLowerCase().indexOf(filter.toLowerCase()) === -1) {
+ if ($e.data('file').toString().toLowerCase().indexOf(filter) === -1) {
$e.addClass('hidden');
- that.$container.trigger('scroll');
} else {
$e.removeClass('hidden');
}
});
+ that.$container.trigger('scroll');
},
hideIrrelevantUIWhenNoFilesMatch:function() {
if (this._filter && this.fileSummary.summary.totalDirs + this.fileSummary.summary.totalFiles === 0) {