2021-07-16 17:30:00 -07:00
|
|
|
#include <sys/resource.h>
|
|
|
|
|
|
2020-08-20 17:16:44 +02:00
|
|
|
#include <QApplication>
|
2021-05-02 16:28:36 -07:00
|
|
|
#include <QSslConfiguration>
|
2020-08-20 17:16:44 +02:00
|
|
|
|
2021-05-06 14:39:05 +02:00
|
|
|
#include "selfdrive/hardware/hw.h"
|
2021-05-09 13:15:17 +08:00
|
|
|
#include "selfdrive/ui/qt/qt_window.h"
|
2021-06-09 20:09:49 +08:00
|
|
|
#include "selfdrive/ui/qt/util.h"
|
2021-05-09 13:15:17 +08:00
|
|
|
#include "selfdrive/ui/qt/window.h"
|
2020-08-20 17:16:44 +02:00
|
|
|
|
2020-08-27 11:57:31 -07:00
|
|
|
int main(int argc, char *argv[]) {
|
2021-07-16 17:30:00 -07:00
|
|
|
setpriority(PRIO_PROCESS, 0, -20);
|
|
|
|
|
|
2021-07-02 14:01:59 +02:00
|
|
|
qInstallMessageHandler(swagLogMessageHandler);
|
2021-07-08 12:19:56 +08:00
|
|
|
initApp();
|
2020-08-20 21:33:32 +02:00
|
|
|
|
2021-05-06 14:39:05 +02:00
|
|
|
if (Hardware::EON()) {
|
|
|
|
|
QSslConfiguration ssl = QSslConfiguration::defaultConfiguration();
|
|
|
|
|
ssl.setCaCertificates(QSslCertificate::fromPath("/usr/etc/tls/cert.pem"));
|
|
|
|
|
QSslConfiguration::setDefaultConfiguration(ssl);
|
|
|
|
|
}
|
2021-05-02 16:28:36 -07:00
|
|
|
|
2020-08-20 17:16:44 +02:00
|
|
|
QApplication a(argc, argv);
|
|
|
|
|
MainWindow w;
|
2020-11-24 22:07:03 -08:00
|
|
|
setMainWindow(&w);
|
2020-11-20 13:21:18 +01:00
|
|
|
a.installEventFilter(&w);
|
2020-08-20 17:16:44 +02:00
|
|
|
return a.exec();
|
|
|
|
|
}
|