diff --git a/Crypto Notepad/Crypto Notepad.csproj b/Crypto Notepad/Crypto Notepad.csproj index f79d11a..5393eda 100644 --- a/Crypto Notepad/Crypto Notepad.csproj +++ b/Crypto Notepad/Crypto Notepad.csproj @@ -101,44 +101,44 @@ - + Form - + AboutFrom.cs - - + + Form - + ChangeKeyForm.cs - - + + Component - + Form - + MainForm.cs - + Form - + EnterKeyForm.cs - + Component - + Form - + PasswordGeneratorFrom.cs @@ -149,29 +149,29 @@ True Resources.resx - + Form - + SettingsForm.cs - + Component - - + + AboutFrom.cs - + ChangeKeyForm.cs - + MainForm.cs - + EnterKeyForm.cs - + PasswordGeneratorFrom.cs @@ -179,7 +179,7 @@ Designer Resources.Designer.cs - + SettingsForm.cs diff --git a/Crypto Notepad/AES.cs b/Crypto Notepad/External Libraries/AES.cs similarity index 100% rename from Crypto Notepad/AES.cs rename to Crypto Notepad/External Libraries/AES.cs diff --git a/Crypto Notepad/EncryptedString.cs b/Crypto Notepad/External Libraries/EncryptedString.cs similarity index 100% rename from Crypto Notepad/EncryptedString.cs rename to Crypto Notepad/External Libraries/EncryptedString.cs diff --git a/Crypto Notepad/ExRichTextBox.cs b/Crypto Notepad/External Libraries/ExRichTextBox.cs similarity index 100% rename from Crypto Notepad/ExRichTextBox.cs rename to Crypto Notepad/External Libraries/ExRichTextBox.cs diff --git a/Crypto Notepad/HideCaretRichTextBox.cs b/Crypto Notepad/External Libraries/HideCaretRichTextBox.cs similarity index 100% rename from Crypto Notepad/HideCaretRichTextBox.cs rename to Crypto Notepad/External Libraries/HideCaretRichTextBox.cs diff --git a/Crypto Notepad/Methods.cs b/Crypto Notepad/External Libraries/Methods.cs similarity index 100% rename from Crypto Notepad/Methods.cs rename to Crypto Notepad/External Libraries/Methods.cs diff --git a/Crypto Notepad/PlaceholderTextBox.cs b/Crypto Notepad/External Libraries/PlaceholderTextBox.cs similarity index 100% rename from Crypto Notepad/PlaceholderTextBox.cs rename to Crypto Notepad/External Libraries/PlaceholderTextBox.cs diff --git a/Crypto Notepad/AboutFrom.Designer.cs b/Crypto Notepad/Forms/AboutFrom.Designer.cs similarity index 89% rename from Crypto Notepad/AboutFrom.Designer.cs rename to Crypto Notepad/Forms/AboutFrom.Designer.cs index beb50f3..a08a7b9 100644 --- a/Crypto Notepad/AboutFrom.Designer.cs +++ b/Crypto Notepad/Forms/AboutFrom.Designer.cs @@ -50,12 +50,23 @@ private void InitializeComponent() this.aboutToolTip.SetToolTip(this.appVersionLabel, "Left click to copy debug info to the clipboard"); this.appVersionLabel.MouseClick += new System.Windows.Forms.MouseEventHandler(this.AppVersionLabel_MouseClick); this.appVersionLabel.MouseDoubleClick += new System.Windows.Forms.MouseEventHandler(this.AppVersionLabel_MouseDoubleClick); + this.appVersionLabel.MouseEnter += new System.EventHandler(this.appVersionLabel_MouseEnter); // // randomColorTimer // this.randomColorTimer.Interval = 200; this.randomColorTimer.Tick += new System.EventHandler(this.RandomColorTimer_Tick); // + // aboutToolTip + // + this.aboutToolTip.AutoPopDelay = 1000; + this.aboutToolTip.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(61)))), ((int)(((byte)(61)))), ((int)(((byte)(68))))); + this.aboutToolTip.ForeColor = System.Drawing.Color.DarkGray; + this.aboutToolTip.InitialDelay = 500; + this.aboutToolTip.OwnerDraw = true; + this.aboutToolTip.ReshowDelay = 100; + this.aboutToolTip.Draw += new System.Windows.Forms.DrawToolTipEventHandler(this.AboutToolTip_Draw); + // // appInfoRichTextBox // this.appInfoRichTextBox.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(45)))), ((int)(((byte)(45)))), ((int)(((byte)(50))))); diff --git a/Crypto Notepad/AboutFrom.cs b/Crypto Notepad/Forms/AboutFrom.cs similarity index 85% rename from Crypto Notepad/AboutFrom.cs rename to Crypto Notepad/Forms/AboutFrom.cs index 20d97ad..7c2371b 100644 --- a/Crypto Notepad/AboutFrom.cs +++ b/Crypto Notepad/Forms/AboutFrom.cs @@ -26,7 +26,7 @@ private void GetDebugInfo() sb.AppendLine(string.Format("OS version = {0}", OSVersionInfo.VersionString)); sb.AppendLine(".Net Framework = " + Methods.GetDotNetVersion()); Clipboard.SetText(sb.ToString()); - aboutToolTip.Show("Copied", appVersionLabel, 210, 1, 1000); + aboutToolTip.SetToolTip(appVersionLabel, "Copied"); } #endregion @@ -86,6 +86,18 @@ private void AppVersionLabel_MouseClick(object sender, MouseEventArgs e) } } } + + private void AboutToolTip_Draw(object sender, DrawToolTipEventArgs e) + { + e.DrawBackground(); + e.DrawBorder(); + e.DrawText(); + } + + private void appVersionLabel_MouseEnter(object sender, EventArgs e) + { + aboutToolTip.SetToolTip(appVersionLabel, "Left click to copy debug info to the clipboard"); + } #endregion diff --git a/Crypto Notepad/AboutFrom.resx b/Crypto Notepad/Forms/AboutFrom.resx similarity index 100% rename from Crypto Notepad/AboutFrom.resx rename to Crypto Notepad/Forms/AboutFrom.resx diff --git a/Crypto Notepad/ChangeKeyForm.Designer.cs b/Crypto Notepad/Forms/ChangeKeyForm.Designer.cs similarity index 100% rename from Crypto Notepad/ChangeKeyForm.Designer.cs rename to Crypto Notepad/Forms/ChangeKeyForm.Designer.cs diff --git a/Crypto Notepad/ChangeKeyForm.cs b/Crypto Notepad/Forms/ChangeKeyForm.cs similarity index 100% rename from Crypto Notepad/ChangeKeyForm.cs rename to Crypto Notepad/Forms/ChangeKeyForm.cs diff --git a/Crypto Notepad/ChangeKeyForm.resx b/Crypto Notepad/Forms/ChangeKeyForm.resx similarity index 100% rename from Crypto Notepad/ChangeKeyForm.resx rename to Crypto Notepad/Forms/ChangeKeyForm.resx diff --git a/Crypto Notepad/EnterKeyForm.Designer.cs b/Crypto Notepad/Forms/EnterKeyForm.Designer.cs similarity index 100% rename from Crypto Notepad/EnterKeyForm.Designer.cs rename to Crypto Notepad/Forms/EnterKeyForm.Designer.cs diff --git a/Crypto Notepad/EnterKeyForm.cs b/Crypto Notepad/Forms/EnterKeyForm.cs similarity index 100% rename from Crypto Notepad/EnterKeyForm.cs rename to Crypto Notepad/Forms/EnterKeyForm.cs diff --git a/Crypto Notepad/EnterKeyForm.resx b/Crypto Notepad/Forms/EnterKeyForm.resx similarity index 100% rename from Crypto Notepad/EnterKeyForm.resx rename to Crypto Notepad/Forms/EnterKeyForm.resx diff --git a/Crypto Notepad/MainForm.Designer.cs b/Crypto Notepad/Forms/MainForm.Designer.cs similarity index 100% rename from Crypto Notepad/MainForm.Designer.cs rename to Crypto Notepad/Forms/MainForm.Designer.cs diff --git a/Crypto Notepad/MainForm.cs b/Crypto Notepad/Forms/MainForm.cs similarity index 100% rename from Crypto Notepad/MainForm.cs rename to Crypto Notepad/Forms/MainForm.cs diff --git a/Crypto Notepad/MainForm.resx b/Crypto Notepad/Forms/MainForm.resx similarity index 100% rename from Crypto Notepad/MainForm.resx rename to Crypto Notepad/Forms/MainForm.resx diff --git a/Crypto Notepad/PasswordGeneratorFrom.Designer.cs b/Crypto Notepad/Forms/PasswordGeneratorFrom.Designer.cs similarity index 96% rename from Crypto Notepad/PasswordGeneratorFrom.Designer.cs rename to Crypto Notepad/Forms/PasswordGeneratorFrom.Designer.cs index 3c80cd2..ff2012e 100644 --- a/Crypto Notepad/PasswordGeneratorFrom.Designer.cs +++ b/Crypto Notepad/Forms/PasswordGeneratorFrom.Designer.cs @@ -200,6 +200,7 @@ private void InitializeComponent() this.copyAllButton.Text = "Copy All"; this.copyAllButton.UseVisualStyleBackColor = true; this.copyAllButton.Click += new System.EventHandler(this.CopyAllButton_Click); + this.copyAllButton.MouseEnter += new System.EventHandler(this.CopyAllButton_MouseEnter); // // copyLastButton // @@ -211,6 +212,13 @@ private void InitializeComponent() this.copyLastButton.Text = "Copy Last"; this.copyLastButton.UseVisualStyleBackColor = true; this.copyLastButton.Click += new System.EventHandler(this.CopyLastButton_Click); + this.copyLastButton.MouseEnter += new System.EventHandler(this.CopyLastButton_MouseEnter); + // + // passwordGeneratorToolTip + // + this.passwordGeneratorToolTip.AutoPopDelay = 1000; + this.passwordGeneratorToolTip.InitialDelay = 500; + this.passwordGeneratorToolTip.ReshowDelay = 100; // // PasswordGeneratorFrom // diff --git a/Crypto Notepad/PasswordGeneratorFrom.cs b/Crypto Notepad/Forms/PasswordGeneratorFrom.cs similarity index 92% rename from Crypto Notepad/PasswordGeneratorFrom.cs rename to Crypto Notepad/Forms/PasswordGeneratorFrom.cs index 536cee4..00ea07f 100644 --- a/Crypto Notepad/PasswordGeneratorFrom.cs +++ b/Crypto Notepad/Forms/PasswordGeneratorFrom.cs @@ -137,13 +137,13 @@ private void PasswordValidation(object sender, EventArgs e) private void CopyAllButton_Click(object sender, EventArgs e) { Clipboard.SetText(passwordsListTextBox.Text); - passwordGeneratorToolTip.Show("Copied", copyAllButton, 0, -20, 1000); + passwordGeneratorToolTip.SetToolTip(copyAllButton, "Copied"); } private void CopyLastButton_Click(object sender, EventArgs e) { Clipboard.SetText(passwordsListTextBox.Lines[passwordsListTextBox.Lines.Length - 1]); - passwordGeneratorToolTip.Show("Copied", copyLastButton, 0, -20, 1000); + passwordGeneratorToolTip.SetToolTip(copyLastButton, "Copied"); } private void PasswordsListTextBox_TextChanged(object sender, EventArgs e) @@ -159,8 +159,17 @@ private void PasswordsListTextBox_TextChanged(object sender, EventArgs e) copyAllButton.Enabled = true; } } + #endregion + private void CopyLastButton_MouseEnter(object sender, EventArgs e) + { + passwordGeneratorToolTip.SetToolTip(copyLastButton, null); + } + private void CopyAllButton_MouseEnter(object sender, EventArgs e) + { + passwordGeneratorToolTip.SetToolTip(copyAllButton, null); + } } } diff --git a/Crypto Notepad/PasswordGeneratorFrom.resx b/Crypto Notepad/Forms/PasswordGeneratorFrom.resx similarity index 100% rename from Crypto Notepad/PasswordGeneratorFrom.resx rename to Crypto Notepad/Forms/PasswordGeneratorFrom.resx diff --git a/Crypto Notepad/SettingsForm.Designer.cs b/Crypto Notepad/Forms/SettingsForm.Designer.cs similarity index 100% rename from Crypto Notepad/SettingsForm.Designer.cs rename to Crypto Notepad/Forms/SettingsForm.Designer.cs diff --git a/Crypto Notepad/SettingsForm.cs b/Crypto Notepad/Forms/SettingsForm.cs similarity index 100% rename from Crypto Notepad/SettingsForm.cs rename to Crypto Notepad/Forms/SettingsForm.cs diff --git a/Crypto Notepad/SettingsForm.resx b/Crypto Notepad/Forms/SettingsForm.resx similarity index 100% rename from Crypto Notepad/SettingsForm.resx rename to Crypto Notepad/Forms/SettingsForm.resx