#include "widget.h"
#include "ui_widget.h"
#include "mypushbutton.h"
Widget::Widget(QWidget *parent)
: QWidget(parent)
, ui(new Ui::Widget)
{
ui->setupUi(this);
MyPushButton *pushButton = new MyPushButton(this);
}
#include "mypushbutton.h"
#include "ui_mypushbutton.h"
#include <QDebug>
MyPushButton::MyPushButton(QWidget *parent) :
QWidget(parent),
ui(new Ui::MyPushButton)
{
qDebug() << "MyPushButton";
ui->setupUi(this);
}
MyPushButton::~MyPushButton()
{
qDebug() << "~MyPushButton";
delete ui;
}
18:45:35: Starting ...
MyPushButton
~MyPushButton