mirror of
https://github.com/jarun/nnn.git
synced 2024-11-24 20:01:27 +00:00
Combine SEL_ASIZE with related cases
This commit is contained in:
parent
7cc113ec98
commit
9c148d5789
18
src/nnn.c
18
src/nnn.c
|
@ -3152,6 +3152,7 @@ nochange:
|
||||||
case SEL_TOGGLEDOT: // fallthrough
|
case SEL_TOGGLEDOT: // fallthrough
|
||||||
case SEL_DETAIL: // fallthrough
|
case SEL_DETAIL: // fallthrough
|
||||||
case SEL_FSIZE: // fallthrough
|
case SEL_FSIZE: // fallthrough
|
||||||
|
case SEL_ASIZE: // fallthrough
|
||||||
case SEL_BSIZE: // fallthrough
|
case SEL_BSIZE: // fallthrough
|
||||||
case SEL_MTIME:
|
case SEL_MTIME:
|
||||||
switch (sel) {
|
switch (sel) {
|
||||||
|
@ -3179,6 +3180,15 @@ nochange:
|
||||||
cfg.blkorder = 0;
|
cfg.blkorder = 0;
|
||||||
cfg.copymode = 0;
|
cfg.copymode = 0;
|
||||||
break;
|
break;
|
||||||
|
case SEL_ASIZE:
|
||||||
|
cfg.apparentsz ^= 1;
|
||||||
|
if (cfg.apparentsz) {
|
||||||
|
nftw_fn = &sum_sizes;
|
||||||
|
cfg.blkorder = 1;
|
||||||
|
BLK_SHIFT = 0;
|
||||||
|
} else
|
||||||
|
cfg.blkorder = 0;
|
||||||
|
break;
|
||||||
case SEL_BSIZE:
|
case SEL_BSIZE:
|
||||||
if (sel == SEL_BSIZE) {
|
if (sel == SEL_BSIZE) {
|
||||||
if (!cfg.apparentsz)
|
if (!cfg.apparentsz)
|
||||||
|
@ -3304,14 +3314,6 @@ nochange:
|
||||||
/* Repopulate as directory content may have changed */
|
/* Repopulate as directory content may have changed */
|
||||||
goto begin;
|
goto begin;
|
||||||
}
|
}
|
||||||
case SEL_ASIZE:
|
|
||||||
cfg.apparentsz ^= 1;
|
|
||||||
if (cfg.apparentsz) {
|
|
||||||
nftw_fn = &sum_sizes;
|
|
||||||
cfg.blkorder = 1;
|
|
||||||
BLK_SHIFT = 0;
|
|
||||||
} else
|
|
||||||
cfg.blkorder = 0; // fallthrough
|
|
||||||
case SEL_COPY:
|
case SEL_COPY:
|
||||||
if (!ndents)
|
if (!ndents)
|
||||||
goto nochange;
|
goto nochange;
|
||||||
|
|
Loading…
Reference in a new issue