Hi
I am using a QTabWidget and have implemented a method which reacts to the "oncloseRequest" signal (clicking on the close icon of a tab):
void generat0rX::sceneTabRemove_slot(int index)
{
sceneTabWidget->currentWidget()->deleteLater();
sceneTabWidget->removeTab(index);
}
void generat0rX::sceneTabRemove_slot(int index)
{
sceneTabWidget->currentWidget()->deleteLater();
sceneTabWidget->removeTab(index);
}
To copy to clipboard, switch view to plain text mode
My problem is that not only the active tab is deleted, but all to the right of it as well (having higher indexes than the currently active one).
Is there a fundamental mistake I am making in the method above?
Thanks & regards,
Michael
Bookmarks