nuliknol
7th February 2015, 22:32
Hi! Simple question here...
Can and object be initialized inside "private:" clause ? Something like this:
class WAction : public QWidget
{
Q_OBJECT
public:
explicit WAction(QWidget *parent = 0);
signals:
public slots:
private:
QPushButton btn_new_action("New Action");
QLabel lbl_description("Action description:");
};
if so, what would be the syntax, because the above code is not valid.
Can and object be initialized inside "private:" clause ? Something like this:
class WAction : public QWidget
{
Q_OBJECT
public:
explicit WAction(QWidget *parent = 0);
signals:
public slots:
private:
QPushButton btn_new_action("New Action");
QLabel lbl_description("Action description:");
};
if so, what would be the syntax, because the above code is not valid.