mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-07-17 23:32:07 +08:00
fba42aab80
* add recent buttons * remove static request * layout * recent doesn't have to be a favorite * work * spacing * spacing * no recents * query next * not null * this needs to live here * less spacing between items old-commit-hash: 9f98a3e44f3b5b70d7e420f9e51f737bb854266d
19 lines
433 B
C++
19 lines
433 B
C++
#include "selfdrive/ui/qt/util.h"
|
|
#include <QStyleOption>
|
|
#include <QDebug>
|
|
|
|
ClickableWidget::ClickableWidget(QWidget *parent) : QWidget(parent) { }
|
|
|
|
void ClickableWidget::mouseReleaseEvent(QMouseEvent *event) {
|
|
emit clicked();
|
|
}
|
|
|
|
|
|
// Fix stylesheets
|
|
void ClickableWidget::paintEvent(QPaintEvent *) {
|
|
QStyleOption opt;
|
|
opt.init(this);
|
|
QPainter p(this);
|
|
style()->drawPrimitive(QStyle::PE_Widget, &opt, &p, this);
|
|
}
|