[WP] Refactoring so its in common to C#

This commit is contained in:
2017-04-21 21:55:26 +00:00
parent a7ce209510
commit 0fe8437e0d
4 changed files with 58 additions and 10 deletions
+11 -1
View File
@@ -8,7 +8,7 @@ using System.Threading.Tasks;
namespace BlubbFish.Utils
{
public class InIReader
public class InIReader : IDisposable
{
private Dictionary<String, Dictionary<String, String>> cont;
private FileSystemWatcher k = new FileSystemWatcher(Directory.GetCurrentDirectory(), "*.ini");
@@ -171,5 +171,15 @@ namespace BlubbFish.Utils
this.Changed();
return false;
}
protected virtual void Dispose(Boolean disposing) {
if (disposing) {
this.k.Dispose();
}
}
public void Dispose() {
Dispose(true);
GC.SuppressFinalize(this);
}
}
}