protected override void DrawContent(Rect rect) { var l = new ListingPlus(); l.Begin(rect); _includeDocked = l.CheckboxLabeled(Lang.Get("Dialog_SavePreset.IncludeDocked"), _includeDocked, enabled: !_includeDocked || _includeFloating); _includeFloating = l.CheckboxLabeled(Lang.Get("Dialog_SavePreset.IncludeFloating"), _includeFloating, enabled: !_includeFloating || _includeDocked); l.GapLine(); _includeHeight = l.CheckboxLabeled(Lang.Get("Dialog_SavePreset.IncludeHeight"), _includeHeight); _includeWidth = l.CheckboxLabeled(Lang.Get("Dialog_SavePreset.IncludeWidth"), _includeWidth); _includeTabs = l.CheckboxLabeled(Lang.Get("Dialog_SavePreset.IncludeTabs"), _includeTabs, enabled: _includeDocked); l.GapLine(); l.Label(Lang.Get("Dialog_SavePreset.Name")); GUI.SetNextControlName(NameControl); _name = l.TextEntry(_name); GUI.FocusControl(NameControl); l.Gap(); var buttonGrid = l.GetButtonGrid(-1f, -1f); if (GUIPlus.DrawButton(buttonGrid[1], Lang.Get("Button.Save"), enabled: Persistent.IsValidFilename(_name))) { Save(); } if (GUIPlus.DrawButton(buttonGrid[2], Lang.Get("Button.Cancel"))) { Close(); } l.End(); }