mirror of
https://github.com/chylex/Discord-History-Tracker.git
synced 2025-07-04 19:38:51 +02:00
Compare commits
4 Commits
295370a3d4
...
c770a066c4
Author | SHA1 | Date | |
---|---|---|---|
c770a066c4 | |||
43bf1fcafe | |||
8857f6c3b1 | |||
87de0b98b5 |
@ -58,18 +58,12 @@
|
||||
<Style Selector="Panel.buttons">
|
||||
<Setter Property="Margin" Value="0 20 0 0" />
|
||||
</Style>
|
||||
<Style Selector="Panel.buttons > WrapPanel.right">
|
||||
<Setter Property="HorizontalAlignment" Value="Right" />
|
||||
<Style Selector="Panel.buttons > WrapPanel">
|
||||
<Setter Property="ItemSpacing" Value="8" />
|
||||
</Style>
|
||||
<Style Selector="Panel.buttons Button">
|
||||
<Setter Property="MinWidth" Value="80" />
|
||||
</Style>
|
||||
<Style Selector="Panel.buttons > WrapPanel.left Button">
|
||||
<Setter Property="Margin" Value="0 0 8 0" />
|
||||
</Style>
|
||||
<Style Selector="Panel.buttons > WrapPanel.right Button">
|
||||
<Setter Property="Margin" Value="8 0 0 0" />
|
||||
</Style>
|
||||
|
||||
</Application.Styles>
|
||||
|
||||
|
@ -15,14 +15,14 @@
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Avalonia" Version="11.2.3" />
|
||||
<PackageReference Include="Avalonia.Controls.DataGrid" Version="11.2.3" />
|
||||
<PackageReference Include="Avalonia" Version="11.3.0" />
|
||||
<PackageReference Include="Avalonia.Controls.DataGrid" Version="11.3.0" />
|
||||
<PackageReference Include="Avalonia.Controls.ItemsRepeater" Version="11.1.5" />
|
||||
<PackageReference Include="Avalonia.Desktop" Version="11.2.3" />
|
||||
<PackageReference Include="Avalonia.Diagnostics" Version="11.2.3" Condition=" '$(Configuration)' == 'Debug' " />
|
||||
<PackageReference Include="Avalonia.Fonts.Inter" Version="11.2.3" />
|
||||
<PackageReference Include="Avalonia.ReactiveUI" Version="11.2.3" />
|
||||
<PackageReference Include="Avalonia.Themes.Fluent" Version="11.2.3" />
|
||||
<PackageReference Include="Avalonia.Desktop" Version="11.3.0" />
|
||||
<PackageReference Include="Avalonia.Diagnostics" Version="11.3.0" Condition=" '$(Configuration)' == 'Debug' " />
|
||||
<PackageReference Include="Avalonia.Fonts.Inter" Version="11.3.0" />
|
||||
<PackageReference Include="Avalonia.ReactiveUI" Version="11.3.0" />
|
||||
<PackageReference Include="Avalonia.Themes.Fluent" Version="11.3.0" />
|
||||
<PackageReference Include="PropertyChanged.SourceGenerator" Version="1.1.1">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
|
@ -30,11 +30,11 @@
|
||||
</ItemsRepeater>
|
||||
</ScrollViewer>
|
||||
<Panel Classes="buttons">
|
||||
<WrapPanel Classes="left">
|
||||
<WrapPanel>
|
||||
<Button Command="{Binding SelectAll}" IsEnabled="{Binding !AreAllSelected}">Select All</Button>
|
||||
<Button Command="{Binding SelectNone}" IsEnabled="{Binding !AreNoneSelected}">Select None</Button>
|
||||
</WrapPanel>
|
||||
<WrapPanel Classes="right">
|
||||
<WrapPanel HorizontalAlignment="Right">
|
||||
<Button Click="ClickOk">OK</Button>
|
||||
<Button Click="ClickCancel">Cancel</Button>
|
||||
</WrapPanel>
|
||||
|
@ -25,7 +25,7 @@
|
||||
<StackPanel Margin="20">
|
||||
<TextBlock Text="{Binding Message}" />
|
||||
<Panel Classes="buttons">
|
||||
<WrapPanel Classes="right">
|
||||
<WrapPanel HorizontalAlignment="Right">
|
||||
<Button Click="ClickOk" IsVisible="{Binding IsOkVisible}">OK</Button>
|
||||
<Button Click="ClickYes" IsVisible="{Binding IsYesVisible}">Yes</Button>
|
||||
<Button Click="ClickNo" IsVisible="{Binding IsNoVisible}">No</Button>
|
||||
|
@ -34,7 +34,7 @@
|
||||
</StackPanel>
|
||||
</ScrollViewer>
|
||||
<Panel Classes="buttons">
|
||||
<WrapPanel Classes="right">
|
||||
<WrapPanel HorizontalAlignment="Right">
|
||||
<Button Click="ClickOk" IsEnabled="{Binding !HasErrors}">OK</Button>
|
||||
<Button Click="ClickCancel">Cancel</Button>
|
||||
</WrapPanel>
|
||||
|
@ -3,12 +3,12 @@
|
||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
xmlns:main="clr-namespace:DHT.Desktop.Main"
|
||||
mc:Ignorable="d" d:DesignWidth="510" d:DesignHeight="375"
|
||||
mc:Ignorable="d" d:DesignWidth="510" d:DesignHeight="425"
|
||||
x:Class="DHT.Desktop.Main.AboutWindow"
|
||||
x:DataType="main:AboutWindowModel"
|
||||
Title="About Discord History Tracker"
|
||||
Icon="avares://DiscordHistoryTracker/Resources/icon.ico"
|
||||
Width="510" Height="375" CanResize="False"
|
||||
Width="510" Height="425" CanResize="False"
|
||||
WindowStartupLocation="CenterOwner">
|
||||
|
||||
<Design.DataContext>
|
||||
@ -21,7 +21,7 @@
|
||||
<Setter Property="VerticalAlignment" Value="Center" />
|
||||
</Style>
|
||||
<Style Selector="Grid > Button">
|
||||
<Setter Property="Margin" Value="0 4" />
|
||||
<Setter Property="Margin" Value="0 3" />
|
||||
<Setter Property="Padding" Value="8 4" />
|
||||
<Setter Property="HorizontalAlignment" Value="Stretch" />
|
||||
</Style>
|
||||
@ -35,39 +35,49 @@
|
||||
</StackPanel>
|
||||
|
||||
<StackPanel Orientation="Horizontal" Spacing="8">
|
||||
<Button Command="{Binding ShowOfficialWebsite}">Official Website</Button>
|
||||
<Button Command="{Binding ShowIssueTracker}">Issue Tracker</Button>
|
||||
<Button Command="{Binding ShowSourceCode}">Source Code</Button>
|
||||
<Button Command="{Binding OpenOfficialWebsite}">Official Website</Button>
|
||||
<Button Command="{Binding OpenIssueTracker}">Issue Tracker</Button>
|
||||
<Button Command="{Binding OpenSourceCode}">Source Code</Button>
|
||||
</StackPanel>
|
||||
|
||||
<Grid RowDefinitions="Auto,5,Auto,Auto,Auto,Auto,Auto,Auto,Auto,Auto" ColumnDefinitions="*,115,95" Margin="0 10 0 0">
|
||||
<Grid RowDefinitions="Auto,5,Auto,Auto,Auto,Auto,Auto,Auto,Auto,Auto" ColumnDefinitions="*,115,90" Margin="0 10 0 0">
|
||||
<TextBlock Grid.Row="0" Grid.Column="0" FontWeight="Bold">Third-Party Software</TextBlock>
|
||||
<TextBlock Grid.Row="0" Grid.Column="1" FontWeight="Bold">License</TextBlock>
|
||||
<TextBlock Grid.Row="0" Grid.Column="2" FontWeight="Bold">Link</TextBlock>
|
||||
|
||||
<TextBlock Grid.Row="2" Grid.Column="0">.NET</TextBlock>
|
||||
<TextBlock Grid.Row="2" Grid.Column="1">MIT</TextBlock>
|
||||
<Button Grid.Row="2" Grid.Column="2" Command="{Binding ShowLibraryNetCore}">GitHub</Button>
|
||||
<Button Grid.Row="2" Grid.Column="2" Command="{Binding OpenThirdPartyNetCore}">GitHub</Button>
|
||||
|
||||
<TextBlock Grid.Row="3" Grid.Column="0">Avalonia</TextBlock>
|
||||
<TextBlock Grid.Row="3" Grid.Column="1">MIT</TextBlock>
|
||||
<Button Grid.Row="3" Grid.Column="2" Command="{Binding ShowLibraryAvalonia}">GitHub</Button>
|
||||
<Button Grid.Row="3" Grid.Column="2" Command="{Binding OpenThirdPartyAvalonia}">GitHub</Button>
|
||||
|
||||
<TextBlock Grid.Row="4" Grid.Column="0">Rx.NET</TextBlock>
|
||||
<TextBlock Grid.Row="4" Grid.Column="1">MIT</TextBlock>
|
||||
<Button Grid.Row="4" Grid.Column="2" Command="{Binding ShowLibraryRxNet}">GitHub</Button>
|
||||
<Button Grid.Row="4" Grid.Column="2" Command="{Binding OpenThirdPartyRxNet}">GitHub</Button>
|
||||
|
||||
<TextBlock Grid.Row="5" Grid.Column="0">SQLite</TextBlock>
|
||||
<TextBlock Grid.Row="5" Grid.Column="1">Public Domain</TextBlock>
|
||||
<Button Grid.Row="5" Grid.Column="2" Command="{Binding ShowLibrarySqlite}">Website</Button>
|
||||
<Button Grid.Row="5" Grid.Column="2" Command="{Binding OpenThirdPartySqlite}">Website</Button>
|
||||
|
||||
<TextBlock Grid.Row="6" Grid.Column="0">Microsoft.Data.Sqlite</TextBlock>
|
||||
<TextBlock Grid.Row="6" Grid.Column="1">Apache-2.0</TextBlock>
|
||||
<Button Grid.Row="6" Grid.Column="2" Command="{Binding ShowLibrarySqliteAdoNet}">NuGet</Button>
|
||||
<Button Grid.Row="6" Grid.Column="2" Command="{Binding OpenThirdPartyMicrosoftDataSqlite}">NuGet</Button>
|
||||
|
||||
<TextBlock Grid.Row="7" Grid.Column="0">PropertyChanged.SourceGenerator</TextBlock>
|
||||
<TextBlock Grid.Row="7" Grid.Column="1">MIT</TextBlock>
|
||||
<Button Grid.Row="7" Grid.Column="2" Command="{Binding ShowLibraryPropertyChangedSourceGenerator}">GitHub</Button>
|
||||
<Button Grid.Row="7" Grid.Column="2" Command="{Binding OpenThirdPartyPropertyChangedSourceGenerator}">GitHub</Button>
|
||||
</Grid>
|
||||
|
||||
<Grid RowDefinitions="Auto,5,Auto,Auto,Auto,Auto,Auto,Auto,Auto,Auto" ColumnDefinitions="*,115,90" Margin="0 5 0 0">
|
||||
<TextBlock Grid.Row="0" Grid.Column="0" FontWeight="Bold">Additional Thanks</TextBlock>
|
||||
<TextBlock Grid.Row="0" Grid.Column="1" FontWeight="Bold">License</TextBlock>
|
||||
<TextBlock Grid.Row="0" Grid.Column="2" FontWeight="Bold">Link</TextBlock>
|
||||
|
||||
<TextBlock Grid.Row="2" Grid.Column="0">BetterDiscord, for Webpack hooks</TextBlock>
|
||||
<TextBlock Grid.Row="2" Grid.Column="1">Apache-2.0</TextBlock>
|
||||
<Button Grid.Row="2" Grid.Column="2" Command="{Binding OpenThirdPartyBetterDiscord}">GitHub</Button>
|
||||
</Grid>
|
||||
|
||||
</StackPanel>
|
||||
|
@ -3,39 +3,43 @@ using DHT.Desktop.Common;
|
||||
namespace DHT.Desktop.Main;
|
||||
|
||||
sealed class AboutWindowModel {
|
||||
public void ShowOfficialWebsite() {
|
||||
public void OpenOfficialWebsite() {
|
||||
SystemUtils.OpenUrl(Program.Website);
|
||||
}
|
||||
|
||||
public void ShowIssueTracker() {
|
||||
public void OpenIssueTracker() {
|
||||
SystemUtils.OpenUrl("https://github.com/chylex/Discord-History-Tracker/issues");
|
||||
}
|
||||
|
||||
public void ShowSourceCode() {
|
||||
public void OpenSourceCode() {
|
||||
SystemUtils.OpenUrl("https://github.com/chylex/Discord-History-Tracker");
|
||||
}
|
||||
|
||||
public void ShowLibraryNetCore() {
|
||||
public void OpenThirdPartyNetCore() {
|
||||
SystemUtils.OpenUrl("https://github.com/dotnet/core");
|
||||
}
|
||||
|
||||
public void ShowLibraryAvalonia() {
|
||||
public void OpenThirdPartyAvalonia() {
|
||||
SystemUtils.OpenUrl("https://github.com/AvaloniaUI/Avalonia");
|
||||
}
|
||||
|
||||
public void ShowLibraryPropertyChangedSourceGenerator() {
|
||||
public void OpenThirdPartyPropertyChangedSourceGenerator() {
|
||||
SystemUtils.OpenUrl("https://github.com/canton7/PropertyChanged.SourceGenerator");
|
||||
}
|
||||
|
||||
public void ShowLibrarySqlite() {
|
||||
public void OpenThirdPartySqlite() {
|
||||
SystemUtils.OpenUrl("https://www.sqlite.org");
|
||||
}
|
||||
|
||||
public void ShowLibrarySqliteAdoNet() {
|
||||
public void OpenThirdPartyMicrosoftDataSqlite() {
|
||||
SystemUtils.OpenUrl("https://www.nuget.org/packages/Microsoft.Data.Sqlite");
|
||||
}
|
||||
|
||||
public void ShowLibraryRxNet() {
|
||||
public void OpenThirdPartyRxNet() {
|
||||
SystemUtils.OpenUrl("https://github.com/dotnet/reactive");
|
||||
}
|
||||
|
||||
public void OpenThirdPartyBetterDiscord() {
|
||||
SystemUtils.OpenUrl("https://github.com/BetterDiscord/BetterDiscord");
|
||||
}
|
||||
}
|
||||
|
@ -13,12 +13,8 @@
|
||||
|
||||
<UserControl.Styles>
|
||||
<Style Selector="WrapPanel > StackPanel">
|
||||
<Setter Property="Margin" Value="0 20 40 0" />
|
||||
<Setter Property="Spacing" Value="4" />
|
||||
</Style>
|
||||
<Style Selector="WrapPanel > StackPanel:nth-last-child(1)">
|
||||
<Setter Property="Margin" Value="0 20 0 0" />
|
||||
</Style>
|
||||
<Style Selector="Grid > Label">
|
||||
<Setter Property="VerticalAlignment" Value="Center" />
|
||||
</Style>
|
||||
@ -30,9 +26,9 @@
|
||||
</Style>
|
||||
</UserControl.Styles>
|
||||
|
||||
<StackPanel>
|
||||
<StackPanel Spacing="20">
|
||||
<TextBlock Text="{Binding FilterStatisticsText}" />
|
||||
<WrapPanel>
|
||||
<WrapPanel ItemSpacing="40" LineSpacing="20">
|
||||
<StackPanel>
|
||||
<CheckBox IsChecked="{Binding LimitSize}">Limit Size</CheckBox>
|
||||
<StackPanel Orientation="Horizontal">
|
||||
|
@ -13,12 +13,8 @@
|
||||
|
||||
<UserControl.Styles>
|
||||
<Style Selector="WrapPanel > StackPanel">
|
||||
<Setter Property="Margin" Value="0 20 40 0" />
|
||||
<Setter Property="Spacing" Value="4" />
|
||||
</Style>
|
||||
<Style Selector="WrapPanel > StackPanel:nth-last-child(1)">
|
||||
<Setter Property="Margin" Value="0 20 0 0" />
|
||||
</Style>
|
||||
<Style Selector="Grid > Label">
|
||||
<Setter Property="VerticalAlignment" Value="Center" />
|
||||
</Style>
|
||||
@ -36,9 +32,9 @@
|
||||
</Style>
|
||||
</UserControl.Styles>
|
||||
|
||||
<StackPanel>
|
||||
<StackPanel Spacing="20">
|
||||
<TextBlock Text="{Binding FilterStatisticsText}" />
|
||||
<WrapPanel>
|
||||
<WrapPanel ItemSpacing="40" LineSpacing="20">
|
||||
<StackPanel>
|
||||
<CheckBox IsChecked="{Binding FilterByDate}">Filter by Date</CheckBox>
|
||||
<Grid ColumnDefinitions="Auto, 4, 125" RowDefinitions="Auto, 4, Auto" Margin="4 0">
|
||||
|
@ -22,16 +22,15 @@
|
||||
</Style>
|
||||
<Style Selector="WrapPanel > StackPanel">
|
||||
<Setter Property="Orientation" Value="Vertical" />
|
||||
<Setter Property="Margin" Value="0 0 10 10" />
|
||||
</Style>
|
||||
</UserControl.Styles>
|
||||
|
||||
<StackPanel>
|
||||
<StackPanel Spacing="10">
|
||||
<Button Command="{Binding OnClickToggleServerButton}" Content="{Binding ToggleServerButtonText}" IsEnabled="{Binding IsToggleServerButtonEnabled}" />
|
||||
<TextBlock TextWrapping="Wrap" Margin="0 15">
|
||||
<TextBlock TextWrapping="Wrap" Margin="0 5">
|
||||
The following settings determine how the tracking script communicates with this application. If you change them, you will have to copy/paste the tracking script or connection code again.
|
||||
</TextBlock>
|
||||
<WrapPanel>
|
||||
<WrapPanel ItemSpacing="10" LineSpacing="10">
|
||||
<StackPanel>
|
||||
<Label Target="Port">Port</Label>
|
||||
<TextBox x:Name="Port" Width="70" Text="{Binding InputPort}" />
|
||||
|
@ -48,7 +48,7 @@
|
||||
</CheckBox>
|
||||
</StackPanel>
|
||||
<Panel Classes="buttons">
|
||||
<WrapPanel Classes="right">
|
||||
<WrapPanel HorizontalAlignment="Right">
|
||||
<Button Click="ClickOk">OK</Button>
|
||||
</WrapPanel>
|
||||
</Panel>
|
||||
|
@ -11,23 +11,17 @@
|
||||
<pages:DatabasePageModel />
|
||||
</Design.DataContext>
|
||||
|
||||
<UserControl.Styles>
|
||||
<Style Selector="WrapPanel > Button">
|
||||
<Setter Property="Margin" Value="0 0 10 10" />
|
||||
</Style>
|
||||
</UserControl.Styles>
|
||||
|
||||
<StackPanel Spacing="10">
|
||||
<DockPanel>
|
||||
<Button Command="{Binding CloseDatabase}" DockPanel.Dock="Right">Close Database</Button>
|
||||
<TextBox Text="{Binding Db.Path}" Width="NaN" Margin="0 0 10 0" IsReadOnly="True" />
|
||||
</DockPanel>
|
||||
<WrapPanel>
|
||||
<WrapPanel ItemSpacing="10" LineSpacing="10">
|
||||
<Button Command="{Binding OpenDatabaseFolder}">Open Database Folder</Button>
|
||||
<Button Command="{Binding MergeWithDatabase}">Merge with Database(s)...</Button>
|
||||
<Button Command="{Binding ImportLegacyArchive}">Import Legacy Archive(s)...</Button>
|
||||
</WrapPanel>
|
||||
<Expander Header="Advanced Tools" Margin="0 15 0 0">
|
||||
<Expander Header="Advanced Tools" Margin="0 25 0 0">
|
||||
<StackPanel Orientation="Vertical" Spacing="10">
|
||||
<TextBlock TextWrapping="Wrap">Recreate the database to free up space after deleting data.</TextBlock>
|
||||
<Button Command="{Binding VacuumDatabase}">Vacuum Database</Button>
|
||||
|
@ -17,27 +17,26 @@
|
||||
<Setter Property="FontSize" Value="15" />
|
||||
</Style>
|
||||
<Style Selector="Label">
|
||||
<Setter Property="Margin" Value="0 5" />
|
||||
<Setter Property="Margin" Value="0" />
|
||||
<Setter Property="Padding" Value="0" />
|
||||
</Style>
|
||||
<Style Selector="WrapPanel > StackPanel">
|
||||
<Setter Property="Orientation" Value="Vertical" />
|
||||
<Setter Property="Margin" Value="0 0 10 10" />
|
||||
</Style>
|
||||
</UserControl.Styles>
|
||||
|
||||
<StackPanel Orientation="Vertical" Spacing="10">
|
||||
<Expander Header="Generate Random Data" IsExpanded="True">
|
||||
<WrapPanel>
|
||||
<StackPanel>
|
||||
<WrapPanel ItemSpacing="10" LineSpacing="10">
|
||||
<StackPanel Spacing="8">
|
||||
<Label Target="Channels">Channels</Label>
|
||||
<TextBox x:Name="Channels" Width="100" Text="{Binding GenerateChannels}" />
|
||||
</StackPanel>
|
||||
<StackPanel>
|
||||
<StackPanel Spacing="8">
|
||||
<Label Target="Users">Users</Label>
|
||||
<TextBox x:Name="Users" Width="100" Text="{Binding GenerateUsers}" />
|
||||
</StackPanel>
|
||||
<StackPanel>
|
||||
<StackPanel Spacing="8">
|
||||
<Label Target="Messages">Messages</Label>
|
||||
<TextBox x:Name="Messages" Width="100" Text="{Binding GenerateMessages}" />
|
||||
</StackPanel>
|
||||
|
@ -13,9 +13,6 @@
|
||||
</Design.DataContext>
|
||||
|
||||
<UserControl.Styles>
|
||||
<Style Selector="WrapPanel > Button">
|
||||
<Setter Property="Margin" Value="0 0 10 10" />
|
||||
</Style>
|
||||
<Style Selector="DataGridColumnHeader">
|
||||
<Setter Property="FontWeight" Value="Medium" />
|
||||
</Style>
|
||||
@ -30,27 +27,25 @@
|
||||
</Style>
|
||||
</UserControl.Styles>
|
||||
|
||||
<StackPanel Orientation="Vertical">
|
||||
<WrapPanel Orientation="Horizontal">
|
||||
<StackPanel Orientation="Vertical" Spacing="20">
|
||||
<WrapPanel Orientation="Horizontal" ItemSpacing="10" LineSpacing="10">
|
||||
<Button Command="{Binding OnClickToggleDownload}" Content="{Binding ToggleDownloadButtonText}" IsEnabled="{Binding IsToggleDownloadButtonEnabled}" />
|
||||
<Button Command="{Binding OnClickRetryFailed}" IsEnabled="{Binding IsRetryFailedOnDownloadsButtonEnabled}">Retry Failed</Button>
|
||||
<Button Command="{Binding OnClickDeleteOrphaned}">Delete Orphaned</Button>
|
||||
<Button Command="{Binding OnClickExportAll}" IsEnabled="{Binding HasSuccessfulDownloads}">Export All...</Button>
|
||||
</WrapPanel>
|
||||
<StackPanel Orientation="Vertical" Spacing="20" Margin="0 10 0 0">
|
||||
<controls:DownloadItemFilterPanel DataContext="{Binding FilterModel}" IsEnabled="{Binding !$parent[UserControl].((pages:DownloadsPageModel)DataContext).IsDownloading}" />
|
||||
<TextBlock TextWrapping="Wrap">
|
||||
Downloading state and filter settings are remembered per-database.
|
||||
</TextBlock>
|
||||
<Expander Header="Download Status" IsExpanded="True">
|
||||
<DataGrid ItemsSource="{Binding StatisticsRows}" AutoGenerateColumns="False" CanUserReorderColumns="False" CanUserResizeColumns="False" CanUserSortColumns="False" IsReadOnly="True">
|
||||
<DataGrid.Columns>
|
||||
<DataGridTextColumn Header="State" Binding="{Binding State, Mode=OneWay}" Width="*" />
|
||||
<DataGridTextColumn Header="Files" Binding="{Binding Items, Mode=OneWay, Converter={StaticResource NumberValueConverter}}" Width="*" CellStyleClasses="right" />
|
||||
<DataGridTextColumn Header="Size" Binding="{Binding SizeText, Mode=OneWay}" Width="*" CellStyleClasses="right" />
|
||||
</DataGrid.Columns>
|
||||
</DataGrid>
|
||||
</Expander>
|
||||
</StackPanel>
|
||||
<controls:DownloadItemFilterPanel DataContext="{Binding FilterModel}" IsEnabled="{Binding !$parent[UserControl].((pages:DownloadsPageModel)DataContext).IsDownloading}" />
|
||||
<TextBlock TextWrapping="Wrap">
|
||||
Downloading state and filter settings are remembered per-database.
|
||||
</TextBlock>
|
||||
<Expander Header="Download Status" IsExpanded="True">
|
||||
<DataGrid ItemsSource="{Binding StatisticsRows}" AutoGenerateColumns="False" CanUserReorderColumns="False" CanUserResizeColumns="False" CanUserSortColumns="False" IsReadOnly="True">
|
||||
<DataGrid.Columns>
|
||||
<DataGridTextColumn Header="State" Binding="{Binding State, Mode=OneWay}" Width="*" />
|
||||
<DataGridTextColumn Header="Files" Binding="{Binding Items, Mode=OneWay, Converter={StaticResource NumberValueConverter}}" Width="*" CellStyleClasses="right" />
|
||||
<DataGridTextColumn Header="Size" Binding="{Binding SizeText, Mode=OneWay}" Width="*" CellStyleClasses="right" />
|
||||
</DataGrid.Columns>
|
||||
</DataGrid>
|
||||
</Expander>
|
||||
</StackPanel>
|
||||
</UserControl>
|
||||
|
@ -15,9 +15,6 @@
|
||||
<Style Selector="TextBlock">
|
||||
<Setter Property="TextWrapping" Value="Wrap" />
|
||||
</Style>
|
||||
<Style Selector="WrapPanel > Button">
|
||||
<Setter Property="Margin" Value="0 0 10 10" />
|
||||
</Style>
|
||||
</UserControl.Styles>
|
||||
|
||||
<StackPanel Spacing="20">
|
||||
@ -37,7 +34,7 @@
|
||||
<Button Command="{Binding OnClickToggleAppDevTools}" Content="{Binding ToggleAppDevToolsButtonText}" IsEnabled="{Binding IsToggleAppDevToolsButtonEnabled}" />
|
||||
</StackPanel>
|
||||
</Expander>
|
||||
<Expander Header="Method 2: Userscript" IsExpanded="True" Padding="12 12 12 2.5">
|
||||
<Expander Header="Method 2: Userscript" IsExpanded="True">
|
||||
<StackPanel Orientation="Vertical" Spacing="10">
|
||||
<TextBlock>
|
||||
Requires a userscript manager in your browser. The userscript adds a DHT icon next to the Help icon on Discord.
|
||||
@ -46,7 +43,7 @@
|
||||
<TextBlock>
|
||||
Copy the Connection Code, click the DHT icon, and paste the code into the prompt.
|
||||
</TextBlock>
|
||||
<WrapPanel>
|
||||
<WrapPanel ItemSpacing="10" LineSpacing="10">
|
||||
<Button Command="{Binding OnClickInstallOrUpdateUserscript}">Install or Update Userscript</Button>
|
||||
<Button x:Name="CopyConnectionCode" Click="CopyConnectionScriptButton_OnClick">Copy Connection Code</Button>
|
||||
</WrapPanel>
|
||||
|
@ -1,8 +1,8 @@
|
||||
/**
|
||||
* Parts copied from Better Discord, licensed under Apache License 2.0.
|
||||
*
|
||||
* https://github.com/BetterDiscord/BetterDiscord/blob/78edeb77c60542a57884686c4ba98f997c886fad/renderer/src/modules/webpackmodules.js
|
||||
* https://github.com/BetterDiscord/BetterDiscord/blob/78edeb77c60542a57884686c4ba98f997c886fad/LICENSE
|
||||
* https://github.com/BetterDiscord/BetterDiscord/blob/2752daf64f98625fc67c569361bd56021307d058/renderer/src/modules/webpackmodules.js
|
||||
* https://github.com/BetterDiscord/BetterDiscord/blob/2752daf64f98625fc67c569361bd56021307d058/LICENSE
|
||||
*/
|
||||
class WEBPACK {
|
||||
static get require() {
|
||||
@ -17,13 +17,15 @@ class WEBPACK {
|
||||
*/
|
||||
let hookedRequire;
|
||||
|
||||
const id = "dht-webpackmodules-" + new Date().getTime();
|
||||
const id = Symbol("dht-webpackmodules-" + new Date().getTime());
|
||||
if (typeof (window["webpackChunkdiscord_app"]) !== "undefined") {
|
||||
window["webpackChunkdiscord_app"].push([ [ id ], {}, internalRequire => hookedRequire = internalRequire ]);
|
||||
window["webpackChunkdiscord_app"].push([ [ id ], {}, internalRequire => {
|
||||
if ("b" in internalRequire) {
|
||||
hookedRequire = internalRequire;
|
||||
}
|
||||
}]);
|
||||
}
|
||||
|
||||
delete hookedRequire.m[id];
|
||||
delete hookedRequire.c[id];
|
||||
return this._require = hookedRequire;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user