Files
clearpilot/selfdrive/ui/qt/ready.h
Brian Hanson 55f73fd421
Some checks failed
prebuilt / build prebuilt (push) Has been cancelled
badges / create badges (push) Has been cancelled
ready screen: hide READY! text after first drive, reset on ignition cycle
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-14 02:51:13 -05:00

36 lines
888 B
C++
Executable File

#pragma once
#include <QMovie>
#include <QLabel>
#include <QPushButton>
#include <QPixmap>
#include <QProgressBar>
#include <QSocketNotifier>
#include <QVariantAnimation>
#include <QWidget>
#include <QElapsedTimer>
#include <QTimer>
#include "common/util.h"
#include "selfdrive/ui/ui.h"
class ReadyWindow : public QWidget {
Q_OBJECT
public:
ReadyWindow(QWidget* parent = nullptr);
bool has_driven = false;
private:
void showEvent(QShowEvent *event) override;
void hideEvent(QHideEvent *event) override;
void refresh();
void paintEvent(QPaintEvent *event) override;
Params params;
QTimer* timer;
bool is_hot = false;
QString cur_temp;
QString error_msg; // non-empty = show red error instead of READY!
QElapsedTimer uptime;
bool last_started = false;
QPixmap img_bg;
QPixmap img_hot;
};