Don't do automatic disc switching when running e.g. the Wii Menu
We only want automatic disc switching to happen when the game actually is running, but software like the Wii Menu also uses DVDLowStopMotor.
This commit is contained in:
parent
bd665aad5d
commit
b608e80d8e
|
@ -1039,7 +1039,8 @@ void ExecuteCommand(u32 command_0, u32 command_1, u32 command_2, u32 output_addr
|
|||
INFO_LOG(DVDINTERFACE, "DVDLowStopMotor %s %s", command_1 ? "eject" : "",
|
||||
command_2 ? "kill!" : "");
|
||||
|
||||
bool auto_disc_change = Config::Get(Config::MAIN_AUTO_DISC_CHANGE) && !Movie::IsPlayingInput();
|
||||
bool auto_disc_change = Config::Get(Config::MAIN_AUTO_DISC_CHANGE) &&
|
||||
!Movie::IsPlayingInput() && DVDThread::IsInsertedDiscRunning();
|
||||
if (auto_disc_change)
|
||||
auto_disc_change = AutoChangeDisc();
|
||||
if (auto_disc_change)
|
||||
|
|
|
@ -216,6 +216,16 @@ IOS::ES::TicketReader GetTicket(const DiscIO::Partition& partition)
|
|||
return s_disc->GetTicket(partition);
|
||||
}
|
||||
|
||||
bool IsInsertedDiscRunning()
|
||||
{
|
||||
if (!s_disc)
|
||||
return false;
|
||||
|
||||
WaitUntilIdle();
|
||||
|
||||
return SConfig::GetInstance().GetGameID() == s_disc->GetGameID();
|
||||
}
|
||||
|
||||
bool UpdateRunningGameMetadata(const DiscIO::Partition& partition, std::optional<u64> title_id)
|
||||
{
|
||||
if (!s_disc)
|
||||
|
|
|
@ -47,6 +47,7 @@ DiscIO::Platform GetDiscType();
|
|||
u64 PartitionOffsetToRawOffset(u64 offset, const DiscIO::Partition& partition);
|
||||
IOS::ES::TMDReader GetTMD(const DiscIO::Partition& partition);
|
||||
IOS::ES::TicketReader GetTicket(const DiscIO::Partition& partition);
|
||||
bool IsInsertedDiscRunning();
|
||||
// This function returns true and calls SConfig::SetRunningGameMetadata(Volume&, Partition&)
|
||||
// if both of the following conditions are true:
|
||||
// - A disc is inserted
|
||||
|
|
Loading…
Reference in New Issue