MCPcopy Create free account
hub / github.com/ddnet/ddnet / PopupProofMode

Method PopupProofMode

src/game/editor/popups.cpp:2997–3020  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2995}
2996
2997CUi::EPopupMenuFunctionResult CEditor::PopupProofMode(void *pContext, CUIRect View, bool Active)
2998{
2999 CEditor *pEditor = static_cast<CEditor *>(pContext);
3000
3001 CUIRect Button;
3002 View.HSplitTop(12.0f, &Button, &View);
3003 static int s_ButtonIngame;
3004 if(pEditor->DoButton_MenuItem(&s_ButtonIngame, "Ingame", pEditor->MapView()->ProofMode()->IsModeIngame(), &Button, BUTTONFLAG_LEFT, "These borders represent what a player maximum can see."))
3005 {
3006 pEditor->MapView()->ProofMode()->SetModeIngame();
3007 return CUi::POPUP_CLOSE_CURRENT;
3008 }
3009
3010 View.HSplitTop(2.0f, nullptr, &View);
3011 View.HSplitTop(12.0f, &Button, &View);
3012 static int s_ButtonMenu;
3013 if(pEditor->DoButton_MenuItem(&s_ButtonMenu, "Menu", pEditor->MapView()->ProofMode()->IsModeMenu(), &Button, BUTTONFLAG_LEFT, "These borders represent what will be shown in the menu."))
3014 {
3015 pEditor->MapView()->ProofMode()->SetModeMenu();
3016 return CUi::POPUP_CLOSE_CURRENT;
3017 }
3018
3019 return CUi::POPUP_KEEP_OPEN;
3020}
3021
3022CUi::EPopupMenuFunctionResult CEditor::PopupAnimateSettings(void *pContext, CUIRect View, bool Active)
3023{

Callers

nothing calls this directly

Calls 7

HSplitTopMethod · 0.80
DoButton_MenuItemMethod · 0.80
IsModeIngameMethod · 0.80
ProofModeMethod · 0.80
SetModeIngameMethod · 0.80
IsModeMenuMethod · 0.80
SetModeMenuMethod · 0.80

Tested by

no test coverage detected