fixes for usb-support
This commit is contained in:
@@ -1,22 +1,20 @@
|
||||
#include "mainwindow.h"
|
||||
#include "database.h"
|
||||
#include "hardwaresetup.h"
|
||||
#include "training.h"
|
||||
#include "ui_mainwindow.h"
|
||||
#include "unistd.h"
|
||||
#include "windowrace.h"
|
||||
#include "windowrennliste2.h"
|
||||
#include "windowssettings.h"
|
||||
#include <QObject>
|
||||
#include <QShortcut>
|
||||
#include "windowssettings.h"
|
||||
#include <iostream>
|
||||
#include "hardwaresetup.h"
|
||||
#include "windowrace.h"
|
||||
#include "database.h"
|
||||
#include <vector>
|
||||
#include "windowrennliste2.h"
|
||||
#include "training.h"
|
||||
#include "unistd.h"
|
||||
using std::vector;
|
||||
|
||||
MainWindow::MainWindow(QWidget *parent) :
|
||||
QMainWindow(parent),
|
||||
ui(new Ui::MainWindow)
|
||||
{
|
||||
MainWindow::MainWindow(QWidget * parent)
|
||||
: QMainWindow(parent), ui(new Ui::MainWindow) {
|
||||
ui->setupUi(this);
|
||||
this->interfaceTraining = NULL;
|
||||
|
||||
@@ -24,50 +22,48 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||
this->interfaceSettings = NULL;
|
||||
this->interfaceRennliste = NULL;
|
||||
|
||||
//test = new HardwareSetup;
|
||||
// test = new HardwareSetup;
|
||||
|
||||
//this->test->start();
|
||||
QObject::connect(ui->pushButton, SIGNAL(clicked()), this, SLOT(NewWindowSettings()));
|
||||
// this->test->start();
|
||||
QObject::connect(ui->pushButton, SIGNAL(clicked()), this,
|
||||
SLOT(NewWindowSettings()));
|
||||
|
||||
QObject::connect(ui->pBRennen, SIGNAL(clicked()), this, SLOT(WindowRennen()));
|
||||
QObject::connect(this->ui->pBTraining, SIGNAL(clicked()), this, SLOT(WindowTraining()));
|
||||
|
||||
QShortcut *startTraining = new QShortcut(QKeySequence("Ctrl+t"), this);
|
||||
QShortcut *startRennen = new QShortcut(QKeySequence("Ctrl+r"), this);
|
||||
|
||||
QObject::connect(startTraining, SIGNAL(activated()), this, SLOT(WindowTraining()));
|
||||
QObject::connect(startRennen, SIGNAL(activated()), this, SLOT(WindowRennen()));
|
||||
QObject::connect(ui->pBRennen, SIGNAL(clicked()), this,
|
||||
SLOT(WindowRennen()));
|
||||
QObject::connect(this->ui->pBTraining, SIGNAL(clicked()), this,
|
||||
SLOT(WindowTraining()));
|
||||
|
||||
QShortcut * startTraining = new QShortcut(QKeySequence("Ctrl+t"), this);
|
||||
QShortcut * startRennen = new QShortcut(QKeySequence("Ctrl+r"), this);
|
||||
|
||||
QObject::connect(startTraining, SIGNAL(activated()), this,
|
||||
SLOT(WindowTraining()));
|
||||
QObject::connect(startRennen, SIGNAL(activated()), this,
|
||||
SLOT(WindowRennen()));
|
||||
|
||||
this->db = new DataBase;
|
||||
|
||||
vector< vector <QString> > daten = db->getData("select * from Fahrer", 2);
|
||||
|
||||
|
||||
vector<vector<QString>> daten = db->getData("select * from Fahrer", 2);
|
||||
}
|
||||
void MainWindow::closeEvent(QCloseEvent *event){
|
||||
|
||||
void MainWindow::closeEvent(QCloseEvent * event) {
|
||||
}
|
||||
|
||||
MainWindow::~MainWindow()
|
||||
{
|
||||
MainWindow::~MainWindow() {
|
||||
delete this->db;
|
||||
delete ui;
|
||||
|
||||
}
|
||||
|
||||
void MainWindow::WindowTraining(){
|
||||
void MainWindow::WindowTraining() {
|
||||
this->interfaceTraining = new Training(this, this->db);
|
||||
this->interfaceTraining->show();
|
||||
}
|
||||
|
||||
void MainWindow::NewWindowSettings(){
|
||||
void MainWindow::NewWindowSettings() {
|
||||
this->interfaceSettings = new WindowsSettings(this->db, this);
|
||||
this->interfaceSettings->show();
|
||||
}
|
||||
|
||||
void MainWindow::WindowRennen(){
|
||||
void MainWindow::WindowRennen() {
|
||||
this->interfaceRace = new WindowRace(this->db, this);
|
||||
this->interfaceRace->show();
|
||||
this->interfaceRennliste = new WindowRennliste(this->db, this);
|
||||
|
||||
Reference in New Issue
Block a user