comparison src/message.h @ 46:b815621df3e3

core: remove all fixed width integers, closes #2460
author David Demelier <markand@malikania.fr>
date Wed, 15 Jan 2020 22:31:17 +0100
parents 4a06503641eb
children
comparison
equal deleted inserted replaced
45:e10fd1b6323f 46:b815621df3e3
23 * \file message.h 23 * \file message.h
24 * \brief Message dialog. 24 * \brief Message dialog.
25 */ 25 */
26 26
27 #include <stdbool.h> 27 #include <stdbool.h>
28 #include <stdint.h>
29 28
30 struct sprite; 29 struct sprite;
31 struct font; 30 struct font;
32 31
33 /** 32 /**
51 */ 50 */
52 struct message { 51 struct message {
53 const char *text[3]; /*!< (RW) lines of text to show */ 52 const char *text[3]; /*!< (RW) lines of text to show */
54 struct sprite *theme; /*!< (RW) sprite to use for the frame */ 53 struct sprite *theme; /*!< (RW) sprite to use for the frame */
55 struct texture *avatar; /*!< (RW) optional avatar */ 54 struct texture *avatar; /*!< (RW) optional avatar */
56 struct font *font; /*!< (RW) font to use */ 55 struct font *font; /*!< (RW) font to use */
57 enum message_flags flags; /*!< (RW) message flags */ 56 enum message_flags flags; /*!< (RW) message flags */
58 enum message_state state; /*!< (RO) current state */ 57 enum message_state state; /*!< (RO) current state */
59 uint16_t elapsed; /*!< (RW) elapsed time while displaying */ 58 unsigned int elapsed; /*!< (RW) elapsed time while displaying */
60 }; 59 };
61 60
62 /** 61 /**
63 * Start opening the message. This function will reset the message state and 62 * Start opening the message. This function will reset the message state and
64 * elapsed time. 63 * elapsed time.
75 * \pre msg != NULL 74 * \pre msg != NULL
76 * \param msg the message 75 * \param msg the message
77 * \param ticks the elapsed delay since last frame 76 * \param ticks the elapsed delay since last frame
78 */ 77 */
79 void 78 void
80 message_update(struct message *msg, unsigned ticks); 79 message_update(struct message *msg, unsigned int ticks);
81 80
82 /** 81 /**
83 * Draw the message into the screen. 82 * Draw the message into the screen.
84 * 83 *
85 * \pre msg != NULL 84 * \pre msg != NULL