mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-25 07:09:48 -06:00
DolphinQt: Only show raw memory card path if it's not the default.
This commit is contained in:
@ -644,4 +644,9 @@ std::string GetMemcardPath(std::string configured_filename, ExpansionInterface::
|
|||||||
Config::GetDirectoryForRegion(Config::ToGameCubeRegion(used_region)),
|
Config::GetDirectoryForRegion(Config::ToGameCubeRegion(used_region)),
|
||||||
blocks_string, ext);
|
blocks_string, ext);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool IsDefaultMemcardPathConfigured(ExpansionInterface::Slot slot)
|
||||||
|
{
|
||||||
|
return Config::Get(GetInfoForMemcardPath(slot)).empty();
|
||||||
|
}
|
||||||
} // namespace Config
|
} // namespace Config
|
||||||
|
@ -350,4 +350,5 @@ std::string GetMemcardPath(ExpansionInterface::Slot slot, std::optional<DiscIO::
|
|||||||
u16 size_mb = 0x80);
|
u16 size_mb = 0x80);
|
||||||
std::string GetMemcardPath(std::string configured_filename, ExpansionInterface::Slot slot,
|
std::string GetMemcardPath(std::string configured_filename, ExpansionInterface::Slot slot,
|
||||||
std::optional<DiscIO::Region> region, u16 size_mb = 0x80);
|
std::optional<DiscIO::Region> region, u16 size_mb = 0x80);
|
||||||
|
bool IsDefaultMemcardPathConfigured(ExpansionInterface::Slot slot);
|
||||||
} // namespace Config
|
} // namespace Config
|
||||||
|
@ -300,14 +300,18 @@ void GameCubePane::UpdateButton(ExpansionInterface::Slot slot)
|
|||||||
{
|
{
|
||||||
case ExpansionInterface::Slot::A:
|
case ExpansionInterface::Slot::A:
|
||||||
case ExpansionInterface::Slot::B:
|
case ExpansionInterface::Slot::B:
|
||||||
|
{
|
||||||
has_config = (device == ExpansionInterface::EXIDeviceType::MemoryCard ||
|
has_config = (device == ExpansionInterface::EXIDeviceType::MemoryCard ||
|
||||||
device == ExpansionInterface::EXIDeviceType::AGP ||
|
device == ExpansionInterface::EXIDeviceType::AGP ||
|
||||||
device == ExpansionInterface::EXIDeviceType::Microphone);
|
device == ExpansionInterface::EXIDeviceType::Microphone);
|
||||||
m_memcard_path_labels[slot]->setHidden(device != ExpansionInterface::EXIDeviceType::MemoryCard);
|
const bool hide_memory_card = device != ExpansionInterface::EXIDeviceType::MemoryCard ||
|
||||||
m_memcard_paths[slot]->setHidden(device != ExpansionInterface::EXIDeviceType::MemoryCard);
|
Config::IsDefaultMemcardPathConfigured(slot);
|
||||||
|
m_memcard_path_labels[slot]->setHidden(hide_memory_card);
|
||||||
|
m_memcard_paths[slot]->setHidden(hide_memory_card);
|
||||||
m_agp_path_labels[slot]->setHidden(device != ExpansionInterface::EXIDeviceType::AGP);
|
m_agp_path_labels[slot]->setHidden(device != ExpansionInterface::EXIDeviceType::AGP);
|
||||||
m_agp_paths[slot]->setHidden(device != ExpansionInterface::EXIDeviceType::AGP);
|
m_agp_paths[slot]->setHidden(device != ExpansionInterface::EXIDeviceType::AGP);
|
||||||
break;
|
break;
|
||||||
|
}
|
||||||
case ExpansionInterface::Slot::SP1:
|
case ExpansionInterface::Slot::SP1:
|
||||||
has_config = (device == ExpansionInterface::EXIDeviceType::Ethernet ||
|
has_config = (device == ExpansionInterface::EXIDeviceType::Ethernet ||
|
||||||
device == ExpansionInterface::EXIDeviceType::EthernetXLink ||
|
device == ExpansionInterface::EXIDeviceType::EthernetXLink ||
|
||||||
|
Reference in New Issue
Block a user