2021-01-13 10:41 AM
I'm wondering if there is a way to force TouchGFX to draw an entire screen again. My project uses a DSI display with internal GRAM. To save power, I turn off the display when possible and turn it on only when needed. This of course erases the GRAM so when the display turns on again it is just blank.
I've tried adding a function to ModelListener and implementing it in a presenter that calls view.draw(). Unfortunately, this doesn't appear to redraw anything. Also, it isn't ideal as I'd have to implement that function for every presenter in my project.
I'm hoping there's a simple way to instruct TouchGFX to simply redraw the most recent screen.
2021-01-13 11:01 AM
One simple way is after wakeup set visible black box over all screen invalidate it and then set invisible and invalidate... Maybe exist better choice.
2021-01-13 11:43 AM
I've found that if I call view.getRootContainer().invalidate() in my presenters then I'm able to get the screen to redraw.
It would still be nice not to have to implement this for each presenter so I'm open to ideas for that as it seems like there should be a simpler way to implement this.
2021-01-13 12:00 PM
yes when you use DSI video mode and full framebuffer
i use this in model then maybe you can rewrite for root invalidate
static_cast<FrontendApplication*>(Application::getInstance())->handleKeyEvent(84);