From 67ec8dcf999361820cef461204ce352cf0018112 Mon Sep 17 00:00:00 2001 From: n00mkrad Date: Wed, 4 Aug 2021 18:10:29 +0200 Subject: [PATCH] Fixed GetBool(string key) always using false as default --- Code/Forms/BatchForm.Designer.cs | 4 ++-- Code/IO/Config.cs | 4 +--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/Code/Forms/BatchForm.Designer.cs b/Code/Forms/BatchForm.Designer.cs index c03b955..fa4a599 100644 --- a/Code/Forms/BatchForm.Designer.cs +++ b/Code/Forms/BatchForm.Designer.cs @@ -190,7 +190,7 @@ this.moveDownBtn.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.moveDownBtn.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.moveDownBtn.ForeColor = System.Drawing.Color.White; - this.moveDownBtn.Location = new System.Drawing.Point(637, 446); + this.moveDownBtn.Location = new System.Drawing.Point(636, 445); this.moveDownBtn.Margin = new System.Windows.Forms.Padding(0); this.moveDownBtn.Name = "moveDownBtn"; this.moveDownBtn.Size = new System.Drawing.Size(35, 35); @@ -207,7 +207,7 @@ this.moveUpBtn.FlatStyle = System.Windows.Forms.FlatStyle.Flat; this.moveUpBtn.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.moveUpBtn.ForeColor = System.Drawing.Color.White; - this.moveUpBtn.Location = new System.Drawing.Point(598, 446); + this.moveUpBtn.Location = new System.Drawing.Point(597, 445); this.moveUpBtn.Margin = new System.Windows.Forms.Padding(0); this.moveUpBtn.Name = "moveUpBtn"; this.moveUpBtn.Size = new System.Drawing.Size(35, 35); diff --git a/Code/IO/Config.cs b/Code/IO/Config.cs index eb5dddb..4fdb64c 100644 --- a/Code/IO/Config.cs +++ b/Code/IO/Config.cs @@ -146,9 +146,7 @@ namespace Flowframes.IO public static bool GetBool(string key) { - WriteIfDoesntExist(key.ToString(), false.ToString()); - string str = Get(key, Type.Bool); - return str.GetBool(); + return Get(key, Type.Bool).GetBool(); } public static bool GetBool(string key, bool defaultVal)