Added optional prompt argument to MENUDEF's SafeCommand
This commit is contained in:
parent
3d9591229e
commit
58a6d7df1f
2 changed files with 28 additions and 3 deletions
|
|
@ -781,7 +781,15 @@ static void ParseOptionMenuBody(FScanner &sc, FOptionMenuDescriptor *desc)
|
|||
FString label = sc.String;
|
||||
sc.MustGetStringName(",");
|
||||
sc.MustGetString();
|
||||
FOptionMenuItem *it = new FOptionMenuItemSafeCommand(label, sc.String);
|
||||
FString command = sc.String;
|
||||
FString prompt;
|
||||
// Check for optional custom prompt
|
||||
if (sc.CheckString(","))
|
||||
{
|
||||
sc.MustGetString();
|
||||
prompt = sc.String;
|
||||
}
|
||||
FOptionMenuItem *it = new FOptionMenuItemSafeCommand(label, command, prompt);
|
||||
desc->mItems.Push(it);
|
||||
}
|
||||
else if (sc.Compare("Control") || sc.Compare("MapControl"))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue