Correct way to reload View?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2021-02-11 1:16 AM
I need to reload view completely after major external changes. I don't want to reset each state manually.
What is the correct way to do this? Is this the only way?
void MyView::reloadView()
{
application().gotoMyScreenNoTransition();
}
This works fine, but requires custom handles for each view.
Solved! Go to Solution.
- Labels:
-
TouchGFX
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2021-02-22 12:23 AM
Hello Tuoman,
As Romain said, transitioning to the same screen is a good and easy way to reset the states of a screen. Right now, we don't have other specific way to perform this.
When your question is answered, please close this topic by choosing Select as Best.
/Alexandre
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2021-02-11 2:02 AM
Hi,
​
I would do it the same way as well but there might be a better way :grinning_face_with_sweat:. What kind of "major external changes" are you doing ? It seems interesting.
/Romain
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2021-02-11 6:51 AM
Ok. This works, unless ST wants to add "reload" function to TouchGFX views.
>What kind of "major external changes" are you doing ? It seems interesting.
This device loads&displays data from external devices. When these devices are plugged in/out, I want to reset the view and all its contents&states, instead of manually resetting everything.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2021-02-22 12:23 AM
Hello Tuoman,
As Romain said, transitioning to the same screen is a good and easy way to reset the states of a screen. Right now, we don't have other specific way to perform this.
When your question is answered, please close this topic by choosing Select as Best.
/Alexandre
