mirror of
https://github.com/9001/copyparty.git
synced 2025-08-18 01:22:13 -06:00
chrome optimizations
This commit is contained in:
parent
d52038366b
commit
8cab4c01fd
|
@ -3687,6 +3687,16 @@ var msel = (function () {
|
||||||
return;
|
return;
|
||||||
|
|
||||||
r.sel = [];
|
r.sel = [];
|
||||||
|
if (r.all && r.all.length) {
|
||||||
|
for (var a = 0; a < r.all.length; a++) {
|
||||||
|
var ao = r.all[a];
|
||||||
|
ao.sel = ebi(ao.id).closest('tr').classList.contains('sel');
|
||||||
|
if (ao.sel)
|
||||||
|
r.sel.push(ao);
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
r.all = [];
|
r.all = [];
|
||||||
var links = QSA('#files tbody td:nth-child(2) a:last-child'),
|
var links = QSA('#files tbody td:nth-child(2) a:last-child'),
|
||||||
vbase = get_evpath();
|
vbase = get_evpath();
|
||||||
|
@ -3715,8 +3725,11 @@ var msel = (function () {
|
||||||
r.load();
|
r.load();
|
||||||
return r.all;
|
return r.all;
|
||||||
};
|
};
|
||||||
r.selui = function () {
|
r.selui = function (reset) {
|
||||||
r.sel = r.all = null;
|
r.sel = null;
|
||||||
|
if (reset)
|
||||||
|
r.all = null;
|
||||||
|
|
||||||
clmod(ebi('wtoggle'), 'sel', r.getsel().length);
|
clmod(ebi('wtoggle'), 'sel', r.getsel().length);
|
||||||
thegrid.loadsel();
|
thegrid.loadsel();
|
||||||
fileman.render();
|
fileman.render();
|
||||||
|
@ -3775,7 +3788,7 @@ var msel = (function () {
|
||||||
for (var a = 0, aa = tds.length; a < aa; a++) {
|
for (var a = 0, aa = tds.length; a < aa; a++) {
|
||||||
tds[a].onclick = r.seltgl;
|
tds[a].onclick = r.seltgl;
|
||||||
}
|
}
|
||||||
r.selui();
|
r.selui(true);
|
||||||
arcfmt.render();
|
arcfmt.render();
|
||||||
fileman.render();
|
fileman.render();
|
||||||
ebi('selzip').style.display = ebi('unsearch') ? 'none' : '';
|
ebi('selzip').style.display = ebi('unsearch') ? 'none' : '';
|
||||||
|
|
Loading…
Reference in a new issue