Skip to content

Commit

Permalink
Fix calculating width of _videoWidget by its wrong initial height of 0
Browse files Browse the repository at this point in the history
  • Loading branch information
SpriteOvO committed Jul 27, 2023
1 parent 2ba3e8f commit 430819a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Source/Gui/MainWindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -231,14 +231,17 @@ MainWindow::MainWindow(QWidget *parent) : QDialog{parent}
_autoHideTimer->callOnTimeout([this] { DoHide(); });
_mediaPlayer->setMuted(true);
_mediaPlayer->setVideoOutput(_videoWidget);
_videoWidget->show();

_ui.layoutAnimation->addWidget(_videoWidget);
_ui.layoutPods->addWidget(_leftBattery);
_ui.layoutPods->addWidget(_rightBattery);
_ui.layoutCase->addWidget(_caseBattery);
_ui.layoutClose->addWidget(_closeButton);

// For getting the correct initial height of `_videoWidget` later
_ui.layoutAnimation->activate();
_videoWidget->show();

Unavailable();
_updateChecker.Start();
}
Expand Down

0 comments on commit 430819a

Please sign in to comment.