Bump maxrecent default to 60. Don't show CPU name if we don't have one.

See #14707 and #10620
This commit is contained in:
Henrik Rydgård 2021-08-09 09:22:55 +02:00
parent aa3daca293
commit 22c180ef6f
2 changed files with 8 additions and 3 deletions

View File

@ -1300,12 +1300,12 @@ void Config::Load(const char *iniFileName, const char *controllerIniFilename) {
LogManager::GetInstance()->LoadConfig(log, debugDefaults);
Section *recent = iniFile.GetOrCreateSection("Recent");
recent->Get("MaxRecent", &iMaxRecent, 30);
recent->Get("MaxRecent", &iMaxRecent, 60);
// Fix issue from switching from uint (hex in .ini) to int (dec)
// -1 is okay, though. We'll just ignore recent stuff if it is.
if (iMaxRecent == 0)
iMaxRecent = 30;
iMaxRecent = 60;
if (iMaxRecent > 0) {
recentIsos.clear();

View File

@ -480,7 +480,12 @@ void SystemInfoScreen::CreateViews() {
#endif
deviceSpecs->Add(new ItemHeader(si->T("CPU Information")));
deviceSpecs->Add(new InfoItem(si->T("CPU Name", "Name"), cpu_info.brand_string));
// Don't bother showing the CPU name if we don't have one.
if (cpu_info.brand_string != "Unknown") {
deviceSpecs->Add(new InfoItem(si->T("CPU Name", "Name"), cpu_info.brand_string));
}
int totalThreads = cpu_info.num_cores * cpu_info.logical_cpu_count;
std::string cores = StringFromFormat(si->T("%d (%d per core, %d cores)"), totalThreads, cpu_info.logical_cpu_count, cpu_info.num_cores);
deviceSpecs->Add(new InfoItem(si->T("Threads"), cores));