Transition between two QDialogs
I am developping a new application and I would like that it starts with a QDialog saying welcome and letting the user choose between two options by clicking on one of the two buttons representing the two options.
I would like that when the user clicks on one of the two buttons, the application answers with another QDialog.
My question is technical: how is the best way of implement the transition between the two QDialogs?
One solution can be that I create only one QDialog and when a button is clicked, the same QDialog deletes the widget of the welcome QDialog and sets the new widgets.
The other solution could be that when a button is clicked, a new QDialog is created.
Do you have any suggestion? Thanks!
Sounds more like a QWizard use case
Yes I agree with you, but I would like to have a customized page of the wizard where the buttons in the bottom of the page are not there and the buttons that is suppose to go to the next page is positioned elsewhere... in the page... I couldnt do that for this reason I tried with QDialog
QStackedWidget/Layout inside your QDialog ?
You are better to create two different dialogs and based on your first action, show the second one. You can either delete the previous one or keep it based on whether you want to reuse the same dialog.