Skip to content
This repository has been archived by the owner on Jul 24, 2022. It is now read-only.

Commit

Permalink
Clear blacklist when game directory is changed
Browse files Browse the repository at this point in the history
  • Loading branch information
Faith committed Mar 11, 2017
1 parent 73076d1 commit 7349439
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions Spectabis-WPF/Views/Library.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1072,6 +1072,10 @@ private void Directory_Click(object sender, RoutedEventArgs e)
Properties.Settings.Default.Save();
PushSnackbar("Game directory folder has been removed!");
}

ClearBlacklist();


}

//"Global Controller" button left click
Expand Down Expand Up @@ -1497,6 +1501,17 @@ private bool IsGameBlacklisted(string _file)
}
}


//Delete blacklist file and create a blank file
private void ClearBlacklist()
{
if(File.Exists(BaseDirectory + @"\resources\logs\blacklist.txt"))
{
File.Delete(BaseDirectory + @"\resources\logs\blacklist.txt");
}
File.Create(BaseDirectory + @"\resources\logs\blacklist.txt");
}

//Controls "Plus" Button popup button visiblity
void PopButtonHitTest(bool e)
{
Expand Down

0 comments on commit 7349439

Please sign in to comment.