degesch: unseen PMs show up as highlights

I used to miss them.
This commit is contained in:
Přemysl Eric Janouch 2015-11-15 01:43:00 +01:00
parent 153d8c55d9
commit 6c7a2ce3c8
1 changed files with 3 additions and 4 deletions

View File

@ -2921,8 +2921,8 @@ log_formatter (struct app_context *ctx,
bool unseen_pm = buffer->type == BUFFER_PM bool unseen_pm = buffer->type == BUFFER_PM
&& buffer != ctx->current_buffer && buffer != ctx->current_buffer
&& !(flags & BUFFER_LINE_UNIMPORTANT); && !(flags & BUFFER_LINE_UNIMPORTANT);
if (ctx->beep_on_highlight bool important = (flags & BUFFER_LINE_HIGHLIGHT) || unseen_pm;
&& ((flags & BUFFER_LINE_HIGHLIGHT) || unseen_pm)) if (ctx->beep_on_highlight && important)
input_ding (&ctx->input); input_ding (&ctx->input);
bool can_leak = false; bool can_leak = false;
@ -2949,8 +2949,7 @@ log_formatter (struct app_context *ctx,
buffer->unseen_messages_count++; buffer->unseen_messages_count++;
if (flags & BUFFER_LINE_UNIMPORTANT) if (flags & BUFFER_LINE_UNIMPORTANT)
buffer->unseen_unimportant_count++; buffer->unseen_unimportant_count++;
if (flags & BUFFER_LINE_HIGHLIGHT) buffer->highlighted = important;
buffer->highlighted = true;
refresh_prompt (ctx); refresh_prompt (ctx);
} }