From: Christian Heller Date: Sun, 8 Sep 2013 10:27:35 +0000 (+0200) Subject: Removed unneeded function; also some minor comment improvmenets. X-Git-Tag: tce~973 X-Git-Url: https://plomlompom.com/repos/%7B%7B%20web_path%20%7D%7D/decks/%7B%7Bprefix%7D%7D/static/day?a=commitdiff_plain;h=b98ec5140cb2691a729275c0a35af0071d743262;p=plomrogue Removed unneeded function; also some minor comment improvmenets. --- diff --git a/src/wincontrol.c b/src/wincontrol.c index ff0ce5d..7a4cdbd 100644 --- a/src/wincontrol.c +++ b/src/wincontrol.c @@ -30,7 +30,7 @@ static char * string_prefixed_id(struct World * world, char * prefix, char id); /* Create Winconf, initialize ->view/height_type/width_type to 0, ->id to "id" - * and ->draw to f. + * and ->draw to "f". */ static void create_winconf(char id, struct WinConf * wcp, void (* f) (struct Win *)); @@ -55,7 +55,6 @@ static void set_winconf(struct World * world, char id); /* Get WinConf by "id"; get id of WinConf mothering "win". */ static struct WinConf * get_winconf_by_id(struct World * world, char id); -static char get_id_by_win(struct World * world, struct Win * win); @@ -194,14 +193,6 @@ static struct WinConf * get_winconf_by_id(struct World * world, char id) -static char get_id_by_win(struct World * world, struct Win * win) -{ - struct WinConf * wc = get_winconf_by_win(world, win); - return wc->id; -} - - - extern struct WinConf * get_winconf_by_win(struct World * world, struct Win * win) { @@ -334,7 +325,8 @@ extern void save_win_configs(struct World * world) uint8_t i = 0; while (0 != w_p) { - line[i] = get_id_by_win(world, w_p); + struct WinConf * wc = get_winconf_by_win(world, w_p); + line[i] = wc->id; w_p = w_p->_next; i++; } diff --git a/src/wincontrol.h b/src/wincontrol.h index f56bc39..b5ccbb5 100644 --- a/src/wincontrol.h +++ b/src/wincontrol.h @@ -9,7 +9,7 @@ -#include /* for uint8_t */ +#include /* for uint8_t, int16_t */ struct Win; struct WinMeta; struct World;