ref: segregate animation screen

This commit is contained in:
semenov
2024-12-28 10:50:26 +03:00
parent 98264fee7a
commit 78e8ecbde6
28 changed files with 1012 additions and 175 deletions

View File

@@ -60,6 +60,8 @@ void MainWindow::createObjects()
commonButtonGroupWidget = new CommonButtonGroupWidget;
entryWidget = new EntryWidget;
versionSelectWidget = new VersionSelectWidget;
waitAnimationWidget = new WaitAnimationWidget;
waitAnimationWidget->setParent(this);
ui->changButtonGroup->addWidget(commonButtonGroupWidget);
ui->interactiveGroup->addWidget(entryWidget);
@@ -95,14 +97,6 @@ void MainWindow::createObjects()
workerThread->start();
workerThread->setPriority(QThread::HighestPriority);
QVBoxLayout *layout = new QVBoxLayout();
layout->setParent(this);
movieLabel = new QLabel("MovieLabel");
layout->addWidget(movieLabel);
setLayout(layout);
movieLabel->setStyleSheet("background-color:rgba(0,0,0,90)");
timer = new QTimer;
}
@@ -532,9 +526,7 @@ void MainWindow::setUpUi()
ui->unsafeChangingButton->setIcon(*resourceManager->getUnsavedIcon());
ui->unsafeChangingButton->setIconSize(cautionIconSize);
movieLabel->setGeometry(367,300,70,70);
movieLabel->setSizePolicy(QSizePolicy::Minimum,QSizePolicy::Minimum);
movieLabel->setMovie(resourceManager->getMovie());
waitAnimationWidget->setMovie(resourceManager->getMovie());
QSize iconSize(30,30);
ui->exitButton->setIcon(*resourceManager->getCloseIcon());
@@ -559,13 +551,11 @@ void MainWindow::activateLoadingAnimation(bool flag)
{
if (flag)
{
movieLabel->show();
resourceManager->startLoadingAnim();
waitAnimationWidget->showWithPlay();
}
else
{
movieLabel->hide();
resourceManager->stopLoadingMovie();
waitAnimationWidget->hideWithStop();
}
}