From de4d970ab60d5ab062aad3cffabff8a46633d8cd Mon Sep 17 00:00:00 2001 From: raven02 Date: Wed, 19 Jun 2013 13:08:29 +0800 Subject: [PATCH] Toggle to adjust VPS/FPS/Both , new timeFormat/dateFormat/buttonPerference --- Core/Config.cpp | 12 ++-- Core/Config.h | 7 +- Core/Dialog/PSPSaveDialog.cpp | 55 +++++++++++----- Core/HLE/sceDisplay.cpp | 2 +- Core/HLE/sceUtility.cpp | 4 +- Core/Reporting.cpp | 2 +- UI/EmuScreen.cpp | 11 +++- UI/MenuScreens.cpp | 119 +++++++++++++++++++++++++++++----- Windows/WndMainWindow.cpp | 4 +- headless/Headless.cpp | 4 +- 10 files changed, 168 insertions(+), 52 deletions(-) diff --git a/Core/Config.cpp b/Core/Config.cpp index dc273895b3..93461ec9a8 100644 --- a/Core/Config.cpp +++ b/Core/Config.cpp @@ -87,7 +87,7 @@ void Config::Load(const char *iniFileName) cpu->Get("FastMemory", &bFastMemory, false); IniFile::Section *graphics = iniFile.GetOrCreateSection("Graphics"); - graphics->Get("ShowFPSCounter", &bShowFPSCounter, false); + graphics->Get("ShowFPSCounter", &iShowFPSCounter, false); graphics->Get("DisplayFramebuffer", &bDisplayFramebuffer, false); #ifdef _WIN32 graphics->Get("ResolutionScale", &iWindowZoom, 2); @@ -143,11 +143,11 @@ void Config::Load(const char *iniFileName) IniFile::Section *pspConfig = iniFile.GetOrCreateSection("SystemParam"); pspConfig->Get("NickName", &sNickName, "shadow"); pspConfig->Get("Language", &ilanguage, PSP_SYSTEMPARAM_LANGUAGE_ENGLISH); - pspConfig->Get("TimeFormat", &itimeformat, PSP_SYSTEMPARAM_TIME_FORMAT_24HR); + pspConfig->Get("TimeFormat", &iTimeFormat, PSP_SYSTEMPARAM_TIME_FORMAT_24HR); pspConfig->Get("DateFormat", &iDateFormat, PSP_SYSTEMPARAM_DATE_FORMAT_YYYYMMDD); pspConfig->Get("TimeZone", &iTimeZone, 0); pspConfig->Get("DayLightSavings", &bDayLightSavings, PSP_SYSTEMPARAM_DAYLIGHTSAVINGS_STD); - pspConfig->Get("ButtonPreference", &bButtonPreference, PSP_SYSTEMPARAM_BUTTON_CROSS); + pspConfig->Get("ButtonPreference", &iButtonPreference, PSP_SYSTEMPARAM_BUTTON_CROSS); pspConfig->Get("LockParentalLevel", &iLockParentalLevel, 0); pspConfig->Get("WlanAdhocChannel", &iWlanAdhocChannel, PSP_SYSTEMPARAM_ADHOC_CHANNEL_AUTOMATIC); pspConfig->Get("WlanPowerSave", &bWlanPowerSave, PSP_SYSTEMPARAM_WLAN_POWERSAVE_OFF); @@ -196,7 +196,7 @@ void Config::Save() cpu->Set("FastMemory", bFastMemory); IniFile::Section *graphics = iniFile.GetOrCreateSection("Graphics"); - graphics->Set("ShowFPSCounter", bShowFPSCounter); + graphics->Set("ShowFPSCounter", iShowFPSCounter); graphics->Set("DisplayFramebuffer", bDisplayFramebuffer); graphics->Set("ResolutionScale", iWindowZoom); graphics->Set("BufferedRendering", bBufferedRendering); @@ -238,11 +238,11 @@ void Config::Save() IniFile::Section *pspConfig = iniFile.GetOrCreateSection("SystemParam"); pspConfig->Set("NickName", sNickName.c_str()); pspConfig->Set("Language", ilanguage); - pspConfig->Set("TimeFormat", itimeformat); + pspConfig->Set("TimeFormat", iTimeFormat); pspConfig->Set("DateFormat", iDateFormat); pspConfig->Set("TimeZone", iTimeZone); pspConfig->Set("DayLightSavings", bDayLightSavings); - pspConfig->Set("ButtonPreference", bButtonPreference); + pspConfig->Set("ButtonPreference", iButtonPreference); pspConfig->Set("LockParentalLevel", iLockParentalLevel); pspConfig->Set("WlanAdhocChannel", iWlanAdhocChannel); pspConfig->Set("WlanPowerSave", bWlanPowerSave); diff --git a/Core/Config.h b/Core/Config.h index 7fbd525e65..a63e571c46 100644 --- a/Core/Config.h +++ b/Core/Config.h @@ -95,7 +95,7 @@ public: bool bShowTouchControls; bool bShowDebuggerOnLoad; bool bShowAnalogStick; - bool bShowFPSCounter; + int iShowFPSCounter; bool bShowDebugStats; bool bLargeControls; bool bAccelerometerToAnalogHoriz; @@ -115,18 +115,19 @@ public: // SystemParam std::string sNickName; int ilanguage; - int itimeformat; + int iTimeFormat; int iDateFormat; int iTimeZone; bool bDayLightSavings; bool bButtonPreference; + int iButtonPreference; int iLockParentalLevel; bool bEncryptSave; int iWlanAdhocChannel; bool bWlanPowerSave; std::string currentDirectory; - std::string externalDirectory; + std::string externalDirectory; std::string memCardDirectory; std::string flashDirectory; std::string internalDataDirectory; diff --git a/Core/Dialog/PSPSaveDialog.cpp b/Core/Dialog/PSPSaveDialog.cpp index 1c1a1b8023..23d32df181 100755 --- a/Core/Dialog/PSPSaveDialog.cpp +++ b/Core/Dialog/PSPSaveDialog.cpp @@ -356,14 +356,24 @@ void PSPSaveDialog::DisplaySaveDataInfo1() char hour_time[10] ; int hour = param.GetFileInfo(currentSelectedSave).modif_time.tm_hour; int min = param.GetFileInfo(currentSelectedSave).modif_time.tm_min; - if (g_Config.itimeformat == PSP_SYSTEMPARAM_TIME_FORMAT_12HR) { + switch (g_Config.iTimeFormat) { + case 1: if (hour > 12) { strcpy(am_pm, "PM"); hour -= 12; } snprintf(hour_time,10,"%02d:%02d %s", hour, min, am_pm); - } else - snprintf(hour_time,10,"%02d:%02d", hour, min); + break; + case 2: + snprintf(hour_time,10,"%02d:%02d", hour, min); + break; + default: + if (hour > 12) { + strcpy(am_pm, "PM"); + hour -= 12; + } + snprintf(hour_time,10,"%02d:%02d %s", hour, min, am_pm); + } snprintf(title, 512, "%s", param.GetFileInfo(currentSelectedSave).title); int day = param.GetFileInfo(currentSelectedSave).modif_time.tm_mday; @@ -371,14 +381,15 @@ void PSPSaveDialog::DisplaySaveDataInfo1() int year = param.GetFileInfo(currentSelectedSave).modif_time.tm_year + 1900; s64 sizeK = param.GetFileInfo(currentSelectedSave).size / 1024; switch (g_Config.iDateFormat) { - case PSP_SYSTEMPARAM_DATE_FORMAT_DDMMYYYY: - snprintf(time, 512, "%02d/%02d/%d %s %lld KB", day, month, year, hour_time, sizeK); + case 1: + snprintf(time, 512, "%d/%02d/%02d %s %lld KB", year, month, day, hour_time, sizeK); break; - case PSP_SYSTEMPARAM_DATE_FORMAT_MMDDYYYY: + case 2: snprintf(time, 512, "%02d/%02d/%d %s %lld KB", month, day, year, hour_time, sizeK); break; - case PSP_SYSTEMPARAM_DATE_FORMAT_YYYYMMDD: - // fall through + case 3: + snprintf(time, 512, "%02d/%02d/%d %s %lld KB", day, month, year, hour_time, sizeK); + break; default: snprintf(time, 512, "%d/%02d/%02d %s %lld KB", year, month, day, hour_time, sizeK); } @@ -408,14 +419,24 @@ void PSPSaveDialog::DisplaySaveDataInfo2() char hour_time[10] ; int hour = param.GetFileInfo(currentSelectedSave).modif_time.tm_hour; int min = param.GetFileInfo(currentSelectedSave).modif_time.tm_min; - if (g_Config.itimeformat == PSP_SYSTEMPARAM_TIME_FORMAT_12HR) { + switch (g_Config.iTimeFormat) { + case 1: if (hour > 12) { strcpy(am_pm, "PM"); hour -= 12; } snprintf(hour_time,10,"%02d:%02d %s", hour, min, am_pm); - } else - snprintf(hour_time,10,"%02d:%02d", hour, min); + break; + case 2: + snprintf(hour_time,10,"%02d:%02d", hour, min); + break; + default: + if (hour > 12) { + strcpy(am_pm, "PM"); + hour -= 12; + } + snprintf(hour_time,10,"%02d:%02d %s", hour, min, am_pm); + } const char *saveTitle = param.GetFileInfo(currentSelectedSave).saveTitle; int day = param.GetFileInfo(currentSelectedSave).modif_time.tm_mday; @@ -423,14 +444,14 @@ void PSPSaveDialog::DisplaySaveDataInfo2() int year = param.GetFileInfo(currentSelectedSave).modif_time.tm_year + 1900; s64 sizeK = param.GetFileInfo(currentSelectedSave).size / 1024; switch (g_Config.iDateFormat) { - case PSP_SYSTEMPARAM_DATE_FORMAT_DDMMYYYY: - snprintf(date, 256, "%02d/%02d/%d", day, month, year); - break; - case PSP_SYSTEMPARAM_DATE_FORMAT_MMDDYYYY: + case 1: + snprintf(date, 256, "%d/%02d/%02d", year, month, day); + case 2: snprintf(date, 256, "%02d/%02d/%d", month, day, year); break; - case PSP_SYSTEMPARAM_DATE_FORMAT_YYYYMMDD: - // fall through + case 3: + snprintf(date, 256, "%02d/%02d/%d", day, month, year); + break; default: snprintf(date, 256, "%d/%02d/%02d", year, month, day); } diff --git a/Core/HLE/sceDisplay.cpp b/Core/HLE/sceDisplay.cpp index 7f7688deff..6a0fbe358e 100644 --- a/Core/HLE/sceDisplay.cpp +++ b/Core/HLE/sceDisplay.cpp @@ -426,7 +426,7 @@ void hleEnterVblank(u64 userdata, int cyclesLate) { gpuStats.numFrames++; - if (g_Config.bShowFPSCounter) { + if (g_Config.iShowFPSCounter) { CalculateFPS(); } diff --git a/Core/HLE/sceUtility.cpp b/Core/HLE/sceUtility.cpp index 8253876bff..e254cf973b 100644 --- a/Core/HLE/sceUtility.cpp +++ b/Core/HLE/sceUtility.cpp @@ -461,7 +461,7 @@ u32 sceUtilityGetSystemParamInt(u32 id, u32 destaddr) param = g_Config.iDateFormat; break; case PSP_SYSTEMPARAM_ID_INT_TIME_FORMAT: - param = g_Config.itimeformat?PSP_SYSTEMPARAM_TIME_FORMAT_12HR:PSP_SYSTEMPARAM_TIME_FORMAT_24HR; + param = g_Config.iTimeFormat?PSP_SYSTEMPARAM_TIME_FORMAT_12HR:PSP_SYSTEMPARAM_TIME_FORMAT_24HR; break; case PSP_SYSTEMPARAM_ID_INT_TIMEZONE: param = g_Config.iTimeZone; @@ -473,7 +473,7 @@ u32 sceUtilityGetSystemParamInt(u32 id, u32 destaddr) param = g_Config.ilanguage; break; case PSP_SYSTEMPARAM_ID_INT_BUTTON_PREFERENCE: - param = g_Config.bButtonPreference?PSP_SYSTEMPARAM_BUTTON_CROSS:PSP_SYSTEMPARAM_BUTTON_CIRCLE; + param = g_Config.iButtonPreference?PSP_SYSTEMPARAM_BUTTON_CROSS:PSP_SYSTEMPARAM_BUTTON_CIRCLE; break; case PSP_SYSTEMPARAM_ID_INT_LOCK_PARENTAL_LEVEL: param = g_Config.iLockParentalLevel; diff --git a/Core/Reporting.cpp b/Core/Reporting.cpp index 8cbabbed25..32f22b8d17 100644 --- a/Core/Reporting.cpp +++ b/Core/Reporting.cpp @@ -211,7 +211,7 @@ namespace Reporting postdata.Add("pixel_height", PSP_CoreParameter().pixelHeight); postdata.Add("ticks", (const uint64_t)CoreTiming::GetTicks()); - if (g_Config.bShowFPSCounter) + if (g_Config.iShowFPSCounter) { float vps, fps; __DisplayGetAveragedFPS(&vps, &fps); diff --git a/UI/EmuScreen.cpp b/UI/EmuScreen.cpp index 5ce338c37d..e461ab91ed 100644 --- a/UI/EmuScreen.cpp +++ b/UI/EmuScreen.cpp @@ -337,11 +337,18 @@ void EmuScreen::render() { ui_draw2d.SetFontScale(1.0f, 1.0f); } - if (g_Config.bShowFPSCounter) { + if (g_Config.iShowFPSCounter) { float vps, fps; __DisplayGetFPS(&vps, &fps); char fpsbuf[256]; - sprintf(fpsbuf, "VPS: %0.1f\nFPS: %0.1f", vps, fps); + switch (g_Config.iShowFPSCounter) { + case 2: + sprintf(fpsbuf, "VPS: %0.1f", vps); break; + case 3: + sprintf(fpsbuf, "FPS: %0.1f", fps); break; + case 4: + sprintf(fpsbuf, "VPS: %0.1f\nFPS: %0.1f", vps, fps); break; + } ui_draw2d.DrawText(UBUNTU24, fpsbuf, dp_xres - 8, 12, 0xc0000000, ALIGN_TOPRIGHT); ui_draw2d.DrawText(UBUNTU24, fpsbuf, dp_xres - 10, 10, 0xFF3fFF3f, ALIGN_TOPRIGHT); } diff --git a/UI/MenuScreens.cpp b/UI/MenuScreens.cpp index dbcc1b3b84..d4028b2757 100644 --- a/UI/MenuScreens.cpp +++ b/UI/MenuScreens.cpp @@ -465,8 +465,6 @@ void PauseScreen::render() { if (gpu) gpu->Resized(); } - UICheckBox(GEN_ID, x, y += stride, ss->T("Show FPS"), ALIGN_TOPLEFT, &g_Config.bShowFPSCounter); - bool enableFrameSkip = g_Config.iFrameSkip != 0; UICheckBox(GEN_ID, x, y += stride , gs->T("Frame Skipping"), ALIGN_TOPLEFT, &enableFrameSkip); if (enableFrameSkip) { @@ -686,24 +684,24 @@ void DeveloperScreen::render() { screenManager()->finishDialog(this, DR_OK); } - if (UIButton(GEN_ID, vlinear, w, 0, d->T("Load language ini"), ALIGN_LEFT)) { + if (UIButton(GEN_ID, vlinear, LARGE_BUTTON_WIDTH + 80, 0, d->T("Load language ini"), ALIGN_LEFT)) { i18nrepo.LoadIni(g_Config.languageIni); // After this, g and s are no longer valid. Need to reload them. g = GetI18NCategory("General"); d = GetI18NCategory("Developer"); } - if (UIButton(GEN_ID, vlinear, w, 0, d->T("Save language ini"), ALIGN_LEFT)) { + if (UIButton(GEN_ID, vlinear, LARGE_BUTTON_WIDTH + 80, 0, d->T("Save language ini"), ALIGN_LEFT)) { i18nrepo.SaveIni(g_Config.languageIni); } - if (UIButton(GEN_ID, vlinear, w, 0, d->T("Run CPU tests"), ALIGN_LEFT)) { + if (UIButton(GEN_ID, vlinear, LARGE_BUTTON_WIDTH + 80, 0, d->T("Run CPU Tests"), ALIGN_LEFT)) { // TODO: Run tests RunTests(); // screenManager()->push(new EmuScreen()) } - if (UIButton(GEN_ID, vlinear, w, 0, d->T("Dump frame to log"), ALIGN_LEFT)) { + if (UIButton(GEN_ID, vlinear, LARGE_BUTTON_WIDTH + 80, 0, d->T("Dump next frame"), ALIGN_LEFT)) { gpu->DumpNextFrame(); } @@ -928,7 +926,35 @@ void GraphicsScreenP3::render() { int y = 35; int stride = 40; int columnw = 400; + + bool ShowCounter = g_Config.iShowFPSCounter > 0; + UICheckBox(GEN_ID, x, y += stride, gs->T("Show VPS/FPS"), ALIGN_TOPLEFT, &ShowCounter); + if (ShowCounter) { + if (g_Config.iShowFPSCounter <= 0) + g_Config.iShowFPSCounter = 1; + char counter[256]; + std::string type; + + switch (g_Config.iShowFPSCounter) { + case 1: type = "VPS";break; + case 2: type = "FPS";break; + case 3: type = "Both";break; + } + sprintf(counter, "%s %s", gs->T("Format :"), type.c_str()); + ui_draw2d.DrawText(UBUNTU24, counter, x + 60, y += stride , 0xFFFFFFFF, ALIGN_LEFT); + HLinear hlinear1(x + 250, y, 20); + if (UIButton(GEN_ID, hlinear1, 80, 0, gs->T("VPS"), ALIGN_LEFT)) + g_Config.iShowFPSCounter = 1; + if (UIButton(GEN_ID, hlinear1, 80, 0, gs->T("FPS"), ALIGN_LEFT)) + g_Config.iShowFPSCounter = 2; + if (UIButton(GEN_ID, hlinear1, 90, 0, gs->T("Both"), ALIGN_LEFT)) + g_Config.iShowFPSCounter = 3; + + y += 20; + } else + g_Config.iShowFPSCounter = 0; + bool FpsLimit = g_Config.iFpsLimit != 0; UICheckBox(GEN_ID, x, y += stride, gs->T("FPS Limit"), ALIGN_TOPLEFT, &FpsLimit); if (FpsLimit) { @@ -1122,13 +1148,74 @@ void SystemScreen::render() { #endif if (g_Config.bJit) UICheckBox(GEN_ID, x, y += stride, s->T("Fast Memory", "Fast Memory (unstable)"), ALIGN_TOPLEFT, &g_Config.bFastMemory); - UICheckBox(GEN_ID, x, y += stride, s->T("Show FPS"), ALIGN_TOPLEFT, &g_Config.bShowFPSCounter); - UICheckBox(GEN_ID, x, y += stride, s->T("Encrypt Save"), ALIGN_TOPLEFT, &g_Config.bEncryptSave); - UICheckBox(GEN_ID, x, y += stride, s->T("Use Button X to Confirm"), ALIGN_TOPLEFT, &g_Config.bButtonPreference); - bool tf = g_Config.itimeformat == 1; - if (UICheckBox(GEN_ID, x, y += stride, s->T("12HR Time Format"), ALIGN_TOPLEFT, &tf)) { - g_Config.itimeformat = tf ? 1 : 0; + + UICheckBox(GEN_ID, x, y += stride, s->T("Daylight Savings"), ALIGN_TOPLEFT, &g_Config.bDayLightSavings); + UICheckBox(GEN_ID, x, y += stride, s->T("Button Perference"), ALIGN_TOPLEFT, &g_Config.bButtonPreference); + if (g_Config.bButtonPreference) { + char button[256]; + std::string type; + switch (g_Config.iButtonPreference) { + case 0: type = "O to Enter";break; + case 1: type = "X to Enter";break; + } + sprintf(button, "%s %s", s->T("Type :"), type.c_str()); + ui_draw2d.DrawText(UBUNTU24, button, x + 60, y += stride , 0xFFFFFFFF, ALIGN_LEFT); + HLinear hlinear1(x + 280, y, 20); + if (UIButton(GEN_ID, hlinear1, 90, 0, s->T("Use O"), ALIGN_LEFT)) + g_Config.iButtonPreference = 0; + if (UIButton(GEN_ID, hlinear1, 90, 0, s->T("Use X"), ALIGN_LEFT)) + g_Config.iButtonPreference = 1; + y += 10; } + + bool time = g_Config.iTimeFormat > 0 ; + UICheckBox(GEN_ID, x, y += stride, s->T("Time Format"), ALIGN_TOPLEFT, &time); + if (time) { + if (g_Config.iTimeFormat <= 0) + g_Config.iTimeFormat = 1; + + char button[256]; + std::string type; + switch (g_Config.iTimeFormat) { + case 1: type = "12HR";break; + case 2: type = "24HR";break; + } + sprintf(button, "%s %s", s->T("Format :"), type.c_str()); + ui_draw2d.DrawText(UBUNTU24, button, x + 60, y += stride , 0xFFFFFFFF, ALIGN_LEFT); + HLinear hlinear1(x + 280, y, 20); + if (UIButton(GEN_ID, hlinear1, 80, 0, s->T("12HR"), ALIGN_LEFT)) + g_Config.iTimeFormat = 1; + if (UIButton(GEN_ID, hlinear1, 80, 0, s->T("24HR"), ALIGN_LEFT)) + g_Config.iTimeFormat = 2; + y += 10; + } else + g_Config.iTimeFormat = 0 ; + + bool date = g_Config.iDateFormat > 0; + UICheckBox(GEN_ID, x, y += stride, s->T("Date Format"), ALIGN_TOPLEFT, &date); + if (date) { + if (g_Config.iDateFormat <= 0) + g_Config.iDateFormat = 1; + char button[256]; + std::string type; + switch (g_Config.iDateFormat) { + case 1: type = "YYYYMMDD";break; + case 2: type = "MMDDYYYY";break; + case 3: type = "DDMMYYYY";break; + } + sprintf(button, "%s %s", s->T("Format :"), type.c_str()); + ui_draw2d.DrawText(UBUNTU24, button, x + 60, y += stride , 0xFFFFFFFF, ALIGN_LEFT); + HLinear hlinear1(x + 350, y, 10); + if (UIButton(GEN_ID, hlinear1, 70, 0, s->T("YMD"), ALIGN_LEFT)) + g_Config.iDateFormat = 1; + if (UIButton(GEN_ID, hlinear1, 70, 0, s->T("MDY"), ALIGN_LEFT)) + g_Config.iDateFormat = 2; + if (UIButton(GEN_ID, hlinear1, 70, 0, s->T("DMY"), ALIGN_LEFT)) + g_Config.iDateFormat = 3; + y += 10; + } else + g_Config.iDateFormat = 0; + UICheckBox(GEN_ID, x, y += stride, s->T("Enable Cheats"), ALIGN_TOPLEFT, &g_Config.bEnableCheats); if (g_Config.bEnableCheats) { HLinear hlinear1(x + 60, y += stride + 10, 20); @@ -1139,7 +1226,7 @@ void SystemScreen::render() { HLinear hlinear2(x, y += stride + 10, 20); if (UIButton(GEN_ID, hlinear2, LARGE_BUTTON_WIDTH, 0, s->T("Language"), ALIGN_TOPLEFT)) { screenManager()->push(new LanguageScreen()); - } + } UIEnd(); } @@ -1166,6 +1253,8 @@ void ControlsScreen::render() { int columnw = 440; UICheckBox(GEN_ID, x, y += stride, c->T("OnScreen", "On-Screen Touch Controls"), ALIGN_TOPLEFT, &g_Config.bShowTouchControls); + UICheckBox(GEN_ID, x, y += stride, c->T("Show Analog Stick"), ALIGN_TOPLEFT, &g_Config.bShowAnalogStick); + UICheckBox(GEN_ID, x, y += stride, c->T("Tilt", "Tilt to Analog (horizontal)"), ALIGN_TOPLEFT, &g_Config.bAccelerometerToAnalogHoriz); if (g_Config.bShowTouchControls) { UICheckBox(GEN_ID, x, y += stride, c->T("Buttons Scaling"), ALIGN_TOPLEFT, &g_Config.bLargeControls); if (g_Config.bLargeControls) { @@ -1183,11 +1272,10 @@ void ControlsScreen::render() { g_Config.fButtonScale += 0.1; y += 20; } - UICheckBox(GEN_ID, x, y += stride, c->T("Show Analog Stick"), ALIGN_TOPLEFT, &g_Config.bShowAnalogStick); // This will be a slider in the new UI later bool bTransparent = g_Config.iTouchButtonOpacity < 65; bool prev = bTransparent; - UICheckBox(GEN_ID, x, y += stride, c->T("Transparent Buttons"), ALIGN_TOPLEFT, &bTransparent); + UICheckBox(GEN_ID, x, y += stride, c->T("Buttons Opacity"), ALIGN_TOPLEFT, &bTransparent); if (bTransparent) { char opacity[256]; sprintf(opacity, "%s %d", c->T("Opacity :"), g_Config.iTouchButtonOpacity); @@ -1206,7 +1294,6 @@ void ControlsScreen::render() { if (bTransparent != prev) g_Config.iTouchButtonOpacity = bTransparent ? 15 : 65; } - UICheckBox(GEN_ID, x, y += stride, c->T("Tilt", "Tilt to Analog (horizontal)"), ALIGN_TOPLEFT, &g_Config.bAccelerometerToAnalogHoriz); UIEnd(); } diff --git a/Windows/WndMainWindow.cpp b/Windows/WndMainWindow.cpp index 34a0176c77..ee02b7bc89 100644 --- a/Windows/WndMainWindow.cpp +++ b/Windows/WndMainWindow.cpp @@ -726,7 +726,7 @@ namespace MainWindow g_Config.bVertexCache = !g_Config.bVertexCache; break; case ID_OPTIONS_SHOWFPS: - g_Config.bShowFPSCounter = !g_Config.bShowFPSCounter; + g_Config.iShowFPSCounter = !g_Config.iShowFPSCounter; break; case ID_OPTIONS_DISPLAYRAWFRAMEBUFFER: g_Config.bDisplayFramebuffer = !g_Config.bDisplayFramebuffer; @@ -898,7 +898,7 @@ namespace MainWindow CHECKITEM(ID_EMULATION_RUNONLOAD, g_Config.bAutoRun); CHECKITEM(ID_OPTIONS_USEVBO, g_Config.bUseVBO); CHECKITEM(ID_OPTIONS_VERTEXCACHE, g_Config.bVertexCache); - CHECKITEM(ID_OPTIONS_SHOWFPS, g_Config.bShowFPSCounter); + CHECKITEM(ID_OPTIONS_SHOWFPS, g_Config.iShowFPSCounter); CHECKITEM(ID_OPTIONS_FRAMESKIP, g_Config.iFrameSkip != 0); CHECKITEM(ID_OPTIONS_MIPMAP, g_Config.bMipMap); CHECKITEM(ID_OPTIONS_VSYNC, g_Config.iVSyncInterval != 0); diff --git a/headless/Headless.cpp b/headless/Headless.cpp index af2375fe67..5bba70a795 100644 --- a/headless/Headless.cpp +++ b/headless/Headless.cpp @@ -200,12 +200,12 @@ int main(int argc, const char* argv[]) g_Config.bVertexCache = true; g_Config.bTrueColor = true; g_Config.ilanguage = PSP_SYSTEMPARAM_LANGUAGE_ENGLISH; - g_Config.itimeformat = PSP_SYSTEMPARAM_TIME_FORMAT_24HR; + g_Config.iTimeFormat = PSP_SYSTEMPARAM_TIME_FORMAT_24HR; g_Config.bEncryptSave = true; g_Config.sNickName = "shadow"; g_Config.iTimeZone = 60; g_Config.iDateFormat = PSP_SYSTEMPARAM_DATE_FORMAT_DDMMYYYY; - g_Config.bButtonPreference = true; + g_Config.iButtonPreference = PSP_SYSTEMPARAM_BUTTON_CROSS; g_Config.iLockParentalLevel = 9; #if defined(ANDROID)