GWIN Console Clear Fix

When a GWIN Console is cleared, set the cursor back to the top left
corner.
ugfx_release_2.6
Andrew Hannam 2012-11-30 00:41:43 +10:00
parent bc0ce07298
commit e741d6045b
1 changed files with 7 additions and 0 deletions

View File

@ -152,6 +152,13 @@ void gwinClear(GHandle gh) {
gdispSetClip(gh->x, gh->y, gh->width, gh->height);
#endif
gdispFillArea(gh->x, gh->y, gh->width, gh->height, gh->bgcolor);
#if GWIN_NEED_CONSOLE
if (gh->type == GW_CONSOLE) {
((GConsoleObject *)gh)->cx = 0;
((GConsoleObject *)gh)->cy = 0;
}
#endif
}
/**