Hallo, i found a solution: no idea if it's stylish
to call hide() and show() for currentWidget!!
void MyClass::MyFunction(void)
{
m_pTabWidget->currentWidget()->hide();
m_pHLayout
= SmartPointer<QHBoxLayout>
(new QHBoxLayout());
// ................. the same code as before .............................
m_pTabWidget->currentWidget()->setLayout(m_pHLayout); //HERE - I expect that the resize event for both m_pWidget1 and pWidget2 is called.....
m_pTabWidget->currentWidget()->show(); // ...in fact it's called HERE !!!!!!!!
}
void MyClass::MyFunction(void)
{
m_pTabWidget->currentWidget()->hide();
m_pHLayout = SmartPointer<QHBoxLayout>(new QHBoxLayout());
// ................. the same code as before .............................
m_pTabWidget->currentWidget()->setLayout(m_pHLayout); //HERE - I expect that the resize event for both m_pWidget1 and pWidget2 is called.....
m_pTabWidget->currentWidget()->show(); // ...in fact it's called HERE !!!!!!!!
}
To copy to clipboard, switch view to plain text mode
Bookmarks