首先我们都知道QObject的connect函数的作用是用来连接信号和槽的。
我们再来具体看看connect函数:
connect(sender, SIGNAL(signal), receiver, SLOT(slot));
sender和receiver是对象指针,signal和slot是转换信号和槽。
请看下面代码的具体实现:
//datherdialog.h
#ifndef FATHERDIALOG_H#define FATHERDIALOG_H#include <QDialog>namespace Ui