qfedu-qt-level/homework-day1/main.cpp

38 lines
907 B
C++
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#include "widget.h"
#include "widget1.h" // 题目1
#include "widget2.h" // 题目2
#include "widget3.h" // 题目3
#include "widget4.h" // 题目4
#include "widget5.h" // 题目5
#include "widget7.h" // 题目6题目7
#include "widget8.h" // 题目7
#include <QApplication>
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
// Widget7 w;
// w.show();
Widget7 judge1;
Widget7 judge2;
Widget7 judge3;
Widget8 w8;
judge1.show();
judge2.show();
judge3.show();
// 建立信号槽连接
w8.connect(&judge1,&Widget7::studentSelected,&w8,&Widget8::receviceStudentSelection);
w8.connect(&judge2,&Widget7::studentSelected,&w8,&Widget8::receviceStudentSelection);
w8.connect(&judge2,&Widget7::studentSelected,&w8,&Widget8::receviceStudentSelection);
// w8.show();
return a.exec();
}