mirror of
https://github.com/libretro/ppsspp.git
synced 2024-11-22 23:59:42 +00:00
Show region on game selection screen
This commit is contained in:
parent
6610cd7663
commit
592d6f902e
@ -448,6 +448,7 @@ static ConfigSetting generalSettings[] = {
|
||||
ConfigSetting("EnableStateUndo", &g_Config.bEnableStateUndo, &DefaultEnableStateUndo, true, true),
|
||||
ConfigSetting("RewindFlipFrequency", &g_Config.iRewindFlipFrequency, 0, true, true),
|
||||
|
||||
ConfigSetting("ShowRegionOnGameIcon", &g_Config.bShowRegionOnGameIcon, false, true, true),
|
||||
ConfigSetting("GridView1", &g_Config.bGridView1, true),
|
||||
ConfigSetting("GridView2", &g_Config.bGridView2, true),
|
||||
ConfigSetting("GridView3", &g_Config.bGridView3, false),
|
||||
|
@ -209,6 +209,7 @@ public:
|
||||
// UI
|
||||
bool bShowDebuggerOnLoad;
|
||||
int iShowFPSCounter;
|
||||
bool bShowRegionOnGameIcon;
|
||||
|
||||
// TODO: Maybe move to a separate theme system.
|
||||
uint32_t uItemStyleFg;
|
||||
|
@ -265,6 +265,7 @@ void GameInfo::ParseParamSFO() {
|
||||
case 'J': region = GAMEREGION_JAPAN; break;
|
||||
case 'H': region = GAMEREGION_HONGKONG; break;
|
||||
case 'A': region = GAMEREGION_ASIA; break;
|
||||
case 'K': region = GAMEREGION_KOREA; break;
|
||||
}
|
||||
/*
|
||||
if (regStr == "NPEZ" || regStr == "NPEG" || regStr == "ULES" || regStr == "UCES" ||
|
||||
|
@ -46,6 +46,7 @@ enum GameRegion {
|
||||
GAMEREGION_EUROPE,
|
||||
GAMEREGION_HONGKONG,
|
||||
GAMEREGION_ASIA,
|
||||
GAMEREGION_KOREA,
|
||||
GAMEREGION_OTHER,
|
||||
GAMEREGION_MAX,
|
||||
};
|
||||
|
@ -217,7 +217,8 @@ void GameScreen::render() {
|
||||
"USA",
|
||||
"Europe",
|
||||
"Hong Kong",
|
||||
"Asia"
|
||||
"Asia",
|
||||
"Korea"
|
||||
};
|
||||
tvRegion_->SetText(ga->T(regionNames[info->region]));
|
||||
} else if (info->region > GAMEREGION_MAX){
|
||||
|
@ -718,6 +718,7 @@ void GameSettingsScreen::CreateViews() {
|
||||
#endif
|
||||
|
||||
systemSettings->Add(new CheckBox(&g_Config.bCheckForNewVersion, sy->T("VersionCheck", "Check for new versions of PPSSPP")));
|
||||
systemSettings->Add(new CheckBox(&g_Config.bShowRegionOnGameIcon, sy->T("Show region on game icon")));
|
||||
if (g_Config.iMaxRecent > 0)
|
||||
systemSettings->Add(new Choice(sy->T("Clear Recent Games List")))->OnClick.Handle(this, &GameSettingsScreen::OnClearRecents);
|
||||
|
||||
|
@ -363,6 +363,17 @@ void GameButton::Draw(UIContext &dc) {
|
||||
if (ginfo->hasConfig && !ginfo->id.empty()) {
|
||||
dc.Draw()->DrawImage(I_GEAR, x, y + h - ui_images[I_GEAR].h, 1.0f);
|
||||
}
|
||||
if (g_Config.bShowRegionOnGameIcon && ginfo->region >= 0 && ginfo->region < GAMEREGION_MAX && ginfo->region != GAMEREGION_OTHER) {
|
||||
static const int regionIcons[GAMEREGION_MAX] = {
|
||||
I_FLAG_JP,
|
||||
I_FLAG_US,
|
||||
I_FLAG_EU,
|
||||
I_FLAG_HK,
|
||||
I_FLAG_AS,
|
||||
I_FLAG_KO
|
||||
};
|
||||
dc.Draw()->DrawImage(regionIcons[ginfo->region], x + w - ui_images[regionIcons[ginfo->region]].w - 5, y + h - ui_images[regionIcons[ginfo->region]].h - 5, 1.0f);
|
||||
}
|
||||
if (overlayColor) {
|
||||
dc.FillRect(Drawable(overlayColor), overlayBounds);
|
||||
}
|
||||
|
68025
UI/ui_atlas.cpp
68025
UI/ui_atlas.cpp
File diff suppressed because it is too large
Load Diff
@ -49,7 +49,13 @@
|
||||
#define I_5 38
|
||||
#define I_6 39
|
||||
#define I_PSP_DISPLAY 40
|
||||
#define I_FLAG_JP 41
|
||||
#define I_FLAG_US 42
|
||||
#define I_FLAG_EU 43
|
||||
#define I_FLAG_HK 44
|
||||
#define I_FLAG_AS 45
|
||||
#define I_FLAG_KO 46
|
||||
|
||||
|
||||
extern const Atlas ui_atlas;
|
||||
extern const AtlasImage ui_images[41];
|
||||
extern const AtlasImage ui_images[47];
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -42,3 +42,9 @@ image I_4 source_assets/image/4.png copy
|
||||
image I_5 source_assets/image/5.png copy
|
||||
image I_6 source_assets/image/6.png copy
|
||||
image I_PSP_DISPLAY source_assets/image/psp_display.png copy
|
||||
image I_FLAG_JP source_assets/image/flag_jp.png copy
|
||||
image I_FLAG_US source_assets/image/flag_us.png copy
|
||||
image I_FLAG_EU source_assets/image/flag_eu.png copy
|
||||
image I_FLAG_HK source_assets/image/flag_hk.png copy
|
||||
image I_FLAG_AS source_assets/image/flag_as.png copy
|
||||
image I_FLAG_KO source_assets/image/flag_ko.png copy
|
||||
|
@ -41,3 +41,9 @@ image I_4 source_assets/image/4.png copy
|
||||
image I_5 source_assets/image/5.png copy
|
||||
image I_6 source_assets/image/6.png copy
|
||||
image I_PSP_DISPLAY source_assets/image/psp_display.png copy
|
||||
image I_FLAG_JP source_assets/image/flag_jp.png copy
|
||||
image I_FLAG_US source_assets/image/flag_us.png copy
|
||||
image I_FLAG_EU source_assets/image/flag_eu.png copy
|
||||
image I_FLAG_HK source_assets/image/flag_hk.png copy
|
||||
image I_FLAG_AS source_assets/image/flag_as.png copy
|
||||
image I_FLAG_KO source_assets/image/flag_ko.png copy
|
||||
|
BIN
source_assets/image/flag_as.png
Normal file
BIN
source_assets/image/flag_as.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 669 B |
BIN
source_assets/image/flag_eu.png
Normal file
BIN
source_assets/image/flag_eu.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 806 B |
BIN
source_assets/image/flag_hk.png
Normal file
BIN
source_assets/image/flag_hk.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 766 B |
BIN
source_assets/image/flag_jp.png
Normal file
BIN
source_assets/image/flag_jp.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 529 B |
BIN
source_assets/image/flag_ko.png
Normal file
BIN
source_assets/image/flag_ko.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 807 B |
BIN
source_assets/image/flag_us.png
Normal file
BIN
source_assets/image/flag_us.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 792 B |
Loading…
Reference in New Issue
Block a user