public void AddOption(String Prompt, Action <DialogueContext> Action) { Panel.AddChild(new Gum.Widget { Text = Prompt, OnClick = (sender, args) => Transition(Action), AutoLayout = Gum.AutoLayout.DockTop }); Panel.Layout(); }
private void MakeMenuItem(Gum.Widget Menu, string Name, string Tooltip, Action <Gum.Widget, Gum.InputEventArgs> OnClick) { Menu.AddChild(new Gum.Widget { AutoLayout = Gum.AutoLayout.DockTop, Border = "border-thin", Text = Name, OnClick = OnClick, Tooltip = Tooltip, TextHorizontalAlign = Gum.HorizontalAlign.Center, TextVerticalAlign = Gum.VerticalAlign.Center }); }