diff --git a/Form1.Designer.cs b/Form1.Designer.cs index afb4bf7..df5f792 100644 --- a/Form1.Designer.cs +++ b/Form1.Designer.cs @@ -88,6 +88,7 @@ private void InitializeComponent() this.tbComicSearch.Name = "tbComicSearch"; this.tbComicSearch.Size = new System.Drawing.Size(287, 22); this.tbComicSearch.TabIndex = 0; + this.tbComicSearch.KeyDown += new System.Windows.Forms.KeyEventHandler(this.tbComicSearch_KeyDown); // // btnSearch // @@ -273,13 +274,13 @@ private void InitializeComponent() this.cmsComics.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.search}); this.cmsComics.Name = "cmsComics"; - this.cmsComics.Size = new System.Drawing.Size(211, 56); + this.cmsComics.Size = new System.Drawing.Size(200, 28); this.cmsComics.ItemClicked += new System.Windows.Forms.ToolStripItemClickedEventHandler(this.cmsComics_ItemClicked); // // search // this.search.Name = "search"; - this.search.Size = new System.Drawing.Size(210, 24); + this.search.Size = new System.Drawing.Size(199, 24); this.search.Text = "Find more like this"; // // Form1 diff --git a/Form1.cs b/Form1.cs index ec8c518..7ae965d 100644 --- a/Form1.cs +++ b/Form1.cs @@ -21,7 +21,7 @@ namespace Omnibus public partial class Form1 : Form { - private String version = "1.4.4"; + private String version = "1.4.5"; private String url = "https://getcomics.info/?s="; private int cancelled = 0; private int complete; @@ -504,7 +504,17 @@ private void DownloadCancelled() DownloadComic(idCount); } } - + + private void tbComicSearch_KeyDown(object sender, KeyEventArgs e) + { + if (e.KeyCode == Keys.Enter) + { + btnSearch_Click(this, new EventArgs()); + e.Handled = true; + e.SuppressKeyPress = true; + } + } + private void DownloadComplete() { @@ -666,5 +676,6 @@ private void LogWriter(string line) string datetime = DateTime.Now.ToString("MM-dd-yy HH:mm:ss"); File.AppendAllText(@"log.txt", "(" + datetime + ") - " + line + Environment.NewLine); } + } } \ No newline at end of file