mirror of
https://github.com/Tyrrrz/DiscordChatExporter.git
synced 2026-04-23 14:33:58 +00:00
Refactor
This commit is contained in:
@@ -95,7 +95,7 @@
|
||||
materialDesign:HintAssist.IsFloating="True"
|
||||
DisplayDateEnd="{Binding BeforeDate, Converter={x:Static converters:DateTimeOffsetToDateTimeConverter.Instance}}"
|
||||
SelectedDate="{Binding AfterDate, Converter={x:Static converters:DateTimeOffsetToDateTimeConverter.Instance}}"
|
||||
ToolTip="If this is set, only messages sent after this date will be exported" />
|
||||
ToolTip="Only include messages sent after this date" />
|
||||
<DatePicker
|
||||
Grid.Row="0"
|
||||
Grid.Column="1"
|
||||
@@ -104,7 +104,7 @@
|
||||
materialDesign:HintAssist.IsFloating="True"
|
||||
DisplayDateStart="{Binding AfterDate, Converter={x:Static converters:DateTimeOffsetToDateTimeConverter.Instance}}"
|
||||
SelectedDate="{Binding BeforeDate, Converter={x:Static converters:DateTimeOffsetToDateTimeConverter.Instance}}"
|
||||
ToolTip="If this is set, only messages sent before this date will be exported" />
|
||||
ToolTip="Only include messages sent before this date" />
|
||||
<materialDesign:TimePicker
|
||||
Grid.Row="1"
|
||||
Grid.Column="0"
|
||||
@@ -113,7 +113,7 @@
|
||||
materialDesign:HintAssist.IsFloating="True"
|
||||
IsEnabled="{Binding IsAfterDateSet}"
|
||||
SelectedTime="{Binding AfterTime, Converter={x:Static converters:TimeSpanToDateTimeConverter.Instance}}"
|
||||
ToolTip="If this is set, only messages sent after this time will be exported" />
|
||||
ToolTip="Only include messages sent after this time" />
|
||||
<materialDesign:TimePicker
|
||||
Grid.Row="1"
|
||||
Grid.Column="1"
|
||||
@@ -122,7 +122,7 @@
|
||||
materialDesign:HintAssist.IsFloating="True"
|
||||
IsEnabled="{Binding IsBeforeDateSet}"
|
||||
SelectedTime="{Binding BeforeTime, Converter={x:Static converters:TimeSpanToDateTimeConverter.Instance}}"
|
||||
ToolTip="If this is set, only messages sent before this time will be exported" />
|
||||
ToolTip="Only include messages sent before this time" />
|
||||
</Grid>
|
||||
|
||||
<!-- Partitioning -->
|
||||
@@ -131,10 +131,10 @@
|
||||
materialDesign:HintAssist.Hint="Messages per partition"
|
||||
materialDesign:HintAssist.IsFloating="True"
|
||||
Text="{Binding PartitionLimit, TargetNullValue=''}"
|
||||
ToolTip="If this is set, the exported file will be split into multiple partitions, each containing no more than specified number of messages" />
|
||||
ToolTip="Split output into partitions limited to this number of messages" />
|
||||
|
||||
<!-- Download media -->
|
||||
<Grid Margin="16,16" ToolTip="If this is set, the export will include additional files such as user avatars, attached files, embedded images, etc">
|
||||
<Grid Margin="16,16" ToolTip="Download referenced media content (user avatars, attached files, embedded images, etc)">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="*" />
|
||||
<ColumnDefinition Width="Auto" />
|
||||
@@ -143,7 +143,7 @@
|
||||
<TextBlock
|
||||
Grid.Column="0"
|
||||
VerticalAlignment="Center"
|
||||
Text="Download referenced media content" />
|
||||
Text="Download media" />
|
||||
<ToggleButton
|
||||
Grid.Column="1"
|
||||
HorizontalAlignment="Right"
|
||||
@@ -168,9 +168,9 @@
|
||||
Height="24"
|
||||
Margin="12"
|
||||
Cursor="Hand"
|
||||
Loaded="AdvancedSectionToggleButton_OnLoaded"
|
||||
IsChecked="{Binding IsAdvancedSectionDisplayedByDefault, Mode=OneTime}"
|
||||
Style="{DynamicResource MaterialDesignHamburgerToggleButton}"
|
||||
ToolTip="Show advanced options" />
|
||||
ToolTip="Toggle advanced options" />
|
||||
|
||||
<Button
|
||||
Grid.Column="2"
|
||||
|
||||
@@ -1,7 +1,4 @@
|
||||
using System.Windows;
|
||||
using DiscordChatExporter.Gui.ViewModels.Dialogs;
|
||||
|
||||
namespace DiscordChatExporter.Gui.Views.Dialogs
|
||||
namespace DiscordChatExporter.Gui.Views.Dialogs
|
||||
{
|
||||
public partial class ExportSetupView
|
||||
{
|
||||
@@ -9,11 +6,5 @@ namespace DiscordChatExporter.Gui.Views.Dialogs
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
private void AdvancedSectionToggleButton_OnLoaded(object sender, RoutedEventArgs e)
|
||||
{
|
||||
if (DataContext is ExportSetupViewModel vm)
|
||||
AdvancedSectionToggleButton.IsChecked = vm.IsAdvancedSectionDisplayedByDefault;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -65,15 +65,15 @@
|
||||
IsChecked="{Binding IsTokenPersisted}" />
|
||||
</DockPanel>
|
||||
|
||||
<!-- Reuse Media -->
|
||||
<!-- Reuse media -->
|
||||
<DockPanel
|
||||
Background="Transparent"
|
||||
LastChildFill="False"
|
||||
ToolTip="If the media folder already exists, reuse media inside it to skip downloads">
|
||||
ToolTip="Reuse already existing media content to skip redundant downloads">
|
||||
<TextBlock
|
||||
Margin="16,8"
|
||||
DockPanel.Dock="Left"
|
||||
Text="Reuse previously downloaded media" />
|
||||
Text="Reuse downloaded media" />
|
||||
<ToggleButton
|
||||
Margin="16,8"
|
||||
DockPanel.Dock="Right"
|
||||
@@ -86,7 +86,7 @@
|
||||
materialDesign:HintAssist.Hint="Date format"
|
||||
materialDesign:HintAssist.IsFloating="True"
|
||||
Text="{Binding DateFormat}"
|
||||
ToolTip="Format used when rendering dates (uses .NET date formatting rules)" />
|
||||
ToolTip="Format used when writing dates (uses .NET date formatting rules)" />
|
||||
|
||||
<!-- Parallel limit -->
|
||||
<StackPanel Background="Transparent" ToolTip="How many channels can be exported at the same time">
|
||||
|
||||
@@ -9,14 +9,10 @@ namespace DiscordChatExporter.Gui.Views.Dialogs
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
private void DarkModeToggleButton_Checked(object sender, RoutedEventArgs e)
|
||||
{
|
||||
private void DarkModeToggleButton_Checked(object sender, RoutedEventArgs e) =>
|
||||
App.SetDarkTheme();
|
||||
}
|
||||
|
||||
private void DarkModeToggleButton_Unchecked(object sender, RoutedEventArgs e)
|
||||
{
|
||||
private void DarkModeToggleButton_Unchecked(object sender, RoutedEventArgs e) =>
|
||||
App.SetLightTheme();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user