aboutsummaryrefslogtreecommitdiffstats
path: root/gui.h
diff options
context:
space:
mode:
authorTectu <joel@unormal.org>2012-06-25 10:40:05 +0200
committerTectu <joel@unormal.org>2012-06-25 10:40:05 +0200
commit7401ade97dbfcb851e9155bbabdb061b2b769492 (patch)
treef9561ca9c77efa4d620b70aecf0857f48fed45ee /gui.h
parente543f15633db2fc915245c5ede020c30e633c1a4 (diff)
downloaduGFX-7401ade97dbfcb851e9155bbabdb061b2b769492.tar.gz
uGFX-7401ade97dbfcb851e9155bbabdb061b2b769492.tar.bz2
uGFX-7401ade97dbfcb851e9155bbabdb061b2b769492.zip
GUI threads do now take active/inactive state
Diffstat (limited to 'gui.h')
-rw-r--r--gui.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/gui.h b/gui.h
index d0ec128a..edacf72f 100644
--- a/gui.h
+++ b/gui.h
@@ -6,7 +6,8 @@ struct button_t {
uint16_t y0;
uint16_t x1;
uint16_t y1;
- uint32_t *state;
+ uint8_t *state;
+ uint8_t *active;
uint16_t interval;
};
@@ -21,9 +22,11 @@ struct bar_t {
uint16_t valueColor;
uint16_t interval;
uint8_t *percent;
+ uint8_t *active;
};
enum {horizontal, vertical};
+enum {inactive, active};
#ifdef __cplusplus
extern "C" {
@@ -53,7 +56,7 @@ void guiInit(uint16_t updateIntervl);
*
* return: pointer to created thread
*/
-Thread *guiDrawButton(uint16_t x0, uint16_t y0, uint16_t x1, uint16_t y1, unsigned char *str, uint16_t fontColor, uint16_t buttonColor, uint16_t inverval, uint8_t *state);
+Thread *guiDrawButton(uint16_t x0, uint16_t y0, uint16_t x1, uint16_t y1, unsigned char *str, uint16_t fontColor, uint16_t buttonColor, uint16_t inverval, uint8_t *active, uint8_t *state);
/*
* Description: draws a bar graph and updates it's value
@@ -69,7 +72,7 @@ Thread *guiDrawButton(uint16_t x0, uint16_t y0, uint16_t x1, uint16_t y1, unsign
*
* return : pointer to created thread
*/
-Thread *guiDrawBarGraph(uint16_t x0, uint16_t y0, uint16_t x1, uint16_t y1, uint16_t orientation, uint16_t frameColor, uint16_t bkColor, uint16_t valueColor, uint16_t interval, uint16_t *percent);
+Thread *guiDrawBarGraph(uint16_t x0, uint16_t y0, uint16_t x1, uint16_t y1, uint16_t orientation, uint16_t frameColor, uint16_t bkColor, uint16_t valueColor, uint16_t interval, uint8_t *active, uint16_t *percent);
#ifdef __cplusplus
}