Re: MainWindow disappearing when loading a QMessageBox
Originally Posted by jacek
Yes, it might be connected to some slot that closes the window.
It is! I was missing a line in the .h file generated via Qt Designer/UIC, which was implementing exactly what you said. I removed that line and now everything works smoothly. and as expected.
Re: MainWindow disappearing when loading a QMessageBox
Originally Posted by fabietto
It is! I was missing a line in the .h file generated via Qt Designer/UIC, which was implementing exactly what you said. I removed that line and now everything works smoothly. and as expected.
Don't remove any lines from autogenerated code or the problem will come back. Better fix the .ui file.
Re: MainWindow disappearing when loading a QMessageBox
Originally Posted by jacek
Don't remove any lines from autogenerated code or the problem will come back. Better fix the .ui file.
Sure, Jacek. I've used the Qt Designer only at the beginning in order to create the skeleton of the main windows. Now I don't generate the .h file automatically, but I simply use a progressively modified version of it.
Bookmarks