Implemented opening/saving themes

This commit is contained in:
Ben
2015-06-26 17:42:20 +01:00
parent aa5cedcbba
commit 71ad5f2d05
60 changed files with 804 additions and 151 deletions

View File

@@ -0,0 +1,36 @@
using System;
using System.IO;
namespace Filtration.Common.Services
{
public interface IFileSystemService
{
string ReadFileAsString(string filePath);
void WriteFileFromString(string filePath, string inputString);
bool DirectoryExists(string directoryPath);
string GetUserProfilePath();
}
internal class FileSystemService : IFileSystemService
{
public string ReadFileAsString(string filePath)
{
return File.ReadAllText(filePath);
}
public void WriteFileFromString(string filePath, string inputString)
{
File.WriteAllText(filePath, inputString);
}
public bool DirectoryExists(string directoryPath)
{
return Directory.Exists(directoryPath);
}
public string GetUserProfilePath()
{
return Environment.GetFolderPath(Environment.SpecialFolder.UserProfile);
}
}
}