From 4b565208f7f71746db57cc9cefce41c647e069d8 Mon Sep 17 00:00:00 2001 From: Marcus Huderle Date: Mon, 17 Oct 2022 19:37:26 -0500 Subject: [PATCH] Fix one-frame EventFrame jank --- src/mainwindow.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index 1a79e0a0..dc48dcc3 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -2088,11 +2088,14 @@ void MainWindow::updateSelectedObjects() { for (QFrame *frame : frames) { layout->addWidget(frame); + } + layout->addStretch(1); + // Show the frames after the vertical spacer is added to avoid visual jank + // where the frame would stretch to the bottom of the layout. + for (QFrame *frame : frames) { frame->show(); } - layout->addStretch(1); - ui->label_NoEvents->hide(); ui->tabWidget_EventType->show(); }