small optimization
And some trace info about tab build time
This commit is contained in:
committed by
Raphael Coeffic
parent
9b1c596783
commit
459ff09e75
@@ -195,6 +195,11 @@ void TabsGroup::setVisibleTab(PageTab* tab)
|
||||
currentTab = tab;
|
||||
if (tab->onSetVisible) tab->onSetVisible();
|
||||
|
||||
#if defined(DEBUG)
|
||||
auto start_ms = RTOS_GET_MS();
|
||||
(void)start_ms;
|
||||
#endif
|
||||
|
||||
auto form = new FormWindow(&body, rect_t{0, 0, body.width(), body.height()},
|
||||
NO_FOCUS | FORM_FORWARD_FOCUS);
|
||||
tab->build(form);
|
||||
@@ -202,6 +207,8 @@ void TabsGroup::setVisibleTab(PageTab* tab)
|
||||
|
||||
header.setTitle(tab->title.c_str());
|
||||
invalidate();
|
||||
|
||||
TRACE("tab time: %d ms", RTOS_GET_MS() - start_ms);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Vendored
+1
-1
Submodule radio/src/thirdparty/libopenui updated: b105e1c21c...bce5887c6b
Reference in New Issue
Block a user