summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJames Rowe <jroweboy@gmail.com>2019-01-20 23:09:14 +0100
committerJames Rowe <jroweboy@gmail.com>2019-01-20 23:09:14 +0100
commit63783db1b3ad50b8b7d4448ebb3195db7706742c (patch)
tree6d93eeb0315eb1c7737c48fd0b9e90ee9c9c3364 /src
parentQT: Upgrade the Loading Bar to look much better (diff)
downloadyuzu-63783db1b3ad50b8b7d4448ebb3195db7706742c.tar
yuzu-63783db1b3ad50b8b7d4448ebb3195db7706742c.tar.gz
yuzu-63783db1b3ad50b8b7d4448ebb3195db7706742c.tar.bz2
yuzu-63783db1b3ad50b8b7d4448ebb3195db7706742c.tar.lz
yuzu-63783db1b3ad50b8b7d4448ebb3195db7706742c.tar.xz
yuzu-63783db1b3ad50b8b7d4448ebb3195db7706742c.tar.zst
yuzu-63783db1b3ad50b8b7d4448ebb3195db7706742c.zip
Diffstat (limited to 'src')
-rw-r--r--src/yuzu/loading_screen.cpp15
1 files changed, 8 insertions, 7 deletions
diff --git a/src/yuzu/loading_screen.cpp b/src/yuzu/loading_screen.cpp
index 617b8c858..530f5173c 100644
--- a/src/yuzu/loading_screen.cpp
+++ b/src/yuzu/loading_screen.cpp
@@ -46,12 +46,8 @@ LoadingScreen::LoadingScreen(QWidget* parent)
progressbar_style = {
{VideoCore::LoadCallbackStage::Prepare,
R"(
-QProgressBar {
- background-color: black;
-}
-QProgressBar::chunk {
- background-color: white;
-})"},
+QProgressBar {}
+QProgressBar::chunk {})"},
{VideoCore::LoadCallbackStage::Raw,
R"(
QProgressBar {
@@ -114,7 +110,7 @@ void LoadingScreen::Prepare(Loader::AppLoader& loader) {
ui->logo->setPixmap(map);
}
- OnLoadProgress(VideoCore::LoadCallbackStage::Prepare, 0, 100);
+ OnLoadProgress(VideoCore::LoadCallbackStage::Prepare, 0, 0);
}
void LoadingScreen::OnLoadProgress(VideoCore::LoadCallbackStage stage, std::size_t value,
@@ -124,6 +120,11 @@ void LoadingScreen::OnLoadProgress(VideoCore::LoadCallbackStage stage, std::size
// reset the timer if the stage changes
if (stage != previous_stage) {
ui->progress_bar->setStyleSheet(progressbar_style[stage]);
+ if (stage == VideoCore::LoadCallbackStage::Prepare) {
+ ui->progress_bar->hide();
+ } else {
+ ui->progress_bar->show();
+ }
previous_stage = stage;
// reset back to fast shader compiling since the stage changed
slow_shader_compile_start = false;