HomeWindow: fix background white flash while switching to onroad (#21695)

pull/21668/head^2
Dean Lee 4 years ago committed by GitHub
parent 116bb0b524
commit f67467f321
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 3
      selfdrive/ui/qt/home.cc
  2. 1
      selfdrive/ui/qt/window.cc

@ -39,6 +39,7 @@ HomeWindow::HomeWindow(QWidget* parent) : QWidget(parent) {
showDriverView(false);
});
slayout->addWidget(driver_view);
setAttribute(Qt::WA_NoSystemBackground);
}
void HomeWindow::showSidebar(bool show) {
@ -46,12 +47,12 @@ void HomeWindow::showSidebar(bool show) {
}
void HomeWindow::offroadTransition(bool offroad) {
sidebar->setVisible(offroad);
if (offroad) {
slayout->setCurrentWidget(home);
} else {
slayout->setCurrentWidget(onroad);
}
sidebar->setVisible(offroad);
emit offroadTransitionSignal(offroad);
}

@ -59,6 +59,7 @@ MainWindow::MainWindow(QWidget *parent) : QWidget(parent) {
outline: none;
}
)");
setAttribute(Qt::WA_NoSystemBackground);
}
void MainWindow::openSettings() {

Loading…
Cancel
Save