mirror of
https://github.com/Crypto-Notepad/Crypto-Notepad.git
synced 2026-03-11 08:55:25 +00:00
Formatting code
This commit is contained in:
parent
8b8cb8789d
commit
9c2b77755e
1 changed files with 15 additions and 8 deletions
|
|
@ -448,16 +448,22 @@ private void StatusPanelTextInfo()
|
|||
{
|
||||
if (statusPanel.Visible)
|
||||
{
|
||||
int linesCount = richTextBox.Lines.Length;
|
||||
|
||||
if (linesCount == 0)
|
||||
if (statusPanelLinesLabel.Visible)
|
||||
{
|
||||
linesCount = 1;
|
||||
int linesCount = richTextBox.Lines.Length;
|
||||
if (linesCount == 0)
|
||||
{
|
||||
linesCount = 1;
|
||||
}
|
||||
statusPanelLinesLabel.Text = "Lines: " + linesCount;
|
||||
}
|
||||
if (statusPanelLengthLabel.Visible)
|
||||
{
|
||||
statusPanelLengthLabel.Text = "Length: " + richTextBox.TextLength;
|
||||
}
|
||||
statusPanelLengthLabel.Text = "Length: " + richTextBox.TextLength;
|
||||
statusPanelLinesLabel.Text = "Lines: " + linesCount;
|
||||
}
|
||||
}
|
||||
|
||||
private void StatusPanelTimer_Tick(object sender, EventArgs e)
|
||||
{
|
||||
StatusPanelTextInfo();
|
||||
|
|
@ -969,6 +975,7 @@ private void RichTextBox_TextChanged(object sender, EventArgs e)
|
|||
Text = Text.Replace("*", string.Empty);
|
||||
}
|
||||
}
|
||||
|
||||
if (richTextBox.TextLength == 0)
|
||||
{
|
||||
if (Text.Contains("*"))
|
||||
|
|
@ -1075,13 +1082,13 @@ private async void OpenMainMenu_Click(object sender, EventArgs e)
|
|||
PublicVar.openFileName = Path.GetFileName(openFileDialog.FileName);
|
||||
if (!openFileDialog.FileName.Contains(".cnp"))
|
||||
{
|
||||
if (Visible)
|
||||
if (Visible)
|
||||
{
|
||||
PublicVar.messageBoxCenterParent = true;
|
||||
}
|
||||
using (new CenterWinDialog(this))
|
||||
{
|
||||
DialogResult res = MessageBox.Show(this, "Try to decrypt \"" + PublicVar.openFileName + "\" file?", PublicVar.appName,
|
||||
DialogResult res = MessageBox.Show(this, "Try to decrypt \"" + PublicVar.openFileName + "\" file?", PublicVar.appName,
|
||||
MessageBoxButtons.YesNo, MessageBoxIcon.Information);
|
||||
if (res == DialogResult.No)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in a new issue