diff options
author | inmarket <andrewh@inmarket.com.au> | 2013-07-07 20:11:38 +1000 |
---|---|---|
committer | inmarket <andrewh@inmarket.com.au> | 2013-07-07 20:11:38 +1000 |
commit | c5ec72027787c9cd5f5b36a46eb55f03fd95d894 (patch) | |
tree | 6cd0e65ba5ce5b0884d5cd4085795e347b5fa509 /src | |
parent | 7f92794b1151076012ad58d390f489118ad419f4 (diff) | |
download | uGFX-c5ec72027787c9cd5f5b36a46eb55f03fd95d894.tar.gz uGFX-c5ec72027787c9cd5f5b36a46eb55f03fd95d894.tar.bz2 uGFX-c5ec72027787c9cd5f5b36a46eb55f03fd95d894.zip |
Fix enabled visibility bug
Diffstat (limited to 'src')
-rw-r--r-- | src/gwin/gwin.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gwin/gwin.c b/src/gwin/gwin.c index 2fd0c905..e5997bc8 100644 --- a/src/gwin/gwin.c +++ b/src/gwin/gwin.c @@ -210,7 +210,7 @@ void gwinSetEnabled(GHandle gh, bool_t enabled) { if (enabled) { if (!(gh->flags & GWIN_FLG_ENABLED)) { gh->flags |= GWIN_FLG_ENABLED; - if (gh->vmt->Redraw) { + if ((gh->flags & GWIN_FLG_VISIBLE) && gh->vmt->Redraw) { #if GDISP_NEED_CLIP gdispSetClip(gh->x, gh->y, gh->width, gh->height); #endif @@ -220,7 +220,7 @@ void gwinSetEnabled(GHandle gh, bool_t enabled) { } else { if ((gh->flags & GWIN_FLG_ENABLED)) { gh->flags &= ~GWIN_FLG_ENABLED; - if (gh->vmt->Redraw) { + if ((gh->flags & GWIN_FLG_VISIBLE) && gh->vmt->Redraw) { #if GDISP_NEED_CLIP gdispSetClip(gh->x, gh->y, gh->width, gh->height); #endif |