Merge remote-tracking branch 'origin/main'

This commit is contained in:
ackimixs
2024-05-10 10:34:36 +02:00
7 changed files with 27 additions and 0 deletions

View File

@@ -3,6 +3,11 @@
InGame::InGame(QWidget *parent) : QWidget(parent) {
this->mainLayout = new QVBoxLayout(this);
this->mainLayout->setAlignment(Qt::AlignCenter);
QPixmap bgPixmap(":/img/ISEN-Nantes.png");
bgPixmap = bgPixmap.scaled(this->size(), Qt::KeepAspectRatioByExpanding);
QPalette palette;
palette.setBrush(QPalette::Window, QBrush(bgPixmap));
this->setPalette(palette);
this->pts = new QLabel("Points : 0", this);
this->pts->setStyleSheet("font-size: 96px; color: black;");
this->x = new QLabel("X : 0", this);

View File

@@ -3,6 +3,9 @@
#include <QVBoxLayout>
#include <QWidget>
#include <QTimer>
#include <QPixmap>
#include <QPalette>
#include <QBrush>
class InGame : public QWidget {
Q_OBJECT

View File

@@ -5,6 +5,7 @@
#include <QStackedWidget>
#include <QPixmap>
#include <QSettings>
#include <atomic>
#include "HomePage.h"
#include "Homologation.h"

View File

@@ -39,26 +39,32 @@ TeamChooser::TeamChooser(QWidget* parent) : QWidget(parent)
this->bottomLayout->addWidget(spawnPoint6, 0, Qt::AlignBottom | Qt::AlignRight);
connect(this->spawnPoint1, &QPushButton::pressed, this, [=]() {
qDebug() << "Spawn point 1 clicked";
spawnPointClicked(1);
});
connect(this->spawnPoint2, &QPushButton::pressed, this, [=]() {
qDebug() << "Spawn point 2 clicked";
spawnPointClicked(2);
});
connect(this->spawnPoint3, &QPushButton::pressed, this, [=]() {
qDebug() << "Spawn point 3 clicked";
spawnPointClicked(3);
});
connect(this->spawnPoint4, &QPushButton::pressed, this, [=]() {
qDebug() << "Spawn point 4 clicked";
spawnPointClicked(4);
});
connect(this->spawnPoint5, &QPushButton::pressed, this, [=]() {
qDebug() << "Spawn point 5 clicked";
spawnPointClicked(5);
});
connect(this->spawnPoint6, &QPushButton::pressed, this, [=]() {
qDebug() << "Spawn point 6 clicked";
spawnPointClicked(6);
});
}

BIN
img/ISEN-Nantes.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

View File

@@ -2,12 +2,23 @@
#include <QApplication>
#include <QObject>
#include <QThread>
#include <csignal>
#include "MainWindow.h"
void signalHandler(int sigmum) {
std::cout << "Inteerupt signal (" << sigmum << ") received.\n";
QApplication::quit();
}
int main(int argc, char* argv[]) {
QApplication a(argc, argv);
signal(SIGTERM, signalHandler);
signal(SIGINT, signalHandler);
DisplayMode mode;
if (argc >= 2)

View File

@@ -6,5 +6,6 @@
<file>img/table.jpg</file>
<file>img/close.svg</file>
<file>img/close.png</file>
<file>img/ISEN-Nantes.png</file>
</qresource>
</RCC>