diff options
author | inmarket <andrewh@inmarket.com.au> | 2013-06-24 22:58:37 +1000 |
---|---|---|
committer | inmarket <andrewh@inmarket.com.au> | 2013-06-24 22:58:37 +1000 |
commit | 8ed9e763c0f97f2946990a911bb940f8c80ff761 (patch) | |
tree | 5f6c19677a530ddfada345242bce1190e3797dfa /src/gwin/console.c | |
parent | c8300fe9c2c7facff1ad32978a5d961690473de4 (diff) | |
download | uGFX-8ed9e763c0f97f2946990a911bb940f8c80ff761.tar.gz uGFX-8ed9e763c0f97f2946990a911bb940f8c80ff761.tar.bz2 uGFX-8ed9e763c0f97f2946990a911bb940f8c80ff761.zip |
GWIN reduce Initialisation parameters and fix visibility issues
Diffstat (limited to 'src/gwin/console.c')
-rw-r--r-- | src/gwin/console.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/gwin/console.c b/src/gwin/console.c index 38e2ea8b..39e534b4 100644 --- a/src/gwin/console.c +++ b/src/gwin/console.c @@ -60,19 +60,21 @@ static void AfterClear(GWindowObject *gh) { static const gwinVMT consoleVMT = { "Console", // The classname + sizeof(GConsoleObject), // The object size 0, // The destroy routine 0, // The redraw routine AfterClear, // The after-clear routine }; -GHandle gwinCreateConsole(GConsoleObject *gc, coord_t x, coord_t y, coord_t width, coord_t height) { - if (!(gc = (GConsoleObject *)_gwindowCreate((GWindowObject *)gc, x, y, width, height, sizeof(GConsoleObject), &consoleVMT, GWIN_FLG_VISIBLE))) +GHandle gwinCreateConsole(GConsoleObject *gc, GWindowInit *pInit) { + if (!(gc = (GConsoleObject *)_gwindowCreate(&gc->g, pInit, &consoleVMT, 0))) return 0; #if GFX_USE_OS_CHIBIOS && GWIN_CONSOLE_USE_BASESTREAM gc->stream.vmt = &GWindowConsoleVMT; #endif gc->cx = 0; gc->cy = 0; + gwinSetVisible((GHandle)gc, pInit->show); return (GHandle)gc; } |