diff --git a/Build/Configurations/Includes/Heretic_things.cfg b/Build/Configurations/Includes/Heretic_things.cfg index 29fc4db9eab39211877782cae97ff4946fe5d0d9..0b4037bac6e709ecfed7d7bc0fa92eab41509415 100644 --- a/Build/Configurations/Includes/Heretic_things.cfg +++ b/Build/Configurations/Includes/Heretic_things.cfg @@ -8,31 +8,31 @@ players height = 56; blocking = 2; error = 2; - sort = 0; + sort = 1; 1 { - title = "Player 1 Start"; + title = "Player 1 start"; sprite = "PLAYA1"; } 2 { - title = "Player 2 Start"; + title = "Player 2 start"; sprite = "PLAYA1"; } 3 { - title = "Player 3 Start"; + title = "Player 3 start"; sprite = "PLAYA1"; } 4 { - title = "Player 4 Start"; + title = "Player 4 start"; sprite = "PLAYA1"; } 11 { - title = "Player Deathmatch Start"; + title = "Player Deathmatch start"; sprite = "PLAYQ0"; } } @@ -80,7 +80,7 @@ sounds height = 16; blocking = 0; error = 0; - sort = 0; + sort = 1; 41 = "Looping Sound: Waterfall"; 42 = "Looping Sound: Wind"; diff --git a/Build/Configurations/Includes/ZDoom_things.cfg b/Build/Configurations/Includes/ZDoom_things.cfg index 10118a66d9105c376f2a70e8faccaa1584f22f2f..258380b92176a30945e5ce61d896bfeca55e3507 100644 --- a/Build/Configurations/Includes/ZDoom_things.cfg +++ b/Build/Configurations/Includes/ZDoom_things.cfg @@ -1486,7 +1486,7 @@ doom 5010 { title = "Pistol"; - sprite = "PISGA0"; + sprite = "PISTA0"; class = "Pistol"; } } @@ -1647,6 +1647,16 @@ heretic class = "$Player8Start"; } } + + weapons + { + 9042 + { + title = "Gold Wand"; + sprite = "GWANA0"; + class = "GoldWand"; + } + } bridges { diff --git a/Source/Core/Controls/ThingBrowserControl.Designer.cs b/Source/Core/Controls/ThingBrowserControl.Designer.cs index 843156ec26927d74cbe29caa02ec0ff0647174c6..2842fc6d0fd462f7065d4df2436ef977f8f2368b 100644 --- a/Source/Core/Controls/ThingBrowserControl.Designer.cs +++ b/Source/Core/Controls/ThingBrowserControl.Designer.cs @@ -292,6 +292,7 @@ namespace CodeImp.DoomBuilder.Controls this.typelist.TabIndex = 22; this.typelist.MouseDoubleClick += new System.Windows.Forms.MouseEventHandler(this.typelist_MouseDoubleClick); this.typelist.MouseEnter += new System.EventHandler(this.typelist_MouseEnter); + this.typelist.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.typelist_KeyPress); this.typelist.SelectionsChanged += new System.EventHandler(this.typelist_SelectionsChanged); // // ThingBrowserControl diff --git a/Source/Core/Controls/ThingBrowserControl.cs b/Source/Core/Controls/ThingBrowserControl.cs index ad2de1016d8c13041eedb065c8df7fd520482704..ea43f9d8ee118f05345b554a26afa1f21ce068c8 100644 --- a/Source/Core/Controls/ThingBrowserControl.cs +++ b/Source/Core/Controls/ThingBrowserControl.cs @@ -19,6 +19,7 @@ using System; using System.Collections.Generic; using System.Drawing; +using System.Globalization; using System.Windows.Forms; using CodeImp.DoomBuilder.Config; using CodeImp.DoomBuilder.Data; @@ -411,6 +412,25 @@ namespace CodeImp.DoomBuilder.Controls typelist.Focus(); } + //mxd. Transfer focus to Filter textbox + private void typelist_KeyPress(object sender, KeyPressEventArgs e) + { + tbFilter.Focus(); + if(e.KeyChar == '\b') // Any better way to check for Backspace?.. + { + if(!string.IsNullOrEmpty(tbFilter.Text) && tbFilter.SelectionStart > 0 && tbFilter.SelectionLength == 0) + { + int s = tbFilter.SelectionStart - 1; + tbFilter.Text = tbFilter.Text.Remove(s, 1); + tbFilter.SelectionStart = s; + } + } + else + { + tbFilter.AppendText(e.KeyChar.ToString(CultureInfo.InvariantCulture)); + } + } + //mxd private void bClear_Click(object sender, EventArgs e) { diff --git a/Source/Core/Windows/ActionBrowserForm.Designer.cs b/Source/Core/Windows/ActionBrowserForm.Designer.cs index 70e30b2db0e6da999b223d75ed2db10f7b17028d..18c21957380e6f9da33d565336369f2e142fe00b 100644 --- a/Source/Core/Windows/ActionBrowserForm.Designer.cs +++ b/Source/Core/Windows/ActionBrowserForm.Designer.cs @@ -391,6 +391,8 @@ namespace CodeImp.DoomBuilder.Windows this.actions.Size = new System.Drawing.Size(379, 335); this.actions.TabIndex = 0; this.actions.DoubleClick += new System.EventHandler(this.actions_DoubleClick); + this.actions.MouseEnter += new System.EventHandler(this.actions_MouseEnter); + this.actions.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.actions_KeyPress); // // tabs // @@ -414,10 +416,10 @@ namespace CodeImp.DoomBuilder.Windows this.tabactions.Controls.Add(this.actions); this.tabactions.Controls.Add(this.prefixespanel); this.tabactions.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.tabactions.Location = new System.Drawing.Point(4, 23); + this.tabactions.Location = new System.Drawing.Point(4, 22); this.tabactions.Name = "tabactions"; this.tabactions.Padding = new System.Windows.Forms.Padding(3); - this.tabactions.Size = new System.Drawing.Size(391, 409); + this.tabactions.Size = new System.Drawing.Size(391, 410); this.tabactions.TabIndex = 0; this.tabactions.Text = "Predefined Actions"; this.tabactions.UseVisualStyleBackColor = true; @@ -478,10 +480,10 @@ namespace CodeImp.DoomBuilder.Windows this.tabgeneralized.Controls.Add(groupBox2); this.tabgeneralized.Controls.Add(groupBox1); this.tabgeneralized.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.tabgeneralized.Location = new System.Drawing.Point(4, 23); + this.tabgeneralized.Location = new System.Drawing.Point(4, 22); this.tabgeneralized.Name = "tabgeneralized"; this.tabgeneralized.Padding = new System.Windows.Forms.Padding(3); - this.tabgeneralized.Size = new System.Drawing.Size(391, 409); + this.tabgeneralized.Size = new System.Drawing.Size(391, 410); this.tabgeneralized.TabIndex = 1; this.tabgeneralized.Text = "Generalized Actions"; this.tabgeneralized.UseVisualStyleBackColor = true; diff --git a/Source/Core/Windows/ActionBrowserForm.cs b/Source/Core/Windows/ActionBrowserForm.cs index 7fbaa88e52fe182b82b965c71366f1be90645e39..164e8f9098463b95373e806264a587659866b0b8 100644 --- a/Source/Core/Windows/ActionBrowserForm.cs +++ b/Source/Core/Windows/ActionBrowserForm.cs @@ -18,6 +18,7 @@ using System; using System.Collections.Generic; +using System.Globalization; using System.Windows.Forms; using CodeImp.DoomBuilder.Config; @@ -330,5 +331,30 @@ namespace CodeImp.DoomBuilder.Windows { if(tabs.SelectedTab == tabactions) tbFilter.Focus(); } + + //mxd + private void actions_MouseEnter(object sender, EventArgs e) + { + actions.Focus(); + } + + //mxd. Transfer focus to Filter textbox + private void actions_KeyPress(object sender, KeyPressEventArgs e) + { + tbFilter.Focus(); + if(e.KeyChar == '\b') // Any better way to check for Backspace?.. + { + if(!string.IsNullOrEmpty(tbFilter.Text) && tbFilter.SelectionStart > 0 && tbFilter.SelectionLength == 0) + { + int s = tbFilter.SelectionStart - 1; + tbFilter.Text = tbFilter.Text.Remove(s, 1); + tbFilter.SelectionStart = s; + } + } + else + { + tbFilter.AppendText(e.KeyChar.ToString(CultureInfo.InvariantCulture)); + } + } } } diff --git a/Source/Core/Windows/DelayedForm.cs b/Source/Core/Windows/DelayedForm.cs index 3392bb1d8c53a627c7ca1af3428e1e9ed7f925d8..f429601094879d122a433503df21686f083d4e70 100644 --- a/Source/Core/Windows/DelayedForm.cs +++ b/Source/Core/Windows/DelayedForm.cs @@ -76,7 +76,7 @@ namespace CodeImp.DoomBuilder.Windows if(!this.IsDisposed) { // Make the form visible - this.Opacity = 100; + this.Opacity = 1.0; } } diff --git a/Source/Core/Windows/EffectBrowserForm.Designer.cs b/Source/Core/Windows/EffectBrowserForm.Designer.cs index 0062ea0987f17ba01045c09af2c510cd10633a1f..8c5820ca54d06014ec5c31e7e032d68a60dac7e7 100644 --- a/Source/Core/Windows/EffectBrowserForm.Designer.cs +++ b/Source/Core/Windows/EffectBrowserForm.Designer.cs @@ -359,6 +359,8 @@ namespace CodeImp.DoomBuilder.Windows this.effects.UseCompatibleStateImageBehavior = false; this.effects.View = System.Windows.Forms.View.Details; this.effects.DoubleClick += new System.EventHandler(this.effects_DoubleClick); + this.effects.MouseEnter += new System.EventHandler(this.effects_MouseEnter); + this.effects.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.effects_KeyPress); // // colnumber // diff --git a/Source/Core/Windows/EffectBrowserForm.cs b/Source/Core/Windows/EffectBrowserForm.cs index 6451582af50f356df9c2050e6f8d745c6781b709..e3ad3edcdedfafe2842418a2db2110f2232fd922 100644 --- a/Source/Core/Windows/EffectBrowserForm.cs +++ b/Source/Core/Windows/EffectBrowserForm.cs @@ -18,6 +18,7 @@ using System; using System.Collections.Generic; +using System.Globalization; using System.Windows.Forms; using CodeImp.DoomBuilder.Config; @@ -245,5 +246,30 @@ namespace CodeImp.DoomBuilder.Windows if(tabs.SelectedTab == tabeffects) tbFilter.Focus(); } + //mxd + private void effects_MouseEnter(object sender, EventArgs e) + { + effects.Focus(); + } + + //mxd. Transfer focus to Filter textbox + private void effects_KeyPress(object sender, KeyPressEventArgs e) + { + tbFilter.Focus(); + if(e.KeyChar == '\b') // Any better way to check for Backspace?.. + { + if(!string.IsNullOrEmpty(tbFilter.Text) && tbFilter.SelectionStart > 0 && tbFilter.SelectionLength == 0) + { + int s = tbFilter.SelectionStart - 1; + tbFilter.Text = tbFilter.Text.Remove(s, 1); + tbFilter.SelectionStart = s; + } + } + else + { + tbFilter.AppendText(e.KeyChar.ToString(CultureInfo.InvariantCulture)); + } + } + } } \ No newline at end of file diff --git a/Source/Core/Windows/ThingBrowserForm.Designer.cs b/Source/Core/Windows/ThingBrowserForm.Designer.cs index dc26388ec7ad52b5087ee379d98e81c2e30bf77e..a2082c20816e7ca5845f051a05f7339a2eed0c35 100644 --- a/Source/Core/Windows/ThingBrowserForm.Designer.cs +++ b/Source/Core/Windows/ThingBrowserForm.Designer.cs @@ -87,6 +87,7 @@ namespace CodeImp.DoomBuilder.Windows this.ShowInTaskbar = false; this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; this.Text = "Choose Thing Type"; + this.Shown += new System.EventHandler(this.ThingBrowserForm_Shown); this.ResumeLayout(false); } diff --git a/Source/Core/Windows/ThingBrowserForm.cs b/Source/Core/Windows/ThingBrowserForm.cs index d9a05a12eb7f63807631379868543de6a64f74c6..23ef52fa6874869c109bcf0ebee10a897d399871 100644 --- a/Source/Core/Windows/ThingBrowserForm.cs +++ b/Source/Core/Windows/ThingBrowserForm.cs @@ -26,7 +26,7 @@ namespace CodeImp.DoomBuilder.Windows public partial class ThingBrowserForm : DelayedForm { // Variables - public int selectedtype; + private int selectedtype; // Properties public int SelectedType { get { return selectedtype; } } @@ -78,5 +78,11 @@ namespace CodeImp.DoomBuilder.Windows // OK apply_Click(this, EventArgs.Empty); } + + //mxd + private void ThingBrowserForm_Shown(object sender, EventArgs e) + { + thingslist.FocusTextbox(); + } } } \ No newline at end of file