mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 01:58:19 +00:00
Modifications in three files
This commit is contained in:
parent
523a3c4450
commit
61ef6210d1
|
@ -953,7 +953,7 @@ void CEditor::DoToolbar(CUIRect ToolBar)
|
|||
if(DoButton_Ex(&s_ProofButton, "Proof", m_ProofBorders, &Button, 0, "[ctrl+p] Toggles proof borders. These borders represent what a player maximum can see.", IGraphics::CORNER_L) ||
|
||||
(m_Dialog == DIALOG_NONE && m_EditBoxActive == 0 && Input()->KeyPress(KEY_P) && ModPressed))
|
||||
{
|
||||
m_ProofBorders = !m_ProofBorders;
|
||||
m_ProofBorders = PROOF_BORDER_OFF;
|
||||
}
|
||||
|
||||
TB_Top.VSplitLeft(10.0f, &Button, &TB_Top);
|
||||
|
@ -2764,7 +2764,7 @@ void CEditor::DoMapEditor(CUIRect View)
|
|||
}
|
||||
|
||||
// menu proof selection
|
||||
if(m_MenuProofBorders && !m_ShowPicker)
|
||||
if(m_ProofBorders == PROOF_BORDER_MENU && !m_ShowPicker)
|
||||
{
|
||||
ResetMenuBackgroundPositions();
|
||||
for(int i = 0; i < (int)m_vMenuBackgroundPositions.size(); i++)
|
||||
|
|
|
@ -796,8 +796,7 @@ public:
|
|||
m_MouseDeltaWy = 0;
|
||||
|
||||
m_GuiActive = true;
|
||||
m_ProofBorders = false;
|
||||
m_MenuProofBorders = false;
|
||||
m_ProofBorders = PROOF_BORDER_OFF;
|
||||
m_CurrentMenuProofIndex = 0;
|
||||
m_PreviewZoom = false;
|
||||
|
||||
|
|
|
@ -2327,18 +2327,18 @@ CUI::EPopupMenuFunctionResult CEditor::PopupProofMode(void *pContext, CUIRect Vi
|
|||
CUIRect Button;
|
||||
View.HSplitTop(12.0f, &Button, &View);
|
||||
static int s_ButtonIngame;
|
||||
if(pEditor->DoButton_MenuItem(&s_ButtonIngame, "Ingame", !pEditor->m_MenuProofBorders, &Button, 0, "These borders represent what a player maximum can see."))
|
||||
if(pEditor->DoButton_MenuItem(&s_ButtonIngame, "Ingame", !pEditor->m_ProofBorders == PROOF_BORDER_INGAME, &Button, 0, "These borders represent what a player maximum can see."))
|
||||
{
|
||||
pEditor->m_MenuProofBorders = false;
|
||||
pEditor->m_ProofBorders = PROOF_BORDER_INGAME;
|
||||
return CUI::POPUP_CLOSE_CURRENT;
|
||||
}
|
||||
|
||||
View.HSplitTop(2.0f, nullptr, &View);
|
||||
View.HSplitTop(12.0f, &Button, &View);
|
||||
static int s_ButtonMenu;
|
||||
if(pEditor->DoButton_MenuItem(&s_ButtonMenu, "Menu", pEditor->m_MenuProofBorders, &Button, 0, "These borders represent what will be shown in the menu."))
|
||||
if(pEditor->DoButton_MenuItem(&s_ButtonMenu, "Menu", pEditor->m_ProofBorders == PROOF_BORDER_INGAME, &Button, 0, "These borders represent what will be shown in the menu."))
|
||||
{
|
||||
pEditor->m_MenuProofBorders = true;
|
||||
pEditor->m_ProofBorders = PROOF_BORDER_INGAME;
|
||||
return CUI::POPUP_CLOSE_CURRENT;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue