Changed to latest RyzStudio8
Changed build script
This commit is contained in:
parent
d5e8d939e3
commit
d917c422f5
27
AppResource.Designer.cs
generated
27
AppResource.Designer.cs
generated
@ -60,6 +60,24 @@ namespace ClipboardWatcher {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to .
|
||||
/// </summary>
|
||||
internal static string AppAuthorURL {
|
||||
get {
|
||||
return ResourceManager.GetString("AppAuthorURL", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to https://www.hiimray.co.uk.
|
||||
/// </summary>
|
||||
internal static string AppCompanyURL {
|
||||
get {
|
||||
return ResourceManager.GetString("AppCompanyURL", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to https://www.hiimray.co.uk.
|
||||
/// </summary>
|
||||
@ -68,5 +86,14 @@ namespace ClipboardWatcher {
|
||||
return ResourceManager.GetString("AppHelpURL", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to https://www.hiimray.co.uk.
|
||||
/// </summary>
|
||||
internal static string AppProductURL {
|
||||
get {
|
||||
return ResourceManager.GetString("AppProductURL", resourceCulture);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -117,7 +117,16 @@
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<data name="AppAuthorURL" xml:space="preserve">
|
||||
<value />
|
||||
</data>
|
||||
<data name="AppCompanyURL" xml:space="preserve">
|
||||
<value>https://www.hiimray.co.uk</value>
|
||||
</data>
|
||||
<data name="AppHelpURL" xml:space="preserve">
|
||||
<value>https://www.hiimray.co.uk</value>
|
||||
</data>
|
||||
<data name="AppProductURL" xml:space="preserve">
|
||||
<value>https://www.hiimray.co.uk</value>
|
||||
</data>
|
||||
</root>
|
@ -11,7 +11,7 @@
|
||||
<Copyright>Ray Lam</Copyright>
|
||||
<ApplicationIcon>favicon.ico</ApplicationIcon>
|
||||
<NoWin32Manifest>true</NoWin32Manifest>
|
||||
<Version>0.1.1.003</Version>
|
||||
<Version>0.1.2.134</Version>
|
||||
<Title>Clipboard Watcher</Title>
|
||||
</PropertyGroup>
|
||||
|
||||
@ -44,11 +44,6 @@
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>AppResource.resx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Update="UIResource.Designer.cs">
|
||||
<DesignTime>True</DesignTime>
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>UIResource.resx</DependentUpon>
|
||||
</Compile>
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
@ -56,20 +51,11 @@
|
||||
<Generator>ResXFileCodeGenerator</Generator>
|
||||
<LastGenOutput>AppResource.Designer.cs</LastGenOutput>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Update="UIResource.resx">
|
||||
<Generator>PublicResXFileCodeGenerator</Generator>
|
||||
<LastGenOutput>UIResource.Designer.cs</LastGenOutput>
|
||||
</EmbeddedResource>
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Folder Include="Resources\" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Reference Include="Ryz3ui">
|
||||
<HintPath>References\Ryz3ui.dll</HintPath>
|
||||
</Reference>
|
||||
<PackageReference Include="RyzStudio" Version="8.1.2.324" />
|
||||
<PackageReference Include="RyzStudio.Windows.Forms" Version="8.1.3.632" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
110
MainForm.Designer.cs
generated
110
MainForm.Designer.cs
generated
@ -43,12 +43,11 @@ namespace ClipboardWatcher
|
||||
viewHelpToolStripMenuItem1 = new System.Windows.Forms.ToolStripMenuItem();
|
||||
toolStripMenuItem16 = new System.Windows.Forms.ToolStripSeparator();
|
||||
aboutToolStripMenuItem1 = new System.Windows.Forms.ToolStripMenuItem();
|
||||
button1 = new RyzStudio.Windows.ThemedForms.TButton();
|
||||
tHorizontalSeparator2 = new RyzStudio.Windows.Forms.THorizontalSeparator();
|
||||
tHorizontalSeparator1 = new RyzStudio.Windows.Forms.THorizontalSeparator();
|
||||
button4 = new RyzStudio.Windows.ThemedForms.TButton();
|
||||
memoBox1 = new RyzStudio.Windows.ThemedForms.TMemoBox();
|
||||
button2 = new RyzStudio.Windows.ThemedForms.TButton();
|
||||
button4 = new RyzStudio.Windows.ThemedForms.ThButton();
|
||||
memoBox1 = new RyzStudio.Windows.ThemedForms.ThToolbarMemoBox();
|
||||
button2 = new RyzStudio.Windows.ThemedForms.ThButton();
|
||||
dialogFooter1 = new RyzStudio.Windows.ThemedForms.Composite.DialogFooter();
|
||||
menuStrip1.SuspendLayout();
|
||||
SuspendLayout();
|
||||
//
|
||||
@ -71,19 +70,19 @@ namespace ClipboardWatcher
|
||||
//
|
||||
newToolStripMenuItem.Name = "newToolStripMenuItem";
|
||||
newToolStripMenuItem.ShortcutKeys = System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.N;
|
||||
newToolStripMenuItem.Size = new System.Drawing.Size(141, 22);
|
||||
newToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
newToolStripMenuItem.Text = "&New";
|
||||
newToolStripMenuItem.Click += newToolStripMenuItem_Click;
|
||||
//
|
||||
// toolStripMenuItem13
|
||||
//
|
||||
toolStripMenuItem13.Name = "toolStripMenuItem13";
|
||||
toolStripMenuItem13.Size = new System.Drawing.Size(138, 6);
|
||||
toolStripMenuItem13.Size = new System.Drawing.Size(177, 6);
|
||||
//
|
||||
// exitToolStripMenuItem2
|
||||
//
|
||||
exitToolStripMenuItem2.Name = "exitToolStripMenuItem2";
|
||||
exitToolStripMenuItem2.Size = new System.Drawing.Size(141, 22);
|
||||
exitToolStripMenuItem2.Size = new System.Drawing.Size(180, 22);
|
||||
exitToolStripMenuItem2.Text = "E&xit";
|
||||
exitToolStripMenuItem2.Click += exitToolStripMenuItem2_Click;
|
||||
//
|
||||
@ -99,7 +98,7 @@ namespace ClipboardWatcher
|
||||
optionsToolStripMenuItem.Enabled = false;
|
||||
optionsToolStripMenuItem.Name = "optionsToolStripMenuItem";
|
||||
optionsToolStripMenuItem.ShortcutKeys = System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.F12;
|
||||
optionsToolStripMenuItem.Size = new System.Drawing.Size(168, 22);
|
||||
optionsToolStripMenuItem.Size = new System.Drawing.Size(180, 22);
|
||||
optionsToolStripMenuItem.Text = "&Options";
|
||||
optionsToolStripMenuItem.Click += optionsToolStripMenuItem_Click;
|
||||
//
|
||||
@ -114,63 +113,29 @@ namespace ClipboardWatcher
|
||||
//
|
||||
viewHelpToolStripMenuItem1.Name = "viewHelpToolStripMenuItem1";
|
||||
viewHelpToolStripMenuItem1.ShortcutKeys = System.Windows.Forms.Keys.F1;
|
||||
viewHelpToolStripMenuItem1.Size = new System.Drawing.Size(146, 22);
|
||||
viewHelpToolStripMenuItem1.Size = new System.Drawing.Size(180, 22);
|
||||
viewHelpToolStripMenuItem1.Text = "&View Help";
|
||||
viewHelpToolStripMenuItem1.Click += viewHelpToolStripMenuItem1_Click;
|
||||
//
|
||||
// toolStripMenuItem16
|
||||
//
|
||||
toolStripMenuItem16.Name = "toolStripMenuItem16";
|
||||
toolStripMenuItem16.Size = new System.Drawing.Size(143, 6);
|
||||
toolStripMenuItem16.Size = new System.Drawing.Size(177, 6);
|
||||
//
|
||||
// aboutToolStripMenuItem1
|
||||
//
|
||||
aboutToolStripMenuItem1.Name = "aboutToolStripMenuItem1";
|
||||
aboutToolStripMenuItem1.Size = new System.Drawing.Size(146, 22);
|
||||
aboutToolStripMenuItem1.Size = new System.Drawing.Size(180, 22);
|
||||
aboutToolStripMenuItem1.Text = "&About";
|
||||
aboutToolStripMenuItem1.Click += aboutToolStripMenuItem1_Click;
|
||||
//
|
||||
// button1
|
||||
//
|
||||
button1.AcceptButton = null;
|
||||
button1.ActiveImage = null;
|
||||
button1.Anchor = System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right;
|
||||
button1.BackColor = System.Drawing.Color.Transparent;
|
||||
button1.EnableReactiveVisual = true;
|
||||
button1.HoverImage = null;
|
||||
button1.IdleImage = null;
|
||||
button1.LabelText = "&Close";
|
||||
button1.Location = new System.Drawing.Point(416, 705);
|
||||
button1.Margin = new System.Windows.Forms.Padding(10, 0, 10, 10);
|
||||
button1.Name = "button1";
|
||||
button1.Padding = new System.Windows.Forms.Padding(4, 4, 3, 3);
|
||||
button1.Size = new System.Drawing.Size(149, 37);
|
||||
button1.TabIndex = 6;
|
||||
button1.TabStop = false;
|
||||
button1.MouseClick += button1_MouseClick;
|
||||
//
|
||||
// tHorizontalSeparator2
|
||||
//
|
||||
tHorizontalSeparator2.Anchor = System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right;
|
||||
tHorizontalSeparator2.AutoScrollMargin = new System.Drawing.Size(0, 0);
|
||||
tHorizontalSeparator2.AutoScrollMinSize = new System.Drawing.Size(0, 0);
|
||||
tHorizontalSeparator2.BackColor = System.Drawing.Color.Transparent;
|
||||
tHorizontalSeparator2.Location = new System.Drawing.Point(8, 673);
|
||||
tHorizontalSeparator2.Margin = new System.Windows.Forms.Padding(0, 10, 0, 0);
|
||||
tHorizontalSeparator2.MaximumSize = new System.Drawing.Size(5760, 22);
|
||||
tHorizontalSeparator2.MinimumSize = new System.Drawing.Size(0, 22);
|
||||
tHorizontalSeparator2.Name = "tHorizontalSeparator2";
|
||||
tHorizontalSeparator2.Size = new System.Drawing.Size(568, 22);
|
||||
tHorizontalSeparator2.TabIndex = 42;
|
||||
tHorizontalSeparator2.TabStop = false;
|
||||
//
|
||||
// tHorizontalSeparator1
|
||||
//
|
||||
tHorizontalSeparator1.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right;
|
||||
tHorizontalSeparator1.AutoScrollMargin = new System.Drawing.Size(0, 0);
|
||||
tHorizontalSeparator1.AutoScrollMinSize = new System.Drawing.Size(0, 0);
|
||||
tHorizontalSeparator1.BackColor = System.Drawing.Color.Transparent;
|
||||
tHorizontalSeparator1.Location = new System.Drawing.Point(8, 79);
|
||||
tHorizontalSeparator1.Location = new System.Drawing.Point(8, 77);
|
||||
tHorizontalSeparator1.Margin = new System.Windows.Forms.Padding(0, 10, 0, 0);
|
||||
tHorizontalSeparator1.MaximumSize = new System.Drawing.Size(5760, 22);
|
||||
tHorizontalSeparator1.MinimumSize = new System.Drawing.Size(0, 22);
|
||||
@ -181,38 +146,34 @@ namespace ClipboardWatcher
|
||||
//
|
||||
// button4
|
||||
//
|
||||
button4.AcceptButton = null;
|
||||
button4.ActiveImage = null;
|
||||
button4.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right;
|
||||
button4.BackColor = System.Drawing.Color.Transparent;
|
||||
button4.EnableMenuOnClick = false;
|
||||
button4.EnableReactiveVisual = true;
|
||||
button4.HoverImage = null;
|
||||
button4.IdleImage = null;
|
||||
button4.LabelText = "&Clear";
|
||||
button4.Location = new System.Drawing.Point(416, 36);
|
||||
button4.Margin = new System.Windows.Forms.Padding(10, 0, 10, 10);
|
||||
button4.Location = new System.Drawing.Point(316, 36);
|
||||
button4.Name = "button4";
|
||||
button4.Padding = new System.Windows.Forms.Padding(4, 4, 3, 3);
|
||||
button4.Size = new System.Drawing.Size(149, 33);
|
||||
button4.Size = new System.Drawing.Size(260, 32);
|
||||
button4.TabIndex = 3;
|
||||
button4.TabStop = false;
|
||||
button4.MouseClick += button4_MouseClick;
|
||||
//
|
||||
// memoBox1
|
||||
//
|
||||
memoBox1.AcceptButton = null;
|
||||
memoBox1.AllowDrop = true;
|
||||
memoBox1.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right;
|
||||
memoBox1.BackColor = System.Drawing.Color.Transparent;
|
||||
memoBox1.ClearedValue = "";
|
||||
memoBox1.EnableReactiveVisual = true;
|
||||
memoBox1.Font = new System.Drawing.Font("Segoe UI", 9F);
|
||||
memoBox1.Location = new System.Drawing.Point(13, 117);
|
||||
memoBox1.Margin = new System.Windows.Forms.Padding(10, 6, 10, 6);
|
||||
memoBox1.Location = new System.Drawing.Point(10, 109);
|
||||
memoBox1.Name = "memoBox1";
|
||||
memoBox1.Padding = new System.Windows.Forms.Padding(4, 4, 3, 3);
|
||||
memoBox1.ReadOnly = false;
|
||||
memoBox1.ScrollBars = System.Windows.Forms.ScrollBars.Vertical;
|
||||
memoBox1.Size = new System.Drawing.Size(558, 550);
|
||||
memoBox1.Size = new System.Drawing.Size(566, 548);
|
||||
memoBox1.TabIndex = 4;
|
||||
memoBox1.TabStop = false;
|
||||
memoBox1.WordWrap = false;
|
||||
@ -221,36 +182,44 @@ namespace ClipboardWatcher
|
||||
//
|
||||
// button2
|
||||
//
|
||||
button2.AcceptButton = null;
|
||||
button2.ActiveImage = null;
|
||||
button2.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Right;
|
||||
button2.Anchor = System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right;
|
||||
button2.BackColor = System.Drawing.Color.Transparent;
|
||||
button2.EnableMenuOnClick = false;
|
||||
button2.EnableReactiveVisual = true;
|
||||
button2.HoverImage = null;
|
||||
button2.IdleImage = null;
|
||||
button2.LabelText = "&Start Monitoring";
|
||||
button2.Location = new System.Drawing.Point(247, 36);
|
||||
button2.Margin = new System.Windows.Forms.Padding(10, 0, 10, 10);
|
||||
button2.Location = new System.Drawing.Point(10, 36);
|
||||
button2.Name = "button2";
|
||||
button2.Padding = new System.Windows.Forms.Padding(4, 4, 3, 3);
|
||||
button2.Size = new System.Drawing.Size(149, 33);
|
||||
button2.Size = new System.Drawing.Size(296, 32);
|
||||
button2.TabIndex = 46;
|
||||
button2.TabStop = false;
|
||||
button2.MouseClick += button3_MouseClick;
|
||||
//
|
||||
// dialogFooter1
|
||||
//
|
||||
dialogFooter1.BackColor = System.Drawing.Color.FromArgb(240, 240, 240);
|
||||
dialogFooter1.Button1Text = "&Close";
|
||||
dialogFooter1.Dialog = this;
|
||||
dialogFooter1.Dock = System.Windows.Forms.DockStyle.Bottom;
|
||||
dialogFooter1.IsBusy = false;
|
||||
dialogFooter1.Location = new System.Drawing.Point(0, 677);
|
||||
dialogFooter1.Name = "dialogFooter1";
|
||||
dialogFooter1.Size = new System.Drawing.Size(584, 84);
|
||||
//
|
||||
// MainForm
|
||||
//
|
||||
AllowDrop = true;
|
||||
AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
|
||||
AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
BackColor = System.Drawing.Color.FromArgb(250, 250, 250);
|
||||
BackColor = System.Drawing.Color.White;
|
||||
ClientSize = new System.Drawing.Size(584, 761);
|
||||
Controls.Add(dialogFooter1);
|
||||
Controls.Add(button2);
|
||||
Controls.Add(memoBox1);
|
||||
Controls.Add(button4);
|
||||
Controls.Add(tHorizontalSeparator1);
|
||||
Controls.Add(tHorizontalSeparator2);
|
||||
Controls.Add(button1);
|
||||
Controls.Add(menuStrip1);
|
||||
Icon = (System.Drawing.Icon)resources.GetObject("$this.Icon");
|
||||
Name = "MainForm";
|
||||
@ -262,9 +231,8 @@ namespace ClipboardWatcher
|
||||
}
|
||||
|
||||
#endregion
|
||||
private RyzStudio.Windows.ThemedForms.TButton button1;
|
||||
private System.Windows.Forms.ToolTip toolTip1;
|
||||
private RyzStudio.Windows.ThemedForms.TButton button4;
|
||||
private RyzStudio.Windows.ThemedForms.ThButton button4;
|
||||
private System.Windows.Forms.MenuStrip menuStrip1;
|
||||
private System.Windows.Forms.ToolStripMenuItem fileToolStripMenuItem;
|
||||
private System.Windows.Forms.ToolStripMenuItem newToolStripMenuItem;
|
||||
@ -276,10 +244,10 @@ namespace ClipboardWatcher
|
||||
private System.Windows.Forms.ToolStripMenuItem viewHelpToolStripMenuItem1;
|
||||
private System.Windows.Forms.ToolStripSeparator toolStripMenuItem16;
|
||||
private System.Windows.Forms.ToolStripMenuItem aboutToolStripMenuItem1;
|
||||
private RyzStudio.Windows.ThemedForms.TMemoBox memoBox1;
|
||||
private RyzStudio.Windows.ThemedForms.ThToolbarMemoBox memoBox1;
|
||||
private RyzStudio.Windows.Forms.THorizontalSeparator tHorizontalSeparator1;
|
||||
private RyzStudio.Windows.Forms.THorizontalSeparator tHorizontalSeparator2;
|
||||
private RyzStudio.Windows.ThemedForms.TButton button2;
|
||||
private RyzStudio.Windows.ThemedForms.ThButton button2;
|
||||
private RyzStudio.Windows.ThemedForms.Composite.DialogFooter dialogFooter1;
|
||||
}
|
||||
}
|
||||
|
||||
|
101
MainForm.cs
101
MainForm.cs
@ -1,22 +1,15 @@
|
||||
using System;
|
||||
using System.Diagnostics;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.ComponentModel;
|
||||
using System.Windows.Forms;
|
||||
using RyzStudio.Windows.Forms;
|
||||
using RyzStudio.Windows.ThemedForms;
|
||||
|
||||
namespace ClipboardWatcher
|
||||
{
|
||||
public partial class MainForm : Form
|
||||
{
|
||||
[DllImport("User32.dll", CharSet = CharSet.Auto)]
|
||||
protected static extern IntPtr SetClipboardViewer(IntPtr hWndNewViewer);
|
||||
|
||||
protected const int WM_DRAWCLIPBOARD = 0x308;
|
||||
|
||||
protected IntPtr _clipboardViewer;
|
||||
protected bool isMonitoring = false;
|
||||
protected int lineCount = 0;
|
||||
private IntPtr _clipboardViewer;
|
||||
private bool _isMonitoring = false;
|
||||
private int _lineCount = 0;
|
||||
|
||||
|
||||
public MainForm()
|
||||
@ -26,9 +19,23 @@ namespace ClipboardWatcher
|
||||
memoBox1.TextBox.WordWrap = false;
|
||||
}
|
||||
|
||||
protected override void OnShown(EventArgs e)
|
||||
{
|
||||
base.OnShown(e);
|
||||
|
||||
button2.Focus();
|
||||
}
|
||||
|
||||
protected override void OnClosing(CancelEventArgs e)
|
||||
{
|
||||
base.OnClosing(e);
|
||||
|
||||
this.IsMonitoring = false;
|
||||
}
|
||||
|
||||
protected override void WndProc(ref Message m)
|
||||
{
|
||||
if ((m.Msg == WM_DRAWCLIPBOARD) && this.IsMonitoring)
|
||||
if ((m.Msg == RyzStudio.Runtime.InteropServices.User32.WM_DRAWCLIPBOARD) && this.IsMonitoring)
|
||||
{
|
||||
AddClipboardText();
|
||||
}
|
||||
@ -39,18 +46,20 @@ namespace ClipboardWatcher
|
||||
|
||||
public bool IsMonitoring
|
||||
{
|
||||
get => isMonitoring;
|
||||
get => _isMonitoring;
|
||||
set
|
||||
{
|
||||
isMonitoring = value;
|
||||
_isMonitoring = value;
|
||||
|
||||
_clipboardViewer = (isMonitoring ? SetClipboardViewer(this.Handle) : default);
|
||||
_clipboardViewer = (_isMonitoring ? RyzStudio.Runtime.InteropServices.User32.SetClipboardViewer(this.Handle) : default);
|
||||
|
||||
button2.LabelText = (isMonitoring ? "Sto&p" : "&Start") + " Monitoring";
|
||||
button2.LabelText = (_isMonitoring ? "Sto&p" : "&Start") + " Monitoring";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#region Main Menu
|
||||
|
||||
/// <summary>
|
||||
/// New
|
||||
/// </summary>
|
||||
@ -70,13 +79,7 @@ namespace ClipboardWatcher
|
||||
/// <param name="e"></param>
|
||||
private void exitToolStripMenuItem2_Click(object sender, EventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
this.Close();
|
||||
}
|
||||
catch
|
||||
{
|
||||
}
|
||||
this.Close();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@ -86,8 +89,7 @@ namespace ClipboardWatcher
|
||||
/// <param name="e"></param>
|
||||
private void optionsToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (this.IsMonitoring) return;
|
||||
|
||||
// do nothing
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@ -97,18 +99,7 @@ namespace ClipboardWatcher
|
||||
/// <param name="e"></param>
|
||||
private void viewHelpToolStripMenuItem1_Click(object sender, EventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
System.Diagnostics.Process.Start(new ProcessStartInfo()
|
||||
{
|
||||
FileName = AppResource.AppHelpURL,
|
||||
UseShellExecute = true
|
||||
});
|
||||
}
|
||||
catch
|
||||
{
|
||||
// do nothing
|
||||
}
|
||||
RyzStudio.Diagnostics.Process.Execute(AppResource.AppHelpURL);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@ -118,9 +109,18 @@ namespace ClipboardWatcher
|
||||
/// <param name="e"></param>
|
||||
private void aboutToolStripMenuItem1_Click(object sender, EventArgs e)
|
||||
{
|
||||
MessageBox.Show(Application.ProductName + " v" + Application.ProductVersion, "About", MessageBoxButtons.OK, MessageBoxIcon.Information);
|
||||
var form = new RyzStudio.Windows.ThemedForms.AboutForm();
|
||||
form.ProductURL = AppResource.AppProductURL;
|
||||
form.AuthorURL = AppResource.AppAuthorURL;
|
||||
form.CompanyURL = AppResource.AppCompanyURL;
|
||||
form.ProductCopyrightStartYear = 2024;
|
||||
//form.ProductLogo = AppResource.icon_64;
|
||||
|
||||
form.ShowDialog();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Start/stop monitoring
|
||||
@ -144,17 +144,7 @@ namespace ClipboardWatcher
|
||||
Clipboard.Clear();
|
||||
|
||||
memoBox1.Text = string.Empty;
|
||||
lineCount = 0;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Close
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
private void button1_MouseClick(object sender, MouseEventArgs e)
|
||||
{
|
||||
this.Close();
|
||||
_lineCount = 0;
|
||||
}
|
||||
|
||||
|
||||
@ -193,9 +183,9 @@ namespace ClipboardWatcher
|
||||
foreach (string item in fileList)
|
||||
{
|
||||
memoBox1.Text += item + Environment.NewLine;
|
||||
lineCount++;
|
||||
_lineCount++;
|
||||
|
||||
UIControl.SetText(this, $"Clipboard Monitor ({lineCount.ToString()})");
|
||||
UIControl.SetText(this, $"Clipboard Monitor ({_lineCount.ToString()})");
|
||||
}
|
||||
}
|
||||
|
||||
@ -214,14 +204,11 @@ namespace ClipboardWatcher
|
||||
}
|
||||
|
||||
memoBox1.Text += clipboardText.Trim() + Environment.NewLine;
|
||||
lineCount++;
|
||||
_lineCount++;
|
||||
|
||||
UIControl.SetText(this, $"Clipboard Monitor ({lineCount.ToString()})");
|
||||
UIControl.SetText(this, $"Clipboard Monitor ({_lineCount.ToString()})");
|
||||
|
||||
this.TopMost = true;
|
||||
this.BringToFront();
|
||||
this.Focus();
|
||||
this.TopMost = false;
|
||||
UIControl.BringToFront(this);
|
||||
}
|
||||
|
||||
}
|
||||
|
Binary file not shown.
63
UIResource.Designer.cs
generated
63
UIResource.Designer.cs
generated
@ -1,63 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:4.0.30319.42000
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace ClipboardWatcher {
|
||||
using System;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// A strongly-typed resource class, for looking up localized strings, etc.
|
||||
/// </summary>
|
||||
// This class was auto-generated by the StronglyTypedResourceBuilder
|
||||
// class via a tool like ResGen or Visual Studio.
|
||||
// To add or remove a member, edit your .ResX file then rerun ResGen
|
||||
// with the /str option, or rebuild your VS project.
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "17.0.0.0")]
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
public class UIResource {
|
||||
|
||||
private static global::System.Resources.ResourceManager resourceMan;
|
||||
|
||||
private static global::System.Globalization.CultureInfo resourceCulture;
|
||||
|
||||
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
|
||||
internal UIResource() {
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Returns the cached ResourceManager instance used by this class.
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
public static global::System.Resources.ResourceManager ResourceManager {
|
||||
get {
|
||||
if (object.ReferenceEquals(resourceMan, null)) {
|
||||
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("ClipboardWatcher.UIResource", typeof(UIResource).Assembly);
|
||||
resourceMan = temp;
|
||||
}
|
||||
return resourceMan;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Overrides the current thread's CurrentUICulture property for all
|
||||
/// resource lookups using this strongly typed resource class.
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
public static global::System.Globalization.CultureInfo Culture {
|
||||
get {
|
||||
return resourceCulture;
|
||||
}
|
||||
set {
|
||||
resourceCulture = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
120
UIResource.resx
120
UIResource.resx
@ -1,120 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
</root>
|
20
build.bat
20
build.bat
@ -1,5 +1,17 @@
|
||||
rmdir /s /q "bin\Release\64\"
|
||||
dotnet publish skye.sln -r win-x64 -c Release /p:PublishSingleFile=true /p:SelfContained=false /p:PublishReadyToRunfalse=true /p:PublishDir="bin\Release\64\"
|
||||
RMDIR /s /q "bin\"
|
||||
RMDIR /s /q "obj\"
|
||||
|
||||
##rmdir /s /q "bin\Release\86\"
|
||||
##dotnet publish skye.sln -r win-x86 -c Release /p:PublishSingleFile=true /p:SelfContained=false /p:PublishReadyToRunfalse=true /p:PublishDir="bin\Release\86\"
|
||||
MKDIR bin
|
||||
|
||||
dotnet restore skye.sln
|
||||
dotnet publish skye.sln -r win-x64 -c Release /p:PublishSingleFile=true /p:SelfContained=false /p:PublishReadyToRunfalse=true /p:PublishDir="bin\"
|
||||
|
||||
REM "C:\B\Portable Files (dev)\Inno Setup\v6.0.4-2\app\ISCC.exe" "build-installer.iss"
|
||||
|
||||
"C:\B\Portable Files\7-Zip (Portable)\23.01\App\7-Zip64\7z.exe" a -t7z "bin\clipboardwatcher.7z" ".\bin\clipboardwatcher.exe" -mx9
|
||||
|
||||
RMDIR /s /q "bin\debug"
|
||||
RMDIR /s /q "bin\release"
|
||||
RMDIR /s /q "obj\"
|
||||
|
||||
PAUSE
|
Loading…
Reference in New Issue
Block a user