diff --git a/Source/Core/Core/ConfigManager.cpp b/Source/Core/Core/ConfigManager.cpp index ffb309c7f7..bdd18ade0b 100644 --- a/Source/Core/Core/ConfigManager.cpp +++ b/Source/Core/Core/ConfigManager.cpp @@ -216,6 +216,7 @@ void SConfig::SaveGameListSettings(IniFile& ini) gamelist->Set("ColumnPlatform", m_showSystemColumn); gamelist->Set("ColumnBanner", m_showBannerColumn); + gamelist->Set("ColumnTitle", m_showTitleColumn); gamelist->Set("ColumnNotes", m_showMakerColumn); gamelist->Set("ColumnFileName", m_showFileNameColumn); gamelist->Set("ColumnID", m_showIDColumn); @@ -536,6 +537,7 @@ void SConfig::LoadGameListSettings(IniFile& ini) // Gamelist columns toggles gamelist->Get("ColumnPlatform", &m_showSystemColumn, true); gamelist->Get("ColumnBanner", &m_showBannerColumn, true); + gamelist->Get("ColumnTitle", &m_showTitleColumn, true); gamelist->Get("ColumnNotes", &m_showMakerColumn, true); gamelist->Get("ColumnFileName", &m_showFileNameColumn, false); gamelist->Get("ColumnID", &m_showIDColumn, false); diff --git a/Source/Core/Core/ConfigManager.h b/Source/Core/Core/ConfigManager.h index a66fd70e76..510d939172 100644 --- a/Source/Core/Core/ConfigManager.h +++ b/Source/Core/Core/ConfigManager.h @@ -293,6 +293,7 @@ struct SConfig : NonCopyable // Game list column toggles bool m_showSystemColumn; bool m_showBannerColumn; + bool m_showTitleColumn; bool m_showMakerColumn; bool m_showFileNameColumn; bool m_showIDColumn; diff --git a/Source/Core/DolphinWX/FrameTools.cpp b/Source/Core/DolphinWX/FrameTools.cpp index e3f268f426..da0a6c3753 100644 --- a/Source/Core/DolphinWX/FrameTools.cpp +++ b/Source/Core/DolphinWX/FrameTools.cpp @@ -1640,6 +1640,9 @@ void CFrame::OnChangeColumnsVisible(wxCommandEvent& event) case IDM_SHOW_BANNER: SConfig::GetInstance().m_showBannerColumn = !SConfig::GetInstance().m_showBannerColumn; break; + case IDM_SHOW_TITLE: + SConfig::GetInstance().m_showTitleColumn = !SConfig::GetInstance().m_showTitleColumn; + break; case IDM_SHOW_MAKER: SConfig::GetInstance().m_showMakerColumn = !SConfig::GetInstance().m_showMakerColumn; break; diff --git a/Source/Core/DolphinWX/GameListCtrl.cpp b/Source/Core/DolphinWX/GameListCtrl.cpp index 68e18b2379..a1bbb00928 100644 --- a/Source/Core/DolphinWX/GameListCtrl.cpp +++ b/Source/Core/DolphinWX/GameListCtrl.cpp @@ -448,7 +448,8 @@ void CGameListCtrl::ReloadList() 0); SetColumnWidth(COLUMN_BANNER, SConfig::GetInstance().m_showBannerColumn ? FromDIP(96 + platform_padding) : 0); - SetColumnWidth(COLUMN_TITLE, FromDIP(175 + platform_padding)); + SetColumnWidth(COLUMN_TITLE, + SConfig::GetInstance().m_showTitleColumn ? FromDIP(175 + platform_padding) : 0); SetColumnWidth(COLUMN_MAKER, SConfig::GetInstance().m_showMakerColumn ? FromDIP(150 + platform_padding) : 0); SetColumnWidth(COLUMN_FILENAME, SConfig::GetInstance().m_showFileNameColumn ? @@ -1433,27 +1434,46 @@ void CGameListCtrl::AutomaticColumnWidth() rc.GetWidth() - (GetColumnWidth(COLUMN_PLATFORM) + GetColumnWidth(COLUMN_BANNER) + GetColumnWidth(COLUMN_ID) + GetColumnWidth(COLUMN_COUNTRY) + GetColumnWidth(COLUMN_SIZE) + GetColumnWidth(COLUMN_EMULATION_STATE)); - - if (SConfig::GetInstance().m_showMakerColumn && SConfig::GetInstance().m_showFileNameColumn) + if (SConfig::GetInstance().m_showTitleColumn && SConfig::GetInstance().m_showMakerColumn && + SConfig::GetInstance().m_showFileNameColumn) { SetColumnWidth(COLUMN_TITLE, resizable / 3); SetColumnWidth(COLUMN_MAKER, resizable / 3); SetColumnWidth(COLUMN_FILENAME, resizable / 3); } - else if (SConfig::GetInstance().m_showMakerColumn) + else if (SConfig::GetInstance().m_showMakerColumn && + SConfig::GetInstance().m_showFileNameColumn) { - SetColumnWidth(COLUMN_TITLE, resizable / 2); SetColumnWidth(COLUMN_MAKER, resizable / 2); + SetColumnWidth(COLUMN_FILENAME, resizable / 2); } - else if (SConfig::GetInstance().m_showFileNameColumn) + else if (SConfig::GetInstance().m_showMakerColumn && SConfig::GetInstance().m_showTitleColumn) + { + SetColumnWidth(COLUMN_MAKER, resizable / 2); + SetColumnWidth(COLUMN_TITLE, resizable / 2); + } + else if (SConfig::GetInstance().m_showFileNameColumn && + SConfig::GetInstance().m_showTitleColumn) { SetColumnWidth(COLUMN_TITLE, resizable / 2); SetColumnWidth(COLUMN_FILENAME, resizable / 2); } - else + else if (SConfig::GetInstance().m_showMakerColumn) + { + SetColumnWidth(COLUMN_MAKER, resizable); + } + else if (SConfig::GetInstance().m_showFileNameColumn) + { + SetColumnWidth(COLUMN_FILENAME, resizable); + } + else if (SConfig::GetInstance().m_showTitleColumn) { SetColumnWidth(COLUMN_TITLE, resizable); } + else + { + SetColumnWidth(COLUMN_DUMMY, resizable); + } } Thaw(); } diff --git a/Source/Core/DolphinWX/Globals.h b/Source/Core/DolphinWX/Globals.h index 8465d091c3..2558874e48 100644 --- a/Source/Core/DolphinWX/Globals.h +++ b/Source/Core/DolphinWX/Globals.h @@ -160,6 +160,7 @@ enum // List Column Title Toggles IDM_SHOW_SYSTEM = IDM_DEBUG_WINDOW_LIST_END, IDM_SHOW_BANNER, + IDM_SHOW_TITLE, IDM_SHOW_MAKER, IDM_SHOW_FILENAME, IDM_SHOW_ID, diff --git a/Source/Core/DolphinWX/MainMenuBar.cpp b/Source/Core/DolphinWX/MainMenuBar.cpp index 3dc8736d14..c4119ded4a 100644 --- a/Source/Core/DolphinWX/MainMenuBar.cpp +++ b/Source/Core/DolphinWX/MainMenuBar.cpp @@ -276,6 +276,8 @@ wxMenu* MainMenuBar::CreateViewMenu() const columns_menu->Check(IDM_SHOW_SYSTEM, config_instance.m_showSystemColumn); columns_menu->AppendCheckItem(IDM_SHOW_BANNER, _("Banner")); columns_menu->Check(IDM_SHOW_BANNER, config_instance.m_showBannerColumn); + columns_menu->AppendCheckItem(IDM_SHOW_TITLE, _("Title")); + columns_menu->Check(IDM_SHOW_TITLE, config_instance.m_showTitleColumn); columns_menu->AppendCheckItem(IDM_SHOW_MAKER, _("Maker")); columns_menu->Check(IDM_SHOW_MAKER, config_instance.m_showMakerColumn); columns_menu->AppendCheckItem(IDM_SHOW_FILENAME, _("File Name"));