信号连接信号
#include "widget.h"
#include "ui_widget.h"
#include <QDebug>
Widget::Widget(QWidget *parent)
: QWidget(parent)
, ui(new Ui::Widget)
{
ui->setupUi(this);
connect(ui->pushButton_src, SIGNAL(clicked()), ui->pushButton_dst, SIGNAL(clicked()));
connect(ui->pushButton_dst, SIGNAL(clicked()), this, SLOT(clickedSlot()));
}
Widget::~Widget()
{
delete ui;
}
void Widget::clickedSlot()
{
qDebug() << "clickedSlot";
}
20:39:10: Starting ...
clickedSlot
clickedSlot