protected override void DrawContent(Rect rect) { try { var grid = rect.GetVGrid(Padding, -1f, ButtonHeight); _tabs.Draw(grid[1]); var button = GUIPlus.DrawButtonRow(grid[2], ButtonWidth, Padding, Lang.Get("Dialog_Config.SetToDefault"), Lang.Get("Dialog_Config.OpenFolder"), Lang.Get("Button.Close")); GUIPlus.DrawText(grid[2], "Version " + Mod.Version, style: Theme.SmallTextStyle, alignment: TextAnchor.LowerRight); if (button == 1) { ConfirmSetToDefault(); } else if (button == 2) { Persistent.OpenConfigFolder(); } else if (button == 3) { Close(); } } catch (Exception exception) { Mod.HandleError(exception); Close(); } }
protected override void DrawContent(Rect rect) { var grid = rect.GetVGrid(Padding, -1f, ButtonHeight); _tabs.Draw(grid[1]); var button = GUIPlus.DrawButtonRow(grid[2], ButtonWidth, Padding, Lang.Get("Dialog_Config.SetToDefault"), Lang.Get("Dialog_Config.OpenFolder"), Lang.Get("Button.Close")); if (button == 1) { ConfirmSetToDefault(); } else if (button == 2) { Persistent.OpenConfigFolder(); } else if (button == 3) { Close(); } }
protected override void DrawContent(Rect rect) { try { var grid = rect.GetVGrid(Padding, -1f, ButtonHeight); _tabs.Draw(grid[1]); var button = GUIPlus.DrawButtonRow(grid[2], ButtonWidth, Padding, Lang.Get("Dialog_Config.SetToDefault"), Lang.Get("Dialog_Config.OpenFolder"), Lang.Get("Button.Close")); GUIPlus.DrawText(grid[2], "Version " + Mod.Version + (Prefs.DevMode && Mod.DevMode ? "[DEV MODE - Click to disable]" : null), style: Theme.SmallTextStyle, alignment: TextAnchor.LowerRight); if (Widgets.ButtonInvisible(grid[2]) && Prefs.DevMode) { Mod.DevMode = !Mod.DevMode; HudTimings.Restart(); } if (button == 1) { ConfirmSetToDefault(); } else if (button == 2) { Persistent.OpenConfigFolder(); } else if (button == 3) { Close(); } } catch (Exception exception) { Mod.HandleError(exception); Close(); } }