Skip to content

Commit

Permalink
progress dialog fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Megamouse committed Jun 16, 2023
1 parent 924692b commit d08fea5
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion rpcs3/Emu/Cell/PPUThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1535,7 +1535,7 @@ void ppu_thread::cpu_task()
// Wait until the progress dialog is closed.
// We don't want to open a cell dialog while a native progress dialog is still open.
thread_ctrl::wait_on<atomic_wait::op_ne>(g_progr_ptotal, 0);
g_fxo->get<progress_dialog_server>().show_overlay_message_only = true;
g_fxo->get<progress_dialog_workaround>().show_overlay_message_only = true;

// Sadly we can't postpone initializing guest time because we need to run PPU threads
// (the farther it's postponed, the less accuracy of guest time has been lost)
Expand Down
2 changes: 1 addition & 1 deletion rpcs3/Emu/system_progress.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ void progress_dialog_server::operator()()
renderer->is_initialized.wait(false, atomic_wait_timeout(5 * 1000000000ull));

auto manager = g_fxo->try_get<rsx::overlays::display_manager>();
show_overlay_message = show_overlay_message_only;
show_overlay_message = g_fxo->get<progress_dialog_workaround>().show_overlay_message_only;

if (manager && !show_overlay_message)
{
Expand Down
5 changes: 4 additions & 1 deletion rpcs3/Emu/system_progress.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,10 @@ struct progress_dialog_server
~progress_dialog_server();

static constexpr auto thread_name = "Progress Dialog Server"sv;

};

struct progress_dialog_workaround
{
// We don't want to show the native dialog during gameplay.
atomic_t<bool> show_overlay_message_only = false;
};

0 comments on commit d08fea5

Please sign in to comment.