Skip to content

Commit

Permalink
Typo
Browse files Browse the repository at this point in the history
  • Loading branch information
ricardopolo committed Feb 16, 2015
1 parent ce729d1 commit e5fc0ab
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

namespace Tulpep.Integritul.Models
{
public class ResultOfComparision
public class ResultOfComparison
{
public string FilePath { get; set; }
public string Status { get; set; }
Expand Down
6 changes: 3 additions & 3 deletions Tulpep.Integritul/Tulpep.Integritul.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -95,9 +95,9 @@
</ApplicationDefinition>
<Compile Include="AppBootstrapper.cs" />
<Compile Include="IShell.cs" />
<Compile Include="Models\ResultOfComparision.cs" />
<Compile Include="Models\ResultOfComparison.cs" />
<Compile Include="ViewModels\HomeViewModel.cs" />
<Compile Include="ViewModels\ResultOfComparisionViewModel.cs" />
<Compile Include="ViewModels\ResultOfComparisonViewModel.cs" />
<Compile Include="ViewModels\ShellViewModel.cs" />
<Compile Include="App.xaml.cs">
<DependentUpon>App.xaml</DependentUpon>
Expand All @@ -107,7 +107,7 @@
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="Views\ResultOfComparisionView.xaml">
<Page Include="Views\ResultOfComparisonView.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
Expand Down
14 changes: 7 additions & 7 deletions Tulpep.Integritul/ViewModels/HomeViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ public async Task CompareIntegrity()
progressDialog.SetMessage(value);
});
var progress = progressHandler as IProgress<string>;
IEnumerable<ResultOfComparision> differences = new List<ResultOfComparision>();
IEnumerable<ResultOfComparison> differences = new List<ResultOfComparison>();
await Task.Run(() =>
{
differences = CompareFolder(folderToScan, integrityFile, progress);
Expand All @@ -105,7 +105,7 @@ await Task.Run(() =>
if(differences.Any())
{
IShell shell = IoC.Get<IShell>();
shell.ChangeScreen(new ResultOfComparisionViewModel(differences));
shell.ChangeScreen(new ResultOfComparisonViewModel(differences));
}
else
{
Expand All @@ -125,10 +125,10 @@ private static void InitialStatusOfFolder(string folder, string zipFile, IProgre

File.WriteAllText(zipFile, JsonConvert.SerializeObject(result, Formatting.Indented));
}
private static IEnumerable<ResultOfComparision> CompareFolder(string folder, string zipFile, IProgress<string> progress)
private static IEnumerable<ResultOfComparison> CompareFolder(string folder, string zipFile, IProgress<string> progress)
{
Dictionary<string, string> original = JsonConvert.DeserializeObject<Dictionary<string, string>>(File.ReadAllText(zipFile));
List<ResultOfComparision> differences = new List<ResultOfComparision>();
List<ResultOfComparison> differences = new List<ResultOfComparison>();
foreach (var fileName in Directory.EnumerateFiles(folder, "*.*", SearchOption.AllDirectories))
{
progress.Report(fileName);
Expand All @@ -137,19 +137,19 @@ private static IEnumerable<ResultOfComparision> CompareFolder(string folder, str
{
if(original[relativePath] != GetChecksum(fileName))
{
differences.Add(new ResultOfComparision { FilePath = fileName, Status = "Modified"});
differences.Add(new ResultOfComparison { FilePath = fileName, Status = "Modified"});
}
original.Remove(relativePath);
}
else
{
differences.Add(new ResultOfComparision { FilePath = fileName, Status = "New File"});
differences.Add(new ResultOfComparison { FilePath = fileName, Status = "New File"});
}
}

foreach(var entry in original)
{
differences.Add(new ResultOfComparision { FilePath = entry.Key, Status = "Deleted" });
differences.Add(new ResultOfComparison { FilePath = entry.Key, Status = "Deleted" });
}

return differences;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@

namespace Tulpep.Integritul.ViewModels
{
public class ResultOfComparisionViewModel : Screen
public class ResultOfComparisonViewModel : Screen
{
public IEnumerable<ResultOfComparision> ResultList { get; set; }
public IEnumerable<ResultOfComparison> ResultList { get; set; }

public ResultOfComparisionViewModel(IEnumerable<ResultOfComparision> result)
public ResultOfComparisonViewModel(IEnumerable<ResultOfComparison> result)
{
ResultList = result;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@
mc:Ignorable="d"
d:DesignHeight="600" d:DesignWidth="800">
<Grid>
<TextBlock Opacity="0.8" FontSize="20" TextWrapping="Wrap" x:Name="ResultsTitle" Margin="0,20,0,20" Foreground="Black" HorizontalAlignment="Center" TextAlignment="Center" Width="617">
<TextBlock Opacity="0.8" FontSize="20" TextWrapping="Wrap" x:Name="ResultsTitle" Margin="92,20,92,0" Foreground="Black" HorizontalAlignment="Center" TextAlignment="Center" Width="616" Height="560" VerticalAlignment="Top">
Here are the results of your comparison per every file in the folder
</TextBlock>
<DataGrid ItemsSource="{Binding ResultList}"
<DataGrid ItemsSource="{Binding ResultList}"
CanUserReorderColumns="True" CanUserResizeColumns="True"
CanUserResizeRows="False" CanUserSortColumns="True" Margin="30,70,30,91"/>
<Button x:Name="Home" Content="Go Back" ToolTip="Home" Width="200" Height="50" Margin="303,0,297,20" VerticalAlignment="Bottom"/>
Expand Down

0 comments on commit e5fc0ab

Please sign in to comment.