openpilot is an open source driver assistance system. openpilot performs the functions of Automated Lane Centering and Adaptive Cruise Control for over 200 supported car makes and models.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

62 lines
1.0 KiB

#pragma once
#include <QLabel>
#include <QStackedLayout>
#include <QWidget>
#include "api.hpp"
class PairingQRWidget : public QWidget {
Q_OBJECT
public:
explicit PairingQRWidget(QWidget* parent = 0);
private:
QLabel* qrCode;
void updateQrCode(QString text);
private slots:
void refresh();
};
class PrimeUserWidget : public QWidget {
Q_OBJECT
public:
explicit PrimeUserWidget(QWidget* parent = 0);
private:
QVBoxLayout* mainLayout;
QLabel* username;
QLabel* points;
CommaApi* api;
private slots:
void replyFinished(QString response);
};
class PrimeAdWidget : public QWidget {
Q_OBJECT
public:
explicit PrimeAdWidget(QWidget* parent = 0);
};
class SetupWidget : public QWidget {
Q_OBJECT
public:
explicit SetupWidget(QWidget* parent = 0);
private:
QStackedLayout* mainLayout;
CommaApi* api;
PrimeAdWidget *primeAd;
PrimeUserWidget *primeUser;
bool showQr = false;
private slots:
void parseError(QString response);
void replyFinished(QString response);
void showQrCode();
};