I have a class declared using this form
MainWindow(QWidget *parent) :
QMainWindow(parent),
ui(new Ui::MainWindow)
{
...
}
I want to refactor it with this form looking like this :
class MainWindow : QMainWindow, ui
{
MainWindow(QWidget *parent)
{
...
}
}
But I removed the parameters that were in the first form. What do this parameters mean ?
How to keep them in the second form ? Please explain me the first syntax (or point to tutorial). I don't understand inheritance with parameters.
EDIT:
I understand the problem now, the class was initialised in a separate .h file which I did not saw at first look. I thought : after the method definition was inheritance operator, whereas it is member initialization operator.