Skip to content

Commit

Permalink
minor
Browse files Browse the repository at this point in the history
  • Loading branch information
tigros committed Aug 10, 2023
1 parent 69cd34f commit dd1e372
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
4 changes: 2 additions & 2 deletions whisperer/Form1.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 6 additions & 2 deletions whisperer/Form1.cs
Original file line number Diff line number Diff line change
Expand Up @@ -213,11 +213,13 @@ private void button1_Click(object sender, EventArgs e)
{
if (openFileDialog1.ShowDialog() == DialogResult.OK)
{
fastObjectListView1.BeginUpdate();
foreach (string filename in openFileDialog1.FileNames)
{
if (!fexists(filename))
fastObjectListView1.AddObject(new filenameline(filename));
}
fastObjectListView1.EndUpdate();
setcount();
}
}
Expand Down Expand Up @@ -437,9 +439,9 @@ void tryrename(string filename, string ext)

void renamewaves(string filename)
{
if (filename.EndsWith(".wav.wav", StringComparison.InvariantCultureIgnoreCase))
if (filename.EndsWith(".wav.wav"))
{
filename = filename.Remove(filename.LastIndexOf(".wav.wav", StringComparison.InvariantCultureIgnoreCase));
filename = filename.Remove(filename.Length - 8);
foreach (string ext in exts)
tryrename(filename, ext);
}
Expand Down Expand Up @@ -625,11 +627,13 @@ private void fastObjectListView1_DragEnter(object sender, DragEventArgs e)

private void fastObjectListView1_DragDrop(object sender, DragEventArgs e)
{
fastObjectListView1.BeginUpdate();
foreach (string file in (string[])e.Data.GetData(DataFormats.FileDrop))
{
if (!fexists(file))
fastObjectListView1.AddObject(new filenameline(file));
}
fastObjectListView1.EndUpdate();
setcount();
}

Expand Down

0 comments on commit dd1e372

Please sign in to comment.