diff --git a/ShareX.HelpersLib/Extensions/Extensions.cs b/ShareX.HelpersLib/Extensions/Extensions.cs index d3453a858..a642cdd3e 100644 --- a/ShareX.HelpersLib/Extensions/Extensions.cs +++ b/ShareX.HelpersLib/Extensions/Extensions.cs @@ -626,5 +626,11 @@ public static Task ContinueInCurrentContext(this Task task, Action action) TaskScheduler scheduler = TaskScheduler.FromCurrentSynchronizationContext(); return task.ContinueWith(t => action(), scheduler); } + + public static void DoubleBuffered(this DataGridView dgv, bool value) + { + PropertyInfo pi = dgv.GetType().GetProperty("DoubleBuffered", BindingFlags.Instance | BindingFlags.NonPublic); + pi.SetValue(dgv, value, null); + } } } \ No newline at end of file diff --git a/ShareX/Controls/NewsListControl.Designer.cs b/ShareX/Controls/NewsListControl.Designer.cs index 6b3f353ae..f5a5c607a 100644 --- a/ShareX/Controls/NewsListControl.Designer.cs +++ b/ShareX/Controls/NewsListControl.Designer.cs @@ -28,39 +28,94 @@ protected override void Dispose(bool disposing) /// private void InitializeComponent() { - this.tlpMain = new System.Windows.Forms.TableLayoutPanel(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle9 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle7 = new System.Windows.Forms.DataGridViewCellStyle(); + System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle8 = new System.Windows.Forms.DataGridViewCellStyle(); + this.dgvNews = new System.Windows.Forms.DataGridView(); + this.chIsUnread = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.chDateTime = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.chText = new System.Windows.Forms.DataGridViewTextBoxColumn(); + ((System.ComponentModel.ISupportInitialize)(this.dgvNews)).BeginInit(); this.SuspendLayout(); // - // tlpMain + // dgvNews // - this.tlpMain.AutoScroll = true; - this.tlpMain.BackColor = System.Drawing.SystemColors.Window; - this.tlpMain.ColumnCount = 2; - this.tlpMain.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle()); - this.tlpMain.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F)); - this.tlpMain.Dock = System.Windows.Forms.DockStyle.Fill; - this.tlpMain.Location = new System.Drawing.Point(0, 0); - this.tlpMain.Margin = new System.Windows.Forms.Padding(0); - this.tlpMain.Name = "tlpMain"; - this.tlpMain.RowCount = 1; - this.tlpMain.RowStyles.Add(new System.Windows.Forms.RowStyle()); - this.tlpMain.Size = new System.Drawing.Size(502, 502); - this.tlpMain.TabIndex = 0; + this.dgvNews.AllowUserToAddRows = false; + this.dgvNews.AllowUserToDeleteRows = false; + this.dgvNews.AllowUserToResizeColumns = false; + this.dgvNews.AllowUserToResizeRows = false; + this.dgvNews.AutoSizeRowsMode = System.Windows.Forms.DataGridViewAutoSizeRowsMode.AllCells; + this.dgvNews.BackgroundColor = System.Drawing.SystemColors.Window; + this.dgvNews.BorderStyle = System.Windows.Forms.BorderStyle.None; + this.dgvNews.CellBorderStyle = System.Windows.Forms.DataGridViewCellBorderStyle.SingleHorizontal; + this.dgvNews.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; + this.dgvNews.ColumnHeadersVisible = false; + this.dgvNews.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { + this.chIsUnread, + this.chDateTime, + this.chText}); + dataGridViewCellStyle9.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; + dataGridViewCellStyle9.BackColor = System.Drawing.SystemColors.Window; + dataGridViewCellStyle9.Font = new System.Drawing.Font("Arial", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); + dataGridViewCellStyle9.ForeColor = System.Drawing.SystemColors.ControlText; + dataGridViewCellStyle9.Padding = new System.Windows.Forms.Padding(5); + dataGridViewCellStyle9.SelectionBackColor = System.Drawing.SystemColors.Window; + dataGridViewCellStyle9.SelectionForeColor = System.Drawing.SystemColors.ControlText; + dataGridViewCellStyle9.WrapMode = System.Windows.Forms.DataGridViewTriState.False; + this.dgvNews.DefaultCellStyle = dataGridViewCellStyle9; + this.dgvNews.Dock = System.Windows.Forms.DockStyle.Fill; + this.dgvNews.Location = new System.Drawing.Point(0, 0); + this.dgvNews.Name = "dgvNews"; + this.dgvNews.RowHeadersVisible = false; + this.dgvNews.Size = new System.Drawing.Size(399, 363); + this.dgvNews.TabIndex = 0; + this.dgvNews.CellMouseClick += new System.Windows.Forms.DataGridViewCellMouseEventHandler(this.dgvNews_CellMouseClick); + this.dgvNews.CellMouseEnter += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvNews_CellMouseEnter); + this.dgvNews.CellMouseLeave += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvNews_CellMouseLeave); + // + // chIsUnread + // + this.chIsUnread.HeaderText = "IsUnread"; + this.chIsUnread.Name = "chIsUnread"; + this.chIsUnread.ReadOnly = true; + this.chIsUnread.Width = 5; + // + // chDateTime + // + dataGridViewCellStyle7.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; + this.chDateTime.DefaultCellStyle = dataGridViewCellStyle7; + this.chDateTime.HeaderText = "DateTime"; + this.chDateTime.Name = "chDateTime"; + this.chDateTime.ReadOnly = true; + // + // chText + // + this.chText.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill; + dataGridViewCellStyle8.Padding = new System.Windows.Forms.Padding(5); + dataGridViewCellStyle8.WrapMode = System.Windows.Forms.DataGridViewTriState.True; + this.chText.DefaultCellStyle = dataGridViewCellStyle8; + this.chText.HeaderText = "Text"; + this.chText.Name = "chText"; + this.chText.ReadOnly = true; // // NewsListControl // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.Controls.Add(this.tlpMain); - this.Margin = new System.Windows.Forms.Padding(0); + this.BackColor = System.Drawing.SystemColors.Window; + this.Controls.Add(this.dgvNews); this.Name = "NewsListControl"; - this.Size = new System.Drawing.Size(502, 502); + this.Size = new System.Drawing.Size(399, 363); + ((System.ComponentModel.ISupportInitialize)(this.dgvNews)).EndInit(); this.ResumeLayout(false); } #endregion - private System.Windows.Forms.TableLayoutPanel tlpMain; + private System.Windows.Forms.DataGridView dgvNews; + private System.Windows.Forms.DataGridViewTextBoxColumn chIsUnread; + private System.Windows.Forms.DataGridViewTextBoxColumn chDateTime; + private System.Windows.Forms.DataGridViewTextBoxColumn chText; } } diff --git a/ShareX/Controls/NewsListControl.cs b/ShareX/Controls/NewsListControl.cs index 29edea5b2..4e6037228 100644 --- a/ShareX/Controls/NewsListControl.cs +++ b/ShareX/Controls/NewsListControl.cs @@ -34,24 +34,17 @@ namespace ShareX { public partial class NewsListControl : UserControl { - public NewsManager NewsManager { get; private set; } - public event EventHandler NewsLoaded; - private ToolTip tooltip; + public NewsManager NewsManager { get; private set; } public NewsListControl() { InitializeComponent(); - - tooltip = new ToolTip() - { - AutoPopDelay = 10000, - InitialDelay = 500 - }; - - tlpMain.CellPaint += TlpMain_CellPaint; - tlpMain.Layout += TlpMain_Layout; + dgvNews.AlternatingRowsDefaultCellStyle.BackColor = dgvNews.AlternatingRowsDefaultCellStyle.SelectionBackColor = + ColorHelpers.DarkerColor(SystemColors.Window, 0.02f); + dgvNews.GridColor = ProfessionalColors.SeparatorDark; + dgvNews.DoubleBuffered(true); } public void Start() @@ -66,7 +59,7 @@ public void Start() { if (NewsManager != null && NewsManager.NewsItems != null) { - tlpMain.SuspendLayout(); + SuspendLayout(); foreach (NewsItem item in NewsManager.NewsItems) { @@ -76,7 +69,9 @@ public void Start() } } - tlpMain.ResumeLayout(); + UpdateUnreadStatus(); + + ResumeLayout(); OnNewsLoaded(); } @@ -104,67 +99,17 @@ public void MarkRead() NewsManager.UpdateUnread(); } } - } - private async void TlpMain_Layout(object sender, LayoutEventArgs e) - { - await Task.Delay(1); - - if (tlpMain.HorizontalScroll.Visible) - { - tlpMain.Padding = new Padding(0, 0, SystemInformation.VerticalScrollBarWidth, 0); - } - else - { - tlpMain.Padding = new Padding(0); - } - } - - private void TlpMain_CellPaint(object sender, TableLayoutCellPaintEventArgs e) - { - Color color; - - if (e.Row.IsEvenNumber()) - { - color = SystemColors.Window; - } - else - { - color = ColorHelpers.DarkerColor(SystemColors.Window, 0.02f); - } - - using (Brush brush = new SolidBrush(color)) - { - e.Graphics.FillRectangle(brush, e.CellBounds); - } - - if (NewsManager != null && NewsManager.NewsItems != null && NewsManager.NewsItems.IsValidIndex(e.Row) && NewsManager.NewsItems[e.Row].IsUnread && e.Column == 0) - { - e.Graphics.FillRectangle(Brushes.LimeGreen, new Rectangle(e.CellBounds.X, e.CellBounds.Y, 5, e.CellBounds.Height)); - } - - using (Pen pen = new Pen(ProfessionalColors.SeparatorDark)) - { - e.Graphics.DrawLine(pen, new Point(e.CellBounds.X, e.CellBounds.Bottom - 1), new Point(e.CellBounds.Right - 1, e.CellBounds.Bottom - 1)); - } + UpdateUnreadStatus(); } public void AddNewsItem(NewsItem item) { - RowStyle style = new RowStyle(SizeType.AutoSize); - tlpMain.RowStyles.Add(style); - int index = tlpMain.RowCount++ - 1; + int index = dgvNews.Rows.Add(); + DataGridViewRow row = dgvNews.Rows[index]; + row.Tag = item; - Label lblDateTime = new Label() - { - Anchor = AnchorStyles.Left | AnchorStyles.Right, - AutoSize = true, - BackColor = Color.Transparent, - Font = new Font("Arial", 10), - Margin = new Padding(0), - Padding = new Padding(10, 8, 5, 8), - Text = item.DateTime.ToShortDateString() - }; + row.Cells[1].Value = item.DateTime.ToShortDateString(); string dateTimeTooltip; double days = (DateTime.Now - item.DateTime).TotalDays; @@ -182,37 +127,78 @@ public void AddNewsItem(NewsItem item) dateTimeTooltip = (int)days + " days ago."; } - tooltip.SetToolTip(lblDateTime, dateTimeTooltip); + row.Cells[1].ToolTipText = dateTimeTooltip; - tlpMain.Controls.Add(lblDateTime, 0, index); - - Label lblText = new Label() - { - Anchor = AnchorStyles.Left | AnchorStyles.Right, - AutoSize = true, - BackColor = Color.Transparent, - Font = new Font("Arial", 10), - Margin = new Padding(0), - Padding = new Padding(5, 8, 5, 8), - Text = item.Text - }; + row.Cells[2].Value = item.Text; if (URLHelpers.IsValidURL(item.URL)) { - tooltip.SetToolTip(lblText, item.URL); - lblText.Cursor = Cursors.Hand; - lblText.MouseEnter += (sender, e) => lblText.ForeColor = SystemColors.HotTrack; - lblText.MouseLeave += (sender, e) => lblText.ForeColor = SystemColors.ControlText; - lblText.MouseClick += (sender, e) => - { - if (e.Button == MouseButtons.Left) - { - URLHelpers.OpenURL(item.URL); - } - }; + row.Cells[2].ToolTipText = item.URL; } + } - tlpMain.Controls.Add(lblText, 1, index); + private void UpdateUnreadStatus() + { + foreach (DataGridViewRow row in dgvNews.Rows) + { + NewsItem newsItem = row.Tag as NewsItem; + if (newsItem != null && newsItem.IsUnread) + { + row.Cells[0].Style.BackColor = row.Cells[0].Style.SelectionBackColor = Color.LimeGreen; + } + else + { + row.Cells[0].Style.ApplyStyle(dgvNews.AlternatingRowsDefaultCellStyle); + } + } + } + + private void dgvNews_CellMouseEnter(object sender, DataGridViewCellEventArgs e) + { + if (e.ColumnIndex == 2) + { + DataGridViewRow row = dgvNews.Rows[e.RowIndex]; + NewsItem newsItem = row.Tag as NewsItem; + if (newsItem != null && !string.IsNullOrEmpty(newsItem.URL)) + { + dgvNews.Cursor = Cursors.Hand; + row.Cells[e.ColumnIndex].Style.ForeColor = row.Cells[e.ColumnIndex].Style.SelectionForeColor = SystemColors.HotTrack; + } + } + else + { + dgvNews.Cursor = Cursors.Default; + } + } + + private void dgvNews_CellMouseLeave(object sender, DataGridViewCellEventArgs e) + { + if (e.ColumnIndex == 2) + { + DataGridViewRow row = dgvNews.Rows[e.RowIndex]; + NewsItem newsItem = row.Tag as NewsItem; + if (newsItem != null && !string.IsNullOrEmpty(newsItem.URL)) + { + row.Cells[e.ColumnIndex].Style.ForeColor = row.Cells[e.ColumnIndex].Style.SelectionForeColor = SystemColors.ControlText; + } + } + else + { + dgvNews.Cursor = Cursors.Default; + } + } + + private void dgvNews_CellMouseClick(object sender, DataGridViewCellMouseEventArgs e) + { + if (e.Button == MouseButtons.Left && e.ColumnIndex == 2) + { + DataGridViewRow row = dgvNews.Rows[e.RowIndex]; + NewsItem newsItem = row.Tag as NewsItem; + if (newsItem != null && URLHelpers.IsValidURL(newsItem.URL)) + { + URLHelpers.OpenURL(newsItem.URL); + } + } } } } \ No newline at end of file diff --git a/ShareX/Controls/NewsListControl.resx b/ShareX/Controls/NewsListControl.resx new file mode 100644 index 000000000..8c7533967 --- /dev/null +++ b/ShareX/Controls/NewsListControl.resx @@ -0,0 +1,129 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + True + + + True + + + True + + \ No newline at end of file diff --git a/ShareX/Forms/MainForm.Designer.cs b/ShareX/Forms/MainForm.Designer.cs index 840bc2118..44f38be75 100644 --- a/ShareX/Forms/MainForm.Designer.cs +++ b/ShareX/Forms/MainForm.Designer.cs @@ -258,11 +258,11 @@ private void InitializeComponent() this.ttMain = new System.Windows.Forms.ToolTip(this.components); this.pbDiscordOpen = new System.Windows.Forms.PictureBox(); this.pbDiscordHide = new System.Windows.Forms.PictureBox(); - this.ucNews = new ShareX.NewsListControl(); this.pNews = new System.Windows.Forms.Panel(); this.btnCloseNews = new System.Windows.Forms.Button(); this.flpCommunity = new System.Windows.Forms.FlowLayoutPanel(); this.flpDiscord = new System.Windows.Forms.FlowLayoutPanel(); + this.ucNews = new ShareX.NewsListControl(); ((System.ComponentModel.ISupportInitialize)(this.scMain)).BeginInit(); this.scMain.Panel1.SuspendLayout(); this.scMain.Panel2.SuspendLayout(); @@ -2039,11 +2039,6 @@ private void InitializeComponent() this.ttMain.SetToolTip(this.pbDiscordHide, resources.GetString("pbDiscordHide.ToolTip")); this.pbDiscordHide.Click += new System.EventHandler(this.pbDiscordHide_Click); // - // ucNews - // - resources.ApplyResources(this.ucNews, "ucNews"); - this.ucNews.Name = "ucNews"; - // // pNews // this.pNews.Controls.Add(this.btnCloseNews); @@ -2073,6 +2068,11 @@ private void InitializeComponent() this.flpDiscord.Controls.Add(this.pbDiscordHide); this.flpDiscord.Name = "flpDiscord"; // + // ucNews + // + resources.ApplyResources(this.ucNews, "ucNews"); + this.ucNews.Name = "ucNews"; + // // MainForm // this.AllowDrop = true; @@ -2327,7 +2327,6 @@ private void InitializeComponent() private System.Windows.Forms.ToolStripMenuItem tsmiOpenActionsToolbar; private System.Windows.Forms.ToolStripMenuItem tsmiDeleteSelectedItem; private System.Windows.Forms.ToolStripMenuItem tsmiSearchImage; - private NewsListControl ucNews; private System.Windows.Forms.Panel pNews; private System.Windows.Forms.Button btnCloseNews; private System.Windows.Forms.ToolStripMenuItem tsmiImageThumbnailer; @@ -2353,5 +2352,6 @@ private void InitializeComponent() private System.Windows.Forms.ToolStripMenuItem tsmiShowCursor; private System.Windows.Forms.ToolStripSeparator tssTrayCapture1; private System.Windows.Forms.ToolStripMenuItem tsmiTrayShowCursor; + private NewsListControl ucNews; } } \ No newline at end of file diff --git a/ShareX/Forms/MainForm.resx b/ShareX/Forms/MainForm.resx index a0f10bb8c..ebe1218fe 100644 --- a/ShareX/Forms/MainForm.resx +++ b/ShareX/Forms/MainForm.resx @@ -159,6 +159,102 @@ 0 + + Fill + + + 0, 0 + + + 335, 429 + + + 2 + + + lvUploads + + + ShareX.HelpersLib.MyListView, ShareX.HelpersLib, Version=12.3.1.0, Culture=neutral, PublicKeyToken=null + + + scMain.Panel1 + + + 1 + + + scMain.Panel1 + + + System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + scMain + + + 0 + + + Fill + + + 0, 0 + + + 333, 429 + + + 0 + + + pbPreview + + + ShareX.HelpersLib.MyPictureBox, ShareX.HelpersLib, Version=12.3.1.0, Culture=neutral, PublicKeyToken=null + + + scMain.Panel2 + + + 0 + + + scMain.Panel2 + + + System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + scMain + + + 1 + + + 674, 429 + + + 335 + + + 6 + + + 1 + + + scMain + + + ShareX.HelpersLib.SplitContainerCustomSplitter, ShareX.HelpersLib, Version=12.3.1.0, Culture=neutral, PublicKeyToken=null + + + $this + + + 4 + Filename @@ -198,126 +294,9 @@ 145 - - Fill - - - 0, 0 - - - 335, 429 - - - 2 - - - lvUploads - - - ShareX.HelpersLib.MyListView, ShareX.HelpersLib, Version=12.3.0.0, Culture=neutral, PublicKeyToken=null - - - scMain.Panel1 - - - 1 - - - scMain.Panel1 - - - System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - scMain - - - 0 - - - Fill - - - 0, 0 - - - 333, 429 - - - 0 - - - pbPreview - - - ShareX.HelpersLib.MyPictureBox, ShareX.HelpersLib, Version=12.3.0.0, Culture=neutral, PublicKeyToken=null - - - scMain.Panel2 - - - 0 - - - scMain.Panel2 - - - System.Windows.Forms.SplitterPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - scMain - - - 1 - - - 674, 429 - - - 335 - - - 6 - - - 1 - - - scMain - - - ShareX.HelpersLib.SplitContainerCustomSplitter, ShareX.HelpersLib, Version=12.3.0.0, Culture=neutral, PublicKeyToken=null - - - $this - - - 4 - True - - 0, 0 - - - 0, 0, 0, 0 - - - 168, 45 - - - AutoSize - - - 0 - - - 567, 17 - - - Open ShareX Patreon campaign web page - pbPatreonOpen @@ -330,24 +309,6 @@ 0 - - 168, 0 - - - 0, 0, 0, 0 - - - 47, 45 - - - AutoSize - - - 1 - - - Hide Patreon button permanently - pbPatreonHide @@ -387,6 +348,75 @@ 0 + + 567, 17 + + + NoControl + + + 0, 0 + + + 0, 0, 0, 0 + + + 168, 45 + + + AutoSize + + + 0 + + + Open ShareX Patreon campaign web page + + + pbPatreonOpen + + + System.Windows.Forms.PictureBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + flpPatreon + + + 0 + + + NoControl + + + 168, 0 + + + 0, 0, 0, 0 + + + 47, 45 + + + AutoSize + + + 1 + + + Hide Patreon button permanently + + + pbPatreonHide + + + System.Windows.Forms.PictureBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + flpPatreon + + + 1 + 17, 17 @@ -396,6 +426,42 @@ Left + + 0, 0 + + + 6, 6, 6, 6 + + + 160, 429 + + + 1 + + + tsMain + + + ShareX.HelpersLib.ToolStripBorderRight, ShareX.HelpersLib, Version=12.3.1.0, Culture=neutral, PublicKeyToken=null + + + $this + + + 5 + + + MiddleLeft + + + Magenta + + + 147, 20 + + + Capture + 191, 22 @@ -483,17 +549,17 @@ Show cursor - + MiddleLeft - + Magenta - + 147, 20 - - Capture + + Upload 203, 22 @@ -537,18 +603,6 @@ Shorten URL... - - MiddleLeft - - - Magenta - - - 147, 20 - - - Upload - BottomLeft @@ -561,6 +615,18 @@ Workflows + + MiddleLeft + + + Magenta + + + 147, 20 + + + Tools + 184, 22 @@ -651,18 +717,6 @@ Monitor test... - - MiddleLeft - - - Magenta - - - 147, 20 - - - Tools - 147, 6 @@ -690,6 +744,18 @@ After upload tasks + + MiddleLeft + + + Magenta + + + 147, 20 + + + Destinations + 187, 22 @@ -729,18 +795,6 @@ Destination settings... - - MiddleLeft - - - Magenta - - - 147, 20 - - - Destinations - MiddleLeft @@ -828,6 +882,18 @@ News + + MiddleLeft + + + Magenta + + + 147, 20 + + + Debug + 172, 22 @@ -864,18 +930,6 @@ Test URL sharing - - MiddleLeft - - - Magenta - - - 147, 20 - - - Debug - MiddleLeft @@ -900,33 +954,18 @@ About... - - 0, 0 - - - 6, 6, 6, 6 - - - 160, 429 - - - 1 - - - tsMain - - - ShareX.HelpersLib.ToolStripBorderRight, ShareX.HelpersLib, Version=12.3.0.0, Culture=neutral, PublicKeyToken=null - - - $this - - - 5 - 286, 17 + + 229, 450 + + + cmsTaskInfo + + + System.Windows.Forms.ContextMenuStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + 228, 22 @@ -939,6 +978,12 @@ Stop upload + + 228, 22 + + + Open + Enter @@ -993,11 +1038,11 @@ Thumbnail file - + 228, 22 - - Open + + Copy Ctrl+C @@ -1164,12 +1209,6 @@ False - - 228, 22 - - - Copy - Ctrl+U @@ -1278,6 +1317,12 @@ Hide columns + + 228, 22 + + + Image preview + 130, 22 @@ -1311,27 +1356,30 @@ Bottom - - 228, 22 - - - Image preview - - - 229, 450 - - - cmsTaskInfo - - - System.Windows.Forms.ContextMenuStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - 105, 17 190, 17 + + 193, 484 + + + cmsTray + + + System.Windows.Forms.ContextMenuStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + ShareX + + + 192, 22 + + + Capture + 191, 22 @@ -1419,11 +1467,11 @@ Show cursor - + 192, 22 - - Capture + + Upload 203, 22 @@ -1467,18 +1515,18 @@ Shorten URL... - - 192, 22 - - - Upload - 192, 22 Workflows + + 192, 22 + + + Tools + 184, 22 @@ -1569,12 +1617,6 @@ Monitor test... - - 192, 22 - - - Tools - 189, 6 @@ -1590,6 +1632,12 @@ After upload tasks + + 192, 22 + + + Destinations + 187, 22 @@ -1629,12 +1677,6 @@ Destination settings... - - 192, 22 - - - Destinations - 192, 22 @@ -1680,6 +1722,12 @@ Image history... + + 192, 22 + + + Debug + 172, 22 @@ -1716,12 +1764,6 @@ Test URL sharing - - 192, 22 - - - Debug - 192, 22 @@ -1764,21 +1806,12 @@ Exit - - 193, 484 - - - cmsTray - - - System.Windows.Forms.ContextMenuStrip, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - ShareX - 405, 17 + + 567, 17 + NoControl @@ -1845,36 +1878,12 @@ 1 - - Fill - - - 0, 0 - - - 0, 0, 0, 0 - - - 674, 429 - - - 4 - - - ucNews - - - ShareX.NewsListControl, ShareX, Version=12.3.0.0, Culture=neutral, PublicKeyToken=null - - - pNews - - - 1 - Bottom, Right + + NoControl + 560, 400 @@ -1899,6 +1908,30 @@ 0 + + Fill + + + 0, 0 + + + 674, 429 + + + 6 + + + ucNews + + + ShareX.Controls.NewsListControl, ShareX, Version=12.3.1.0, Culture=neutral, PublicKeyToken=null + + + pNews + + + 1 + Fill @@ -1935,24 +1968,6 @@ GrowAndShrink - - True - - - 3, 3 - - - 215, 45 - - - 4 - - - False - - - False - flpDiscord @@ -1989,6 +2004,36 @@ 3 + + True + + + 3, 3 + + + 215, 45 + + + 4 + + + False + + + False + + + flpDiscord + + + System.Windows.Forms.FlowLayoutPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + flpCommunity + + + 1 + True @@ -2407,7 +2452,7 @@ tsbNews - ShareX.HelpersLib.ToolStripButtonCounter, ShareX.HelpersLib, Version=12.3.0.0, Culture=neutral, PublicKeyToken=null + ShareX.HelpersLib.ToolStripButtonCounter, ShareX.HelpersLib, Version=12.3.1.0, Culture=neutral, PublicKeyToken=null tsddbDebug @@ -2455,7 +2500,7 @@ tsbDonate - ShareX.HelpersLib.ToolStripButtonColorAnimation, ShareX.HelpersLib, Version=12.3.0.0, Culture=neutral, PublicKeyToken=null + ShareX.HelpersLib.ToolStripButtonColorAnimation, ShareX.HelpersLib, Version=12.3.1.0, Culture=neutral, PublicKeyToken=null tsbAbout @@ -3307,6 +3352,6 @@ MainForm - ShareX.HelpersLib.HotkeyForm, ShareX.HelpersLib, Version=12.3.0.0, Culture=neutral, PublicKeyToken=null + ShareX.HelpersLib.HotkeyForm, ShareX.HelpersLib, Version=12.3.1.0, Culture=neutral, PublicKeyToken=null \ No newline at end of file diff --git a/ShareX/ShareX.csproj b/ShareX/ShareX.csproj index 777c91c09..e5dc08ce6 100644 --- a/ShareX/ShareX.csproj +++ b/ShareX/ShareX.csproj @@ -388,6 +388,9 @@ HotkeySelectionControl.cs + + NewsListControl.cs + AboutForm.cs