From 5b48ce02be0d9618481fed18807f2e65da3c3b52 Mon Sep 17 00:00:00 2001 From: Ivandro Ismael Date: Mon, 4 Jul 2016 21:57:14 +0000 Subject: [PATCH] [RemoveTextFromHearingImpaired] - Let GeneratePreview manage cursors style. --- src/Forms/RemoveTextFromHearImpaired.cs | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/src/Forms/RemoveTextFromHearImpaired.cs b/src/Forms/RemoveTextFromHearImpaired.cs index 10cbefd12..a3a41149f 100644 --- a/src/Forms/RemoveTextFromHearImpaired.cs +++ b/src/Forms/RemoveTextFromHearImpaired.cs @@ -99,7 +99,7 @@ namespace Nikse.SubtitleEdit.Forms { if (Subtitle == null) return; - + Cursor.Current = Cursors.WaitCursor; _removeTextForHiLib.Settings = GetSettings(); _removeTextForHiLib.Warnings = new List(); listViewFixes.BeginUpdate(); @@ -120,6 +120,7 @@ namespace Nikse.SubtitleEdit.Forms } listViewFixes.EndUpdate(); groupBoxLinesFound.Text = string.Format(_language.LinesFoundX, count); + Cursor.Current = Cursors.Default; } private void AddToListView(Paragraph p, string newText) @@ -188,16 +189,12 @@ namespace Nikse.SubtitleEdit.Forms private void CheckBoxRemoveTextBetweenCheckedChanged(object sender, EventArgs e) { - Cursor = Cursors.WaitCursor; GeneratePreview(); - Cursor = Cursors.Default; } private void checkBoxRemoveInterjections_CheckedChanged(object sender, EventArgs e) { - Cursor = Cursors.WaitCursor; GeneratePreview(); - Cursor = Cursors.Default; } private void buttonEditInterjections_Click(object sender, EventArgs e) @@ -211,9 +208,7 @@ namespace Nikse.SubtitleEdit.Forms _removeTextForHiLib.ResetInterjections(); if (checkBoxRemoveInterjections.Checked) { - Cursor = Cursors.WaitCursor; GeneratePreview(); - Cursor = Cursors.Default; } } } @@ -250,16 +245,12 @@ namespace Nikse.SubtitleEdit.Forms { checkBoxRemoveTextBeforeColonOnlyUppercase.Enabled = checkBoxRemoveTextBeforeColon.Checked; checkBoxColonSeparateLine.Enabled = checkBoxRemoveTextBeforeColon.Checked; - Cursor = Cursors.WaitCursor; GeneratePreview(); - Cursor = Cursors.Default; } private void checkBoxRemoveIfAllUppercase_CheckedChanged(object sender, EventArgs e) { - Cursor = Cursors.WaitCursor; GeneratePreview(); - Cursor = Cursors.Default; } public RemoveTextForHISettings GetSettings()