aboutsummaryrefslogtreecommitdiff
path: root/source/nds/draw.c
diff options
context:
space:
mode:
authorNebuleon Fumika2013-05-23 20:07:48 -0400
committerNebuleon Fumika2013-05-23 20:07:48 -0400
commit3f501f9c905f24dcb80be2b4dfb8fbadad9c260b (patch)
treee3f58dcb64fd01f2d640cc80e58be471260ec8c5 /source/nds/draw.c
parent5edf465c07e3958c07a2d6f0058af78b9c8f7a97 (diff)
downloadsnes9x2005-3f501f9c905f24dcb80be2b4dfb8fbadad9c260b.tar.gz
snes9x2005-3f501f9c905f24dcb80be2b4dfb8fbadad9c260b.tar.bz2
snes9x2005-3f501f9c905f24dcb80be2b4dfb8fbadad9c260b.zip
Add support for custom main menu active/inactive, message text and background colors. Fill in default values for the purple skin in uicolors.txt.
Diffstat (limited to 'source/nds/draw.c')
-rw-r--r--source/nds/draw.c16
1 files changed, 15 insertions, 1 deletions
diff --git a/source/nds/draw.c b/source/nds/draw.c
index 793b6ca..9a96e43 100644
--- a/source/nds/draw.c
+++ b/source/nds/draw.c
@@ -106,8 +106,12 @@ struct gui_iconlist gui_icon_list[]= {
/* 34 */ {"sbutto", 76, 16, NULL}
};
+u16 COLOR_BG = COLOR16( 0, 0, 0);
u16 COLOR_INACTIVE_ITEM = COLOR16( 0, 0, 0);
u16 COLOR_ACTIVE_ITEM = COLOR16(31, 31, 31);
+u16 COLOR_MSSG = COLOR16( 0, 0, 0);
+u16 COLOR_INACTIVE_MAIN = COLOR16(31, 31, 31);
+u16 COLOR_ACTIVE_MAIN = COLOR16(31, 31, 31);
/*
@@ -624,6 +628,7 @@ void draw_hscroll_over(u32 index)
/*
* Drawing dialog
*/
+/*
void draw_dialog(void* screen_addr, u32 sx, u32 sy, u32 ex, u32 ey)
{
drawboxfill(screen_addr, sx + 5, sy + 5, ex + 5, ey + 5, COLOR_DIALOG_SHADOW);
@@ -650,6 +655,7 @@ void draw_dialog(void* screen_addr, u32 sx, u32 sy, u32 ex, u32 ey)
drawboxfill(screen_addr, sx, sy, ex, ey, COLOR_DIALOG);
}
+*/
/*
* Draw yes or no dialog
@@ -1116,10 +1122,18 @@ int color_init()
{
*colon = '\0';
u16* color = NULL;
- if (strcasecmp(current_line, "ActiveItem") == 0)
+ if (strcasecmp(current_line, "Background") == 0)
+ color = &COLOR_BG;
+ else if (strcasecmp(current_line, "ActiveItem") == 0)
color = &COLOR_ACTIVE_ITEM;
else if (strcasecmp(current_line, "InactiveItem") == 0)
color = &COLOR_INACTIVE_ITEM;
+ else if (strcasecmp(current_line, "MessageText") == 0)
+ color = &COLOR_MSSG;
+ else if (strcasecmp(current_line, "ActiveMain") == 0)
+ color = &COLOR_ACTIVE_MAIN;
+ else if (strcasecmp(current_line, "InactiveMain") == 0)
+ color = &COLOR_INACTIVE_MAIN;
if (color != NULL)
{