From a27a454c4aaa2df10ab33cce34d80d3a6bf7c001 Mon Sep 17 00:00:00 2001 From: MrStonedOne Date: Wed, 30 Aug 2017 21:57:21 -0700 Subject: [PATCH] Make the fact there are hidden notes more obvious. We print the first note that would be skipped then pixel shift the show all button over the skipped noted. The rest after that are not printed --- code/modules/admin/sql_message_system.dm | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/code/modules/admin/sql_message_system.dm b/code/modules/admin/sql_message_system.dm index b70eb5ad836..a18dfa9dbd8 100644 --- a/code/modules/admin/sql_message_system.dm +++ b/code/modules/admin/sql_message_system.dm @@ -199,6 +199,7 @@ var/messagedata var/watchdata var/notedata + var/skipped = FALSE while(query_get_messages.NextRow()) type = query_get_messages.item[1] if(type == "memo") @@ -217,9 +218,12 @@ if (agegate && type == "note" && isnum(config.note_stale_days) && isnum(config.note_fresh_days) && config.note_stale_days > config.note_fresh_days) var/alpha = Clamp(100 - (age - config.note_fresh_days) * (85 / (config.note_stale_days - config.note_fresh_days)), 15, 100) if (alpha < 100) - alphatext = "filter: alpha(opacity=[alpha]); opacity: [alpha/100];" if (alpha <= 15) - alphatext += " display:none;" + if (skipped) + break + alpha = 10 + skipped = TRUE + alphatext = "filter: alpha(opacity=[alpha]); opacity: [alpha/100];" var/data data += "

[timestamp] | [server] | [admin_ckey]" @@ -265,7 +269,11 @@ output += notedata if(!linkless) if (agegate) - output += "

\[Show All\]
" + if (skipped) //the first skipped message is still shown so that we can put this link over it. + output += "
\[Show All\]
" + else + output += "
\[Show All\]
" + else output += "
\[Hide Old\]
" if(index)