- scriptified the input methods of DConversationMenu.

- fixed handling of DimAllowed.
This commit is contained in:
Christoph Oelckers 2017-02-19 13:07:49 +01:00
commit d85b9cdd71
10 changed files with 169 additions and 157 deletions

View file

@ -160,6 +160,7 @@ DMenu::DMenu(DMenu *parent)
mParentMenu = parent;
mMouseCapture = false;
mBackbuttonSelected = false;
DontDim = false;
GC::WriteBarrier(this, parent);
}
@ -445,11 +446,6 @@ DEFINE_ACTION_FUNCTION(DMenu, Close)
return 0;
}
bool DMenu::DimAllowed()
{
return true;
}
bool DMenu::TranslateKeyboardEvents()
{
IFVIRTUAL(DMenu, TranslateKeyboardEvents)
@ -928,7 +924,7 @@ void M_Drawer (void)
if (CurrentMenu != nullptr && menuactive != MENU_Off)
{
if (CurrentMenu->DimAllowed())
if (!CurrentMenu->DontDim)
{
screen->Dim(fade);
V_SetBorderNeedRefresh();
@ -1203,6 +1199,7 @@ CCMD(undocolorpic)
DEFINE_FIELD(DMenu, mParentMenu)
DEFINE_FIELD(DMenu, mMouseCapture);
DEFINE_FIELD(DMenu, mBackbuttonSelected);
DEFINE_FIELD(DMenu, DontDim);
DEFINE_FIELD(DMenuDescriptor, mMenuName)
DEFINE_FIELD(DMenuDescriptor, mNetgameMessage)