-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathchoose.cpp
28 lines (23 loc) · 855 Bytes
/
choose.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#include "choose.h"
#include <QDebug>
#include "global.h"
Choose::Choose()
{
qDebug()<<"begin!!!!!!";
this->resize(800,800);
this->move(400,50);
computer = new QPushButton(this);
this->setWindowFlags(Qt::CustomizeWindowHint | Qt::WindowCloseButtonHint);
QPalette palette;
palette.setBrush(QPalette::Background, QBrush(QPixmap(":/pic/bg.jpg").scaled(this->size(),Qt::IgnoreAspectRatio,Qt::SmoothTransformation)));
this->setPalette(palette);
computer->setStyleSheet("QPushButton{border-image:url(:/pic/pc.PNG);background-position: center;}");
computer->setGeometry(250,350,300,60);
connect(computer,SIGNAL(clicked()),this,SLOT(accept()));
connect(computer,SIGNAL(clicked()),this,SLOT(selectcomputer()));
qDebug()<<"end!";
}
void Choose::selectcomputer()
{
mode = 0;
}