summaryrefslogtreecommitdiffstats
path: root/src/core
diff options
context:
space:
mode:
authoreray orçunus <erayorcunus@gmail.com>2020-07-20 21:47:41 +0200
committereray orçunus <erayorcunus@gmail.com>2020-07-20 21:47:41 +0200
commit70df13f9d34fd855b78f74d7f1da8423241f8b01 (patch)
tree6c71b19b940fd919c5b76437180ab35f24c02f40 /src/core
parentavoid UB (diff)
downloadre3-70df13f9d34fd855b78f74d7f1da8423241f8b01.tar
re3-70df13f9d34fd855b78f74d7f1da8423241f8b01.tar.gz
re3-70df13f9d34fd855b78f74d7f1da8423241f8b01.tar.bz2
re3-70df13f9d34fd855b78f74d7f1da8423241f8b01.tar.lz
re3-70df13f9d34fd855b78f74d7f1da8423241f8b01.tar.xz
re3-70df13f9d34fd855b78f74d7f1da8423241f8b01.tar.zst
re3-70df13f9d34fd855b78f74d7f1da8423241f8b01.zip
Diffstat (limited to 'src/core')
-rw-r--r--src/core/Frontend.cpp18
-rw-r--r--src/core/Frontend.h2
2 files changed, 10 insertions, 10 deletions
diff --git a/src/core/Frontend.cpp b/src/core/Frontend.cpp
index e67e939a..6e4e8917 100644
--- a/src/core/Frontend.cpp
+++ b/src/core/Frontend.cpp
@@ -956,10 +956,10 @@ CMenuManager::Draw()
CFont::SetDropShadowPosition(0);
if (!CheckHover(MENU_X(30.0f), MENU_X(30.0f) + CFont::GetStringWidth(backTx), SCREEN_SCALE_FROM_BOTTOM(125.0f), SCREEN_SCALE_FROM_BOTTOM(105.0f))) {
m_nHoverOption = HOVEROPTION_NOT_HOVERING;
- m_nCurrOption = m_nPrevOption = 0;
+ m_nCurrOption = m_nOptionMouseHovering = 0;
} else {
m_nHoverOption = HOVEROPTION_RANDOM_ITEM;
- m_nCurrOption = m_nPrevOption = 1;
+ m_nCurrOption = m_nOptionMouseHovering = 1;
}
return;
}
@@ -1256,7 +1256,7 @@ CMenuManager::Draw()
static int oldOption = -99;
static int oldScreen = m_nCurrScreen;
- m_nPrevOption = rowToCheck;
+ m_nOptionMouseHovering = rowToCheck;
if (m_nMouseOldPosX != m_nMousePosX || m_nMouseOldPosY != m_nMousePosY) {
m_nCurrOption = rowToCheck;
m_bShowMouse = true;
@@ -1980,10 +1980,10 @@ CMenuManager::DrawControllerSetupScreen()
float curOptY = i * rowHeight + yStart;
if (m_nMousePosY > MENU_Y(curOptY) && m_nMousePosY < MENU_Y(rowHeight + curOptY)) {
- if (m_nPrevOption != i && m_nCurrExLayer == HOVEROPTION_LIST)
+ if (m_nOptionMouseHovering != i && m_nCurrExLayer == HOVEROPTION_LIST)
DMAudio.PlayFrontEndSound(SOUND_FRONTEND_MENU_NAVIGATION, 0);
- m_nPrevOption = i;
+ m_nOptionMouseHovering = i;
if (m_nMouseOldPosX != m_nMousePosX || m_nMouseOldPosY != m_nMousePosY) {
m_nCurrExLayer = HOVEROPTION_LIST;
m_nSelectedListRow = i;
@@ -2694,7 +2694,7 @@ CMenuManager::DrawPlayerSetupScreen()
if (m_nMousePosX > MENU_X_LEFT_ALIGNED(PLAYERSETUP_LIST_LEFT) && m_nMousePosX < MENU_X_RIGHT_ALIGNED(PLAYERSETUP_LIST_RIGHT)) {
if (m_nMousePosY > MENU_Y(rowStartY) && m_nMousePosY < MENU_Y(rowEndY)) {
- m_nPrevOption = rowIdx;
+ m_nOptionMouseHovering = rowIdx;
if (m_nMouseOldPosX != m_nMousePosX || m_nMouseOldPosY != m_nMousePosY) {
m_nCurrExLayer = HOVEROPTION_LIST;
}
@@ -4025,7 +4025,7 @@ CMenuManager::ProcessButtonPresses(void)
if (aScreens[m_nCurrScreen].m_aEntries[m_nCurrOption].m_Action == MENUACTION_RESUME &&
#endif
(m_nHoverOption == HOVEROPTION_RANDOM_ITEM)) {
- m_nCurrOption = m_nPrevOption;
+ m_nCurrOption = m_nOptionMouseHovering;
optionSelected = true;
}
} else if (CPad::GetPad(0)->GetLeftMouseJustDown()) {
@@ -4039,7 +4039,7 @@ CMenuManager::ProcessButtonPresses(void)
OutputDebugString("FRONTEND RADIO STATION CHANGED");
} else if (m_nHoverOption == HOVEROPTION_RANDOM_ITEM
&& aScreens[m_nCurrScreen].m_aEntries[m_nCurrOption].m_Action != MENUACTION_RESUME) {
- m_nCurrOption = m_nPrevOption;
+ m_nCurrOption = m_nOptionMouseHovering;
optionSelected = true;
}
#else
@@ -4126,7 +4126,7 @@ CMenuManager::ProcessButtonPresses(void)
break;
case HOVEROPTION_RANDOM_ITEM:
if (((m_nCurrOption != 0) || (m_nCurrScreen != MENUPAGE_PAUSE_MENU)) {
- m_nCurrOption = m_nPrevOption;
+ m_nCurrOption = m_nOptionMouseHovering;
optionSelected = true;
}
break;
diff --git a/src/core/Frontend.h b/src/core/Frontend.h
index 758e29aa..7b0e2f4b 100644
--- a/src/core/Frontend.h
+++ b/src/core/Frontend.h
@@ -518,7 +518,7 @@ public:
int32 m_nHoverOption;
int32 m_nCurrScreen;
int32 m_nCurrOption;
- int32 m_nPrevOption;
+ int32 m_nOptionMouseHovering;
int32 m_nPrevScreen;
uint32 field_558;
int32 m_nCurrSaveSlot;