Skip to content

Commit

Permalink
Use DataGrid for download list and add sorting
Browse files Browse the repository at this point in the history
Closes #10
  • Loading branch information
Tyrrrz committed Jun 15, 2019
1 parent 1aaf98b commit e7bd937
Show file tree
Hide file tree
Showing 5 changed files with 198 additions and 188 deletions.
26 changes: 26 additions & 0 deletions YoutubeDownloader/App.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,32 @@
<Setter Property="Foreground" Value="{DynamicResource PrimaryTextBrush}" />
</Style>

<Style BasedOn="{StaticResource MaterialDesignDataGrid}" TargetType="{x:Type DataGrid}">
<Setter Property="AutoGenerateColumns" Value="False" />
<Setter Property="CanUserAddRows" Value="False" />
<Setter Property="CanUserDeleteRows" Value="False" />
<Setter Property="CanUserReorderColumns" Value="True" />
<Setter Property="CanUserResizeColumns" Value="True" />
<Setter Property="CanUserSortColumns" Value="True" />
<Setter Property="IsReadOnly" Value="True" />
<Setter Property="SelectionMode" Value="Single" />
<Setter Property="SelectionUnit" Value="FullRow" />
</Style>

<Style BasedOn="{StaticResource MaterialDesignDataGridRow}" TargetType="{x:Type DataGridRow}">
<Setter Property="FocusVisualStyle" Value="{x:Null}" />
</Style>

<Style BasedOn="{StaticResource MaterialDesignDataGridCell}" TargetType="{x:Type DataGridCell}">
<Setter Property="FocusVisualStyle" Value="{x:Null}" />
<Style.Triggers>
<Trigger Property="IsSelected" Value="True">
<Setter Property="Background" Value="{x:Null}" />
<Setter Property="BorderBrush" Value="{x:Null}" />
</Trigger>
</Style.Triggers>
</Style>

<Style
x:Key="MaterialDesignFlatDarkButton"
BasedOn="{StaticResource MaterialDesignFlatButton}"
Expand Down
159 changes: 0 additions & 159 deletions YoutubeDownloader/Views/Components/DownloadView.xaml

This file was deleted.

10 changes: 0 additions & 10 deletions YoutubeDownloader/Views/Components/DownloadView.xaml.cs

This file was deleted.

0 comments on commit e7bd937

Please sign in to comment.