Darkmode fixes

This commit is contained in:
AffectedArc07
2019-01-30 17:34:12 +00:00
parent bad385813c
commit 2d4dfb55b7
3 changed files with 33 additions and 32 deletions
@@ -482,7 +482,10 @@
/datum/preferences/proc/SetChangelog(client/C,hash)
lastchangelog=hash
winset(C, "rpane.changelog", "background-color=none;font-style=")
if(preferences_datums[C.ckey].toggles & UI_DARKMODE)
winset(C, "rpane.changelog", "background-color=#40628a;font-color=#ffffff;font-style=none")
else
winset(C, "rpane.changelog", "background-color=none;font-style=none")
var/DBQuery/query = dbcon.NewQuery("UPDATE [format_table_name("player")] SET lastchangelog='[lastchangelog]' WHERE ckey='[C.ckey]'")
if(!query.Execute())
var/err = query.ErrorMsg()
@@ -491,3 +494,9 @@
to_chat(C, "Couldn't update your last seen changelog, please try again later.")
return
return 1
/datum/preferences/proc/UpdateChangelogButton(client/C)
if(preferences_datums[C.ckey].toggles & UI_DARKMODE)
winset(C, "rpane.changelog", "background-color=#40628a;text-color=#ffffff;font-style=none")
else
winset(C, "rpane.changelog", "background-color=none;text-color=#000000;font-style=none")