2019-03-28 06:13 AM
Hello all,
I am trying to switch the screen throuch code in touchgfx.
If I use SwitchScreen, how shall I state the argument (screen* newScreen)?
If, for example I want to switch to Screen7.
Shall I call the function with SwitchScreen(scr7)?
where scr7 is declared as follows:
ScreenView7 scr7;
Solved! Go to Solution.
2022-01-21 03:42 AM
Solved. I had to add
#include <gui/common/FrontendHeap.hpp>
in FrontendApplication.c
2024-08-12 08:18 AM
But you would not be able to call
static_cast<FrontendApplication*>(Application::getInstance())->gotoScreen1ScreenNoTransition();
from .c code. How could you circumvent that, could you write a c-calling convention compatible wrapper inside FrontEndApplication.cpp which would call gotoScreen1ScreenNoTransition() directly? Could this be for example done by writing a function outside the class that woudl have access to the instantiated object and place that between extern "c" brackets?
I wish that I could program everyghing in either .cpp or .c, but with FreeRTOS and TouchGFX one has little choice.