From dad908c68c1cdb8b868be9ee61899cea711bc95b Mon Sep 17 00:00:00 2001 From: UnknownShadow200 Date: Wed, 10 Nov 2021 18:51:21 +1100 Subject: [PATCH] GUI: Use FixedDialog instead for FixedToolWindow for improved appearance of popup dialogs, especially on Linux Note that this means that popup dialogs now appear in taskbar on Linux, whereas they weren't before. However popup dialogs were already appearing before in taskbar on Windows, so at least the behaviour is consistent now --- GUI/Popups/ColorSelector.Designer.cs | 6 +++--- GUI/Popups/CustomCommands.Designer.cs | 4 +++- GUI/Popups/EditText.Designer.cs | 4 +++- GUI/Popups/PortTools.Designer.cs | 4 +++- GUI/Popups/TokenSelector.Designer.cs | 6 +++--- 5 files changed, 15 insertions(+), 9 deletions(-) diff --git a/GUI/Popups/ColorSelector.Designer.cs b/GUI/Popups/ColorSelector.Designer.cs index 6c15db304..ebb07a258 100644 --- a/GUI/Popups/ColorSelector.Designer.cs +++ b/GUI/Popups/ColorSelector.Designer.cs @@ -28,10 +28,10 @@ this.ClientSize = new System.Drawing.Size(200, 200); this.Controls.Add(this.btnCancel); this.Font = new System.Drawing.Font("Calibri", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWindow; + this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog; + this.MaximizeBox = false; + this.MinimizeBox = false; this.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3); - this.MaximizeBox = false; - this.MinimizeBox = false; this.Name = "ColorPicker"; this.ShowIcon = false; this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; diff --git a/GUI/Popups/CustomCommands.Designer.cs b/GUI/Popups/CustomCommands.Designer.cs index 36cd8f694..2404ad4da 100644 --- a/GUI/Popups/CustomCommands.Designer.cs +++ b/GUI/Popups/CustomCommands.Designer.cs @@ -149,7 +149,9 @@ this.Controls.Add(this.btnLoad); this.Controls.Add(this.btnUnload); this.Font = new System.Drawing.Font("Calibri", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWindow; + this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog; + this.MaximizeBox = false; + this.MinimizeBox = false; this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; this.Name = "CustomCommands"; this.Text = "Custom commands"; diff --git a/GUI/Popups/EditText.Designer.cs b/GUI/Popups/EditText.Designer.cs index 5c72106bf..fa2c64372 100644 --- a/GUI/Popups/EditText.Designer.cs +++ b/GUI/Popups/EditText.Designer.cs @@ -96,7 +96,9 @@ namespace MCGalaxy.Gui.Popups this.Controls.Add(this.txtEdit); this.Controls.Add(this.cmbList); this.Font = new System.Drawing.Font("Calibri", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWindow; + this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog; + this.MaximizeBox = false; + this.MinimizeBox = false; this.Name = "EditText"; this.ShowIcon = false; this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; diff --git a/GUI/Popups/PortTools.Designer.cs b/GUI/Popups/PortTools.Designer.cs index 571c5a3fa..1b6ce4b3b 100644 --- a/GUI/Popups/PortTools.Designer.cs +++ b/GUI/Popups/PortTools.Designer.cs @@ -120,7 +120,9 @@ namespace MCGalaxy.Gui.Popups { this.Controls.Add(this.gbUpnp); this.Controls.Add(this.linkManually); this.Controls.Add(this.linkHelpForward); - this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWindow; + this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog; + this.MaximizeBox = false; + this.MinimizeBox = false; this.Name = "PortTools"; this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; this.Text = "Port forward tools"; diff --git a/GUI/Popups/TokenSelector.Designer.cs b/GUI/Popups/TokenSelector.Designer.cs index aeeab2b5a..1183b1e2a 100644 --- a/GUI/Popups/TokenSelector.Designer.cs +++ b/GUI/Popups/TokenSelector.Designer.cs @@ -30,10 +30,10 @@ this.ClientSize = new System.Drawing.Size(200, 200); this.Controls.Add(this.btnCancel); this.Font = new System.Drawing.Font("Calibri", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedToolWindow; + this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog; + this.MaximizeBox = false; + this.MinimizeBox = false; this.Margin = new System.Windows.Forms.Padding(4, 3, 4, 3); - this.MaximizeBox = false; - this.MinimizeBox = false; this.Name = "TokenSelector"; this.ShowIcon = false; this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;