mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 01:58:19 +00:00
Reuse MouseInside variable
This commit is contained in:
parent
0f6572ebf6
commit
cae2b49ed6
|
@ -234,7 +234,7 @@ void CMenus::DoButton_KeySelect(const void *pID, const char *pText, int Checked,
|
|||
|
||||
int CMenus::DoButton_MenuTab(const void *pID, const char *pText, int Checked, const CUIRect *pRect, int Corners, SUIAnimator *pAnimator, const ColorRGBA *pDefaultColor, const ColorRGBA *pActiveColor, const ColorRGBA *pHoverColor, float EdgeRounding, int AlignVertically)
|
||||
{
|
||||
bool MouseInside = UI()->MouseInside(pRect);
|
||||
const bool MouseInside = UI()->MouseInside(pRect);
|
||||
CUIRect Rect = *pRect;
|
||||
|
||||
if(pAnimator != NULL)
|
||||
|
@ -272,7 +272,7 @@ int CMenus::DoButton_MenuTab(const void *pID, const char *pText, int Checked, co
|
|||
}
|
||||
else
|
||||
{
|
||||
if(UI()->MouseInside(pRect))
|
||||
if(MouseInside)
|
||||
{
|
||||
ColorRGBA HoverColorMenuTab = ms_ColorTabbarHover;
|
||||
if(pHoverColor)
|
||||
|
|
Loading…
Reference in a new issue