diff options
Diffstat (limited to 'demos/modules/gwin/textedit')
-rw-r--r-- | demos/modules/gwin/textedit/gfxconf.h | 3 | ||||
-rw-r--r-- | demos/modules/gwin/textedit/main.c | 14 |
2 files changed, 17 insertions, 0 deletions
diff --git a/demos/modules/gwin/textedit/gfxconf.h b/demos/modules/gwin/textedit/gfxconf.h index 3c5d7b96..4faaae82 100644 --- a/demos/modules/gwin/textedit/gfxconf.h +++ b/demos/modules/gwin/textedit/gfxconf.h @@ -63,7 +63,10 @@ /* Features for the GINPUT subsystem. */ #define GINPUT_NEED_MOUSE TRUE + +/* One or both of these */ #define GINPUT_NEED_KEYBOARD TRUE +#define GWIN_NEED_KEYBOARD TRUE /* Features for the GQUEUE subsystem. */ #define GFX_USE_GQUEUE TRUE diff --git a/demos/modules/gwin/textedit/main.c b/demos/modules/gwin/textedit/main.c index ed52ccb2..4072f983 100644 --- a/demos/modules/gwin/textedit/main.c +++ b/demos/modules/gwin/textedit/main.c @@ -34,6 +34,9 @@ static GHandle ghTextedit1; static GHandle ghTextedit2; static GHandle ghTextedit3; static GListener gl; +#if GWIN_NEED_KEYBOARD + static GHandle ghKeyboard; +#endif static void guiCreate(void) { @@ -80,6 +83,17 @@ static void guiCreate(void) wi.text = "the different widgets"; ghTextedit3 = gwinTexteditCreate(0, &wi, 100); //gwinTexteditSetBorder(ghTextedit3, TRUE); + + // Virtual keyboard +#if GWIN_NEED_KEYBOARD + wi.g.show = TRUE; + wi.g.x = 0; + wi.g.y = gdispGetHeight()*3/4; + wi.g.width = gdispGetWidth(); + wi.g.height = gdispGetHeight()/4; + ghKeyboard = gwinKeyboardCreate(0, &wi); +#endif + } int main(void) { |