diff options
author | Joel Bodenmann <joel@unormal.org> | 2013-12-11 17:30:48 +0100 |
---|---|---|
committer | Joel Bodenmann <joel@unormal.org> | 2013-12-11 17:30:48 +0100 |
commit | 981282bb564bdc9c2a60e9f94d262deb1b418bcc (patch) | |
tree | 3a5c8fb2569128e89c1b5586ea806f4968a27e96 /src | |
parent | 891f134bc1a210b3b91baba189ba1d48a6a617a3 (diff) | |
download | uGFX-981282bb564bdc9c2a60e9f94d262deb1b418bcc.tar.gz uGFX-981282bb564bdc9c2a60e9f94d262deb1b418bcc.tar.bz2 uGFX-981282bb564bdc9c2a60e9f94d262deb1b418bcc.zip |
GWIN console visible bug fix
Diffstat (limited to 'src')
-rw-r--r-- | src/gwin/console.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/gwin/console.c b/src/gwin/console.c index 1be18662..7966b6ff 100644 --- a/src/gwin/console.c +++ b/src/gwin/console.c @@ -90,6 +90,9 @@ void gwinPutChar(GHandle gh, char c) { #define gcw ((GConsoleObject *)gh) uint8_t width, fy, fp; + if (!gwinGetVisible(gh)) + return; + if (gh->vmt != &consoleVMT || !gh->font) return; @@ -147,11 +150,17 @@ void gwinPutChar(GHandle gh, char c) { } void gwinPutString(GHandle gh, const char *str) { + if (!gwinGetVisible(gh)) + return; + while(*str) gwinPutChar(gh, *str++); } void gwinPutCharArray(GHandle gh, const char *str, size_t n) { + if (!gwinGetVisible(gh)) + return; + while(n--) gwinPutChar(gh, *str++); } @@ -211,6 +220,9 @@ void gwinPrintf(GHandle gh, const char *fmt, ...) { char tmpbuf[MAX_FILLER + 1]; #endif + if (!gwinGetVisible(gh)) + return; + if (gh->vmt != &consoleVMT || !gh->font) return; |