diff options
| author | Léo Lam <leo@innovatetechnologi.es> | 2018-03-07 17:31:04 +0100 |
|---|---|---|
| committer | Léo Lam <leo@innovatetechnologi.es> | 2018-03-07 17:40:22 +0100 |
| commit | 3af09da0f330893db02f04a566302ac44125f3aa (patch) | |
| tree | e2b1f7bb9cd7566fd27e142987eae92385b3f22c /Source/Core | |
| parent | a436c6182b98d4e244ae1e2f7998edcfc8f9e13c (diff) | |
UI: Show title ID in info panel
Add a way to easily get the title ID of a game. For Wii titles, it's
sometimes more useful to know than the game ID.
Diffstat (limited to 'Source/Core')
| -rw-r--r-- | Source/Core/DolphinQt2/Config/InfoWidget.cpp | 5 | ||||
| -rw-r--r-- | Source/Core/DolphinWX/ISOProperties/InfoPanel.cpp | 5 |
2 files changed, 9 insertions, 1 deletions
diff --git a/Source/Core/DolphinQt2/Config/InfoWidget.cpp b/Source/Core/DolphinQt2/Config/InfoWidget.cpp index c71648805e..bbf8aa4867 100644 --- a/Source/Core/DolphinQt2/Config/InfoWidget.cpp +++ b/Source/Core/DolphinQt2/Config/InfoWidget.cpp @@ -32,7 +32,10 @@ QGroupBox* InfoWidget::CreateISODetails() QLineEdit* file_path = CreateValueDisplay(m_game.GetFilePath()); QLineEdit* internal_name = CreateValueDisplay(m_game.GetInternalName()); - QLineEdit* game_id = CreateValueDisplay(m_game.GetGameID()); + QString game_id_string = m_game.GetGameID(); + if (const u64 title_id = m_game.GetTitleID()) + game_id_string += QStringLiteral(" (%1)").arg(title_id, 16, 16, QLatin1Char('0')); + QLineEdit* game_id = CreateValueDisplay(game_id_string); QLineEdit* country = CreateValueDisplay(m_game.GetCountry()); QLineEdit* maker = CreateValueDisplay(m_game.GetMaker()); QLineEdit* maker_id = CreateValueDisplay(QStringLiteral("0x") + m_game.GetMakerID()); diff --git a/Source/Core/DolphinWX/ISOProperties/InfoPanel.cpp b/Source/Core/DolphinWX/ISOProperties/InfoPanel.cpp index 36fba6c543..45a6121813 100644 --- a/Source/Core/DolphinWX/ISOProperties/InfoPanel.cpp +++ b/Source/Core/DolphinWX/ISOProperties/InfoPanel.cpp @@ -5,6 +5,7 @@ #include "DolphinWX/ISOProperties/InfoPanel.h" #include <algorithm> +#include <cinttypes> #include <iterator> #include <optional> #include <string> @@ -190,7 +191,11 @@ void InfoPanel::LoadISODetails() { const IOS::ES::TMDReader tmd = m_opened_iso->GetTMD(m_opened_iso->GetGamePartition()); if (tmd.IsValid()) + { m_ios_version->SetValue(StringFromFormat("IOS%u", static_cast<u32>(tmd.GetIOSId()))); + m_game_id->SetValue(StrToWxStr(StringFromFormat( + "%s (%016" PRIx64 ")", m_opened_iso->GetGameID().c_str(), tmd.GetTitleId()))); + } } } |
