So this is the situation: I have created my own custom widget, and it uses 2 separate forms, designed in Designer and defined in the private section of the header file. When I switch between the two forms, I have to delete the objects and layout in the other form, otherwise I get a mess.
I use something like myForm.setupUi() and lster myForm2.setupUi(), but doing that causes problems. So I need to somehow delete the objects created by the setupUi() function. I tried qDeleteAll(children()) but that deleted everything in the widget, not just in the UI part, and I don't want that.
Basically I want to undo the operations of setupUi(). Any ideas? Thanks!
Bookmarks