mirror of
https://github.com/Tyrrrz/DiscordChatExporter.git
synced 2025-05-22 10:55:15 -04:00
[GUI] Fix outdated binding
This commit is contained in:
parent
da9536bd1b
commit
720e53caab
1 changed files with 66 additions and 66 deletions
|
@ -1,17 +1,17 @@
|
||||||
<UserControl
|
<UserControl
|
||||||
|
Style="{DynamicResource MaterialDesignRoot}"
|
||||||
|
Width="380"
|
||||||
|
d:DataContext="{d:DesignInstance Type=dialogs:ExportSetupViewModel}"
|
||||||
|
mc:Ignorable="d"
|
||||||
x:Class="DiscordChatExporter.Gui.Views.Dialogs.ExportSetupView"
|
x:Class="DiscordChatExporter.Gui.Views.Dialogs.ExportSetupView"
|
||||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
||||||
xmlns:converters="clr-namespace:DiscordChatExporter.Gui.Converters"
|
xmlns:converters="clr-namespace:DiscordChatExporter.Gui.Converters"
|
||||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||||
xmlns:dialogs="clr-namespace:DiscordChatExporter.Gui.ViewModels.Dialogs"
|
xmlns:dialogs="clr-namespace:DiscordChatExporter.Gui.ViewModels.Dialogs"
|
||||||
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
|
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
|
||||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||||
xmlns:s="https://github.com/canton7/Stylet"
|
xmlns:s="https://github.com/canton7/Stylet"
|
||||||
Width="380"
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||||||
d:DataContext="{d:DesignInstance Type=dialogs:ExportSetupViewModel}"
|
|
||||||
Style="{DynamicResource MaterialDesignRoot}"
|
|
||||||
mc:Ignorable="d">
|
|
||||||
<StackPanel>
|
<StackPanel>
|
||||||
<!-- Guild/channel info -->
|
<!-- Guild/channel info -->
|
||||||
<Grid Margin="16">
|
<Grid Margin="16">
|
||||||
|
@ -23,8 +23,8 @@
|
||||||
<!-- Guild icon -->
|
<!-- Guild icon -->
|
||||||
<Ellipse
|
<Ellipse
|
||||||
Grid.Column="0"
|
Grid.Column="0"
|
||||||
Width="32"
|
Height="32"
|
||||||
Height="32">
|
Width="32">
|
||||||
<Ellipse.Fill>
|
<Ellipse.Fill>
|
||||||
<ImageBrush ImageSource="{Binding Guild.IconUrl}" />
|
<ImageBrush ImageSource="{Binding Guild.IconUrl}" />
|
||||||
</Ellipse.Fill>
|
</Ellipse.Fill>
|
||||||
|
@ -32,11 +32,11 @@
|
||||||
|
|
||||||
<!-- Placeholder (for multiple channels) -->
|
<!-- Placeholder (for multiple channels) -->
|
||||||
<TextBlock
|
<TextBlock
|
||||||
|
FontSize="19"
|
||||||
Grid.Column="1"
|
Grid.Column="1"
|
||||||
Margin="8,0,0,0"
|
Margin="8,0,0,0"
|
||||||
VerticalAlignment="Center"
|
|
||||||
FontSize="19"
|
|
||||||
TextTrimming="CharacterEllipsis"
|
TextTrimming="CharacterEllipsis"
|
||||||
|
VerticalAlignment="Center"
|
||||||
Visibility="{Binding IsSingleChannel, Converter={x:Static s:BoolToVisibilityConverter.InverseInstance}}">
|
Visibility="{Binding IsSingleChannel, Converter={x:Static s:BoolToVisibilityConverter.InverseInstance}}">
|
||||||
<Run Text="{Binding Channels.Count, Mode=OneWay}" />
|
<Run Text="{Binding Channels.Count, Mode=OneWay}" />
|
||||||
<Run Text="channels selected" />
|
<Run Text="channels selected" />
|
||||||
|
@ -44,14 +44,14 @@
|
||||||
|
|
||||||
<!-- Category and channel name (for single channel) -->
|
<!-- Category and channel name (for single channel) -->
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Grid.Column="1"
|
|
||||||
Margin="8,0,0,0"
|
|
||||||
VerticalAlignment="Center"
|
|
||||||
FontSize="19"
|
FontSize="19"
|
||||||
FontWeight="Light"
|
FontWeight="Light"
|
||||||
|
Grid.Column="1"
|
||||||
|
Margin="8,0,0,0"
|
||||||
TextTrimming="CharacterEllipsis"
|
TextTrimming="CharacterEllipsis"
|
||||||
|
VerticalAlignment="Center"
|
||||||
Visibility="{Binding IsSingleChannel, Converter={x:Static s:BoolToVisibilityConverter.Instance}}">
|
Visibility="{Binding IsSingleChannel, Converter={x:Static s:BoolToVisibilityConverter.Instance}}">
|
||||||
<Run Text="{Binding Channels[0].Category, Mode=OneWay}" ToolTip="{Binding Channels[0].Category, Mode=OneWay}" />
|
<Run Text="{Binding Channels[0].Category.Name, Mode=OneWay}" ToolTip="{Binding Channels[0].Category.Name, Mode=OneWay}" />
|
||||||
<Run Text="/" />
|
<Run Text="/" />
|
||||||
<Run
|
<Run
|
||||||
FontWeight="SemiBold"
|
FontWeight="SemiBold"
|
||||||
|
@ -62,12 +62,12 @@
|
||||||
|
|
||||||
<!-- Format -->
|
<!-- Format -->
|
||||||
<ComboBox
|
<ComboBox
|
||||||
Margin="16,8"
|
|
||||||
materialDesign:HintAssist.Hint="Format"
|
|
||||||
materialDesign:HintAssist.IsFloating="True"
|
|
||||||
IsReadOnly="True"
|
IsReadOnly="True"
|
||||||
ItemsSource="{Binding AvailableFormats}"
|
ItemsSource="{Binding AvailableFormats}"
|
||||||
SelectedItem="{Binding SelectedFormat}">
|
Margin="16,8"
|
||||||
|
SelectedItem="{Binding SelectedFormat}"
|
||||||
|
materialDesign:HintAssist.Hint="Format"
|
||||||
|
materialDesign:HintAssist.IsFloating="True">
|
||||||
<ComboBox.ItemTemplate>
|
<ComboBox.ItemTemplate>
|
||||||
<DataTemplate>
|
<DataTemplate>
|
||||||
<TextBlock Text="{Binding Converter={x:Static converters:ExportFormatToStringConverter.Instance}}" />
|
<TextBlock Text="{Binding Converter={x:Static converters:ExportFormatToStringConverter.Instance}}" />
|
||||||
|
@ -88,58 +88,58 @@
|
||||||
<RowDefinition Height="*" />
|
<RowDefinition Height="*" />
|
||||||
</Grid.RowDefinitions>
|
</Grid.RowDefinitions>
|
||||||
<DatePicker
|
<DatePicker
|
||||||
Grid.Row="0"
|
|
||||||
Grid.Column="0"
|
|
||||||
Margin="16,8,16,4"
|
|
||||||
materialDesign:HintAssist.Hint="After (date)"
|
|
||||||
materialDesign:HintAssist.IsFloating="True"
|
|
||||||
DisplayDateEnd="{Binding BeforeDate, Converter={x:Static converters:DateTimeOffsetToDateTimeConverter.Instance}}"
|
DisplayDateEnd="{Binding BeforeDate, Converter={x:Static converters:DateTimeOffsetToDateTimeConverter.Instance}}"
|
||||||
SelectedDate="{Binding AfterDate, Converter={x:Static converters:DateTimeOffsetToDateTimeConverter.Instance}}"
|
|
||||||
ToolTip="Only include messages sent after this date" />
|
|
||||||
<DatePicker
|
|
||||||
Grid.Row="0"
|
|
||||||
Grid.Column="1"
|
|
||||||
Margin="16,8,16,4"
|
|
||||||
materialDesign:HintAssist.Hint="Before (date)"
|
|
||||||
materialDesign:HintAssist.IsFloating="True"
|
|
||||||
DisplayDateStart="{Binding AfterDate, Converter={x:Static converters:DateTimeOffsetToDateTimeConverter.Instance}}"
|
|
||||||
SelectedDate="{Binding BeforeDate, Converter={x:Static converters:DateTimeOffsetToDateTimeConverter.Instance}}"
|
|
||||||
ToolTip="Only include messages sent before this date" />
|
|
||||||
<materialDesign:TimePicker
|
|
||||||
Grid.Row="1"
|
|
||||||
Grid.Column="0"
|
Grid.Column="0"
|
||||||
Margin="16,4,16,8"
|
Grid.Row="0"
|
||||||
materialDesign:HintAssist.Hint="After (time)"
|
Margin="16,8,16,4"
|
||||||
materialDesign:HintAssist.IsFloating="True"
|
SelectedDate="{Binding AfterDate, Converter={x:Static converters:DateTimeOffsetToDateTimeConverter.Instance}}"
|
||||||
IsEnabled="{Binding IsAfterDateSet}"
|
ToolTip="Only include messages sent after this date"
|
||||||
SelectedTime="{Binding AfterTime, Converter={x:Static converters:TimeSpanToDateTimeConverter.Instance}}"
|
materialDesign:HintAssist.Hint="After (date)"
|
||||||
ToolTip="Only include messages sent after this time" />
|
materialDesign:HintAssist.IsFloating="True" />
|
||||||
<materialDesign:TimePicker
|
<DatePicker
|
||||||
Grid.Row="1"
|
DisplayDateStart="{Binding AfterDate, Converter={x:Static converters:DateTimeOffsetToDateTimeConverter.Instance}}"
|
||||||
Grid.Column="1"
|
Grid.Column="1"
|
||||||
|
Grid.Row="0"
|
||||||
|
Margin="16,8,16,4"
|
||||||
|
SelectedDate="{Binding BeforeDate, Converter={x:Static converters:DateTimeOffsetToDateTimeConverter.Instance}}"
|
||||||
|
ToolTip="Only include messages sent before this date"
|
||||||
|
materialDesign:HintAssist.Hint="Before (date)"
|
||||||
|
materialDesign:HintAssist.IsFloating="True" />
|
||||||
|
<materialDesign:TimePicker
|
||||||
|
Grid.Column="0"
|
||||||
|
Grid.Row="1"
|
||||||
|
IsEnabled="{Binding IsAfterDateSet}"
|
||||||
Margin="16,4,16,8"
|
Margin="16,4,16,8"
|
||||||
materialDesign:HintAssist.Hint="Before (time)"
|
SelectedTime="{Binding AfterTime, Converter={x:Static converters:TimeSpanToDateTimeConverter.Instance}}"
|
||||||
materialDesign:HintAssist.IsFloating="True"
|
ToolTip="Only include messages sent after this time"
|
||||||
|
materialDesign:HintAssist.Hint="After (time)"
|
||||||
|
materialDesign:HintAssist.IsFloating="True" />
|
||||||
|
<materialDesign:TimePicker
|
||||||
|
Grid.Column="1"
|
||||||
|
Grid.Row="1"
|
||||||
IsEnabled="{Binding IsBeforeDateSet}"
|
IsEnabled="{Binding IsBeforeDateSet}"
|
||||||
|
Margin="16,4,16,8"
|
||||||
SelectedTime="{Binding BeforeTime, Converter={x:Static converters:TimeSpanToDateTimeConverter.Instance}}"
|
SelectedTime="{Binding BeforeTime, Converter={x:Static converters:TimeSpanToDateTimeConverter.Instance}}"
|
||||||
ToolTip="Only include messages sent before this time" />
|
ToolTip="Only include messages sent before this time"
|
||||||
|
materialDesign:HintAssist.Hint="Before (time)"
|
||||||
|
materialDesign:HintAssist.IsFloating="True" />
|
||||||
</Grid>
|
</Grid>
|
||||||
|
|
||||||
<!-- Partitioning -->
|
<!-- Partitioning -->
|
||||||
<TextBox
|
<TextBox
|
||||||
Margin="16,8"
|
Margin="16,8"
|
||||||
materialDesign:HintAssist.Hint="Partition limit"
|
|
||||||
materialDesign:HintAssist.IsFloating="True"
|
|
||||||
Text="{Binding PartitionLimitValue}"
|
Text="{Binding PartitionLimitValue}"
|
||||||
ToolTip="Split output into partitions, each limited to this number of messages (e.g. '100') or file size (e.g. '10mb')" />
|
ToolTip="Split output into partitions, each limited to this number of messages (e.g. '100') or file size (e.g. '10mb')"
|
||||||
|
materialDesign:HintAssist.Hint="Partition limit"
|
||||||
|
materialDesign:HintAssist.IsFloating="True" />
|
||||||
|
|
||||||
<!-- Filtering -->
|
<!-- Filtering -->
|
||||||
<TextBox
|
<TextBox
|
||||||
Margin="16,8"
|
Margin="16,8"
|
||||||
materialDesign:HintAssist.Hint="Message filter"
|
|
||||||
materialDesign:HintAssist.IsFloating="True"
|
|
||||||
Text="{Binding MessageFilterValue}"
|
Text="{Binding MessageFilterValue}"
|
||||||
ToolTip="Only include messages that satisfy this filter (e.g. 'from:foo#1234' or 'has:image')." />
|
ToolTip="Only include messages that satisfy this filter (e.g. 'from:foo#1234' or 'has:image')."
|
||||||
|
materialDesign:HintAssist.Hint="Message filter"
|
||||||
|
materialDesign:HintAssist.IsFloating="True" />
|
||||||
|
|
||||||
<!-- Download media -->
|
<!-- Download media -->
|
||||||
<Grid Margin="16,16" ToolTip="Download referenced media content (user avatars, attached files, embedded images, etc)">
|
<Grid Margin="16,16" ToolTip="Download referenced media content (user avatars, attached files, embedded images, etc)">
|
||||||
|
@ -150,13 +150,13 @@
|
||||||
|
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Grid.Column="0"
|
Grid.Column="0"
|
||||||
VerticalAlignment="Center"
|
Text="Download media"
|
||||||
Text="Download media" />
|
VerticalAlignment="Center" />
|
||||||
<ToggleButton
|
<ToggleButton
|
||||||
Grid.Column="1"
|
Grid.Column="1"
|
||||||
HorizontalAlignment="Right"
|
HorizontalAlignment="Right"
|
||||||
VerticalAlignment="Center"
|
IsChecked="{Binding ShouldDownloadMedia}"
|
||||||
IsChecked="{Binding ShouldDownloadMedia}" />
|
VerticalAlignment="Center" />
|
||||||
</Grid>
|
</Grid>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
|
|
||||||
|
@ -170,29 +170,29 @@
|
||||||
</Grid.ColumnDefinitions>
|
</Grid.ColumnDefinitions>
|
||||||
|
|
||||||
<ToggleButton
|
<ToggleButton
|
||||||
x:Name="AdvancedSectionToggleButton"
|
|
||||||
Grid.Column="0"
|
|
||||||
Width="24"
|
|
||||||
Height="24"
|
|
||||||
Margin="12"
|
|
||||||
Cursor="Hand"
|
Cursor="Hand"
|
||||||
|
Grid.Column="0"
|
||||||
|
Height="24"
|
||||||
IsChecked="{Binding IsAdvancedSectionDisplayedByDefault, Mode=OneTime}"
|
IsChecked="{Binding IsAdvancedSectionDisplayedByDefault, Mode=OneTime}"
|
||||||
|
Margin="12"
|
||||||
Style="{DynamicResource MaterialDesignHamburgerToggleButton}"
|
Style="{DynamicResource MaterialDesignHamburgerToggleButton}"
|
||||||
ToolTip="Toggle advanced options" />
|
ToolTip="Toggle advanced options"
|
||||||
|
Width="24"
|
||||||
|
x:Name="AdvancedSectionToggleButton" />
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
Grid.Column="2"
|
|
||||||
Margin="8"
|
|
||||||
Command="{s:Action Confirm}"
|
Command="{s:Action Confirm}"
|
||||||
Content="EXPORT"
|
Content="EXPORT"
|
||||||
|
Grid.Column="2"
|
||||||
IsDefault="True"
|
IsDefault="True"
|
||||||
|
Margin="8"
|
||||||
Style="{DynamicResource MaterialDesignFlatButton}" />
|
Style="{DynamicResource MaterialDesignFlatButton}" />
|
||||||
<Button
|
<Button
|
||||||
Grid.Column="3"
|
|
||||||
Margin="8"
|
|
||||||
Command="{s:Action Close}"
|
Command="{s:Action Close}"
|
||||||
Content="CANCEL"
|
Content="CANCEL"
|
||||||
|
Grid.Column="3"
|
||||||
IsCancel="True"
|
IsCancel="True"
|
||||||
|
Margin="8"
|
||||||
Style="{DynamicResource MaterialDesignFlatButton}" />
|
Style="{DynamicResource MaterialDesignFlatButton}" />
|
||||||
</Grid>
|
</Grid>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue