mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-23 04:51:32 +01:00
dark skin for reals (#7084)
This passed review with (#7035) let's get this.
This commit is contained in:
@@ -7,6 +7,7 @@
|
||||
S["UI_style_color"] >> pref.UI_style_color
|
||||
S["UI_style_alpha"] >> pref.UI_style_alpha
|
||||
S["html_UI_style"] >> pref.html_UI_style
|
||||
S["skin_theme"] >> pref.skin_theme
|
||||
S["ooccolor"] >> pref.ooccolor
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/ui/save_preferences(var/savefile/S)
|
||||
@@ -14,6 +15,7 @@
|
||||
S["UI_style_color"] << pref.UI_style_color
|
||||
S["UI_style_alpha"] << pref.UI_style_alpha
|
||||
S["html_UI_style"] << pref.html_UI_style
|
||||
S["skin_theme"] << pref.skin_theme
|
||||
S["ooccolor"] << pref.ooccolor
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/ui/gather_load_query()
|
||||
@@ -24,6 +26,7 @@
|
||||
"UI_style_color",
|
||||
"UI_style_alpha",
|
||||
"html_UI_style",
|
||||
"skin_theme",
|
||||
"ooccolor"
|
||||
),
|
||||
"args" = list("ckey")
|
||||
@@ -40,6 +43,7 @@
|
||||
"UI_style_color",
|
||||
"UI_style_alpha",
|
||||
"html_UI_style",
|
||||
"skin_theme",
|
||||
"ooccolor",
|
||||
"ckey" = 1
|
||||
)
|
||||
@@ -52,6 +56,7 @@
|
||||
"UI_style_color" = pref.UI_style_color,
|
||||
"UI_style" = pref.UI_style,
|
||||
"html_UI_style" = pref.html_UI_style,
|
||||
"skin_theme" = pref.skin_theme,
|
||||
"ooccolor" = pref.ooccolor
|
||||
)
|
||||
|
||||
@@ -59,7 +64,8 @@
|
||||
pref.UI_style = sanitize_inlist(pref.UI_style, all_ui_styles, initial(pref.UI_style))
|
||||
pref.UI_style_color = sanitize_hexcolor(pref.UI_style_color, initial(pref.UI_style_color))
|
||||
pref.UI_style_alpha = sanitize_integer(text2num(pref.UI_style_alpha), 0, 255, initial(pref.UI_style_alpha))
|
||||
pref.html_UI_style = sanitize_inlist(pref.html_UI_style, SSvueui.available_html_themes, initial(pref.html_UI_style))
|
||||
pref.html_UI_style = sanitize_inlist(pref.html_UI_style, SStheming.available_html_themes, initial(pref.html_UI_style))
|
||||
pref.skin_theme = sanitize_inlist(pref.skin_theme, SStheming.skin_themes, initial(pref.skin_theme))
|
||||
pref.ooccolor = sanitize_hexcolor(pref.ooccolor, initial(pref.ooccolor))
|
||||
|
||||
/datum/category_item/player_setup_item/player_global/ui/content(mob/user)
|
||||
@@ -70,6 +76,7 @@
|
||||
dat += "-Color: <a href='?src=\ref[src];select_color=1'><b>[pref.UI_style_color]</b></a> [HTML_RECT(pref.UI_style_color)] - <a href='?src=\ref[src];reset=ui'>reset</a><br>"
|
||||
dat += "-Alpha(transparency): <a href='?src=\ref[src];select_alpha=1'><b>[pref.UI_style_alpha]</b></a> - <a href='?src=\ref[src];reset=alpha'>reset</a><br>"
|
||||
dat += "<b>HTML UI Style:</b> <a href='?src=\ref[src];select_html=1'><b>[pref.html_UI_style]</b></a><br>"
|
||||
dat += "<b>Main UI Style:</b> <a href='?src=\ref[src];select_skin_theme=1'><b>[pref.skin_theme]</b></a><br>"
|
||||
if(can_select_ooc_color(user))
|
||||
dat += "<b>OOC Color:</b> "
|
||||
if(pref.ooccolor == initial(pref.ooccolor))
|
||||
@@ -99,11 +106,19 @@
|
||||
return TOPIC_REFRESH
|
||||
|
||||
else if(href_list["select_html"])
|
||||
var/html_style_new = input(user, "Choose HTML UI style.", "Global Preference", pref.html_UI_style) as null|anything in SSvueui.available_html_themes
|
||||
var/html_style_new = input(user, "Choose HTML UI style.", "Global Preference", pref.html_UI_style) as null|anything in SStheming.available_html_themes
|
||||
if(isnull(html_style_new) || !CanUseTopic(user)) return TOPIC_NOACTION
|
||||
pref.html_UI_style = html_style_new
|
||||
return TOPIC_REFRESH
|
||||
|
||||
else if(href_list["select_skin_theme"])
|
||||
var/skin_theme_new = input(user, "Choose HTML UI style.", "Global Preference", pref.skin_theme) as null|anything in SStheming.skin_themes
|
||||
if(isnull(skin_theme_new) || !CanUseTopic(user)) return TOPIC_NOACTION
|
||||
pref.skin_theme = skin_theme_new
|
||||
if(SStheming)
|
||||
SStheming.apply_theme_from_perfs(user)
|
||||
return TOPIC_REFRESH
|
||||
|
||||
else if(href_list["select_ooc_color"])
|
||||
var/new_ooccolor = input(user, "Choose OOC color:", "Global Preference") as color|null
|
||||
if(new_ooccolor && can_select_ooc_color(user) && CanUseTopic(user))
|
||||
|
||||
Reference in New Issue
Block a user