diff options
author | inmarket <andrewh@inmarket.com.au> | 2013-06-10 17:18:01 +1000 |
---|---|---|
committer | inmarket <andrewh@inmarket.com.au> | 2013-06-10 17:18:01 +1000 |
commit | 2cb35d6815a0a12035f4792c266b688c77085620 (patch) | |
tree | 292ebc4760767d67b41f7f0e0022185afcf05067 /src/gwin/gwin.c | |
parent | 777ec6af7c1b594f7b7a9cbaaf7ead90d8fb7e8f (diff) | |
download | uGFX-2cb35d6815a0a12035f4792c266b688c77085620.tar.gz uGFX-2cb35d6815a0a12035f4792c266b688c77085620.tar.bz2 uGFX-2cb35d6815a0a12035f4792c266b688c77085620.zip |
Clean up GWIN Event assignment. Optimise event efficiency.
Diffstat (limited to 'src/gwin/gwin.c')
-rw-r--r-- | src/gwin/gwin.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/gwin/gwin.c b/src/gwin/gwin.c index 3e790d38..98e61c52 100644 --- a/src/gwin/gwin.c +++ b/src/gwin/gwin.c @@ -70,6 +70,11 @@ static color_t defaultBgColor = Black; *-----------------------------------------------*/ void _gwinInit(void) { + #if GWIN_NEED_WIDGET + extern void _gwidgetInit(void); + + _gwidgetInit(); + #endif #if GWIN_NEED_WINDOWMANAGER gfxQueueASyncInit(&_GWINList); cwm = &GNullWindowManager; @@ -79,7 +84,7 @@ void _gwinInit(void) { // Internal routine for use by GWIN components only // Initialise a window creating it dynamically if required. -GHandle _gwindowInit(GWindowObject *pgw, coord_t x, coord_t y, coord_t width, coord_t height, size_t size, const gwinVMT *vmt, uint16_t flags) { +GHandle _gwindowCreate(GWindowObject *pgw, coord_t x, coord_t y, coord_t width, coord_t height, size_t size, const gwinVMT *vmt, uint16_t flags) { // Allocate the structure if necessary if (!pgw) { if (!(pgw = (GWindowObject *)gfxAlloc(size))) @@ -146,7 +151,7 @@ void gwinSetDefaultBgColor(color_t bgclr) { *-----------------------------------------------*/ GHandle gwinCreateWindow(GWindowObject *pgw, coord_t x, coord_t y, coord_t width, coord_t height) { - return _gwindowInit(pgw, x, y, width, height, sizeof(GWindowObject), &basegwinVMT, GWIN_FLG_VISIBLE); + return _gwindowCreate(pgw, x, y, width, height, sizeof(GWindowObject), &basegwinVMT, GWIN_FLG_VISIBLE); } void gwinDestroy(GHandle gh) { |