From cb7e29180fc258e43d9efa8118cf9171e9bcf84f Mon Sep 17 00:00:00 2001 From: Romain Vimont Date: Wed, 7 Feb 2018 11:47:34 +0100 Subject: [PATCH] Change the window icon color in debug mode To highlight the debug/release mode of the running application, use a different window icon color in debug mode. --- app/src/tinyxpm.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/app/src/tinyxpm.c b/app/src/tinyxpm.c index ec404a02..cb3ca071 100644 --- a/app/src/tinyxpm.c +++ b/app/src/tinyxpm.c @@ -29,6 +29,11 @@ static SDL_bool find_color(struct index *index, int len, char c, Uint32 *color) // Parameter is not "const char *" because XPM formats are generally stored in a // (non-const) "char *" SDL_Surface *read_xpm(char *xpm[]) { +#if SDL_ASSERT_LEVEL >= 2 + // patch the XPM to change the icon color in debug mode + xpm[2] = ". c #CC00CC"; +#endif + char *endptr; // *** No error handling, assume the XPM source is valid *** // (it's in our source repo)