19 lines
396 B
C++
19 lines
396 B
C++
|
#include "widget6.h"
|
||
|
|
||
|
Widget6::Widget6(QWidget *parent) : QWidget(parent)
|
||
|
{
|
||
|
|
||
|
setWindowTitle("题目5-widget6");
|
||
|
setFixedSize(400,600);
|
||
|
move(900,300);
|
||
|
|
||
|
btn = new QPushButton("隐身按钮",this);
|
||
|
btn->setFixedSize(200,100);
|
||
|
btn->move(10,10);
|
||
|
|
||
|
|
||
|
connect(btn,&QPushButton::clicked,[&]()->void{
|
||
|
emit this->stealth(); // 发送隐身信号
|
||
|
});
|
||
|
}
|