mirror of
https://github.com/jarun/nnn.git
synced 2025-03-18 20:39:45 +00:00
Set attrs in a go
This commit is contained in:
parent
5228528fac
commit
2b11601f89
1 changed files with 1 additions and 4 deletions
|
@ -3196,10 +3196,7 @@ static void print_time(const time_t *timep)
|
||||||
static void printent(const struct entry *ent, uint namecols, bool sel)
|
static void printent(const struct entry *ent, uint namecols, bool sel)
|
||||||
{
|
{
|
||||||
char ind = get_ind(ent->mode, FALSE);
|
char ind = get_ind(ent->mode, FALSE);
|
||||||
int attrs = sel ? A_REVERSE : 0;
|
int attrs = ((ind == '@' || (ent->flags & HARD_LINK)) ? A_DIM : 0) | (sel ? A_REVERSE : 0);
|
||||||
|
|
||||||
if (ind == '@' || (ent->flags & HARD_LINK))
|
|
||||||
attrs |= A_DIM;
|
|
||||||
|
|
||||||
if (!ind)
|
if (!ind)
|
||||||
++namecols;
|
++namecols;
|
||||||
|
|
Loading…
Add table
Reference in a new issue