mirror of
https://github.com/yaobiao131/downkyicore.git
synced 2025-08-10 00:52:31 +00:00
fix: 修复ui上的问题
This commit is contained in:
@@ -104,19 +104,6 @@
|
||||
FontSize="12"
|
||||
Foreground="{DynamicResource BrushTextDark}"
|
||||
Text="{Binding StringFormat={} {0}, Path=DownloadStatusTitle}">
|
||||
|
||||
<!--<TextBlock.Style>
|
||||
<Style TargetType="{x:Type TextBlock}">
|
||||
<Setter Property="Text"
|
||||
Value="{Binding StringFormat={} {0}, Path=DownloadStatusTitle}" />
|
||||
<Style.Triggers>
|
||||
<DataTrigger Binding="{Binding DownloadContent}" Value="">
|
||||
<Setter Property="Text"
|
||||
Value="{Binding DownloadStatusTitle}" />
|
||||
</DataTrigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</TextBlock.Style>-->
|
||||
<i:Interaction.Behaviors>
|
||||
<ia:DataTriggerBehavior Binding="{Binding DownloadContent}"
|
||||
Value="">
|
||||
|
||||
@@ -6,7 +6,8 @@
|
||||
xmlns:prism="http://prismlibrary.com/"
|
||||
prism:ViewModelLocator.AutoWireViewModel="True"
|
||||
xmlns:i="using:Avalonia.Xaml.Interactivity"
|
||||
xmlns:ia="clr-namespace:Avalonia.Xaml.Interactions.Core;assembly=Avalonia.Xaml.Interactions">
|
||||
xmlns:ia="clr-namespace:Avalonia.Xaml.Interactions.Core;assembly=Avalonia.Xaml.Interactions"
|
||||
xmlns:iac="clr-namespace:DownKyi.CustomAction">
|
||||
<ScrollViewer>
|
||||
<StackPanel Margin="50,0" Orientation="Vertical">
|
||||
<StackPanel Margin="0,20,0,0" Orientation="Horizontal">
|
||||
@@ -17,7 +18,7 @@
|
||||
</StackPanel>
|
||||
|
||||
<CheckBox
|
||||
Name="nameUseSSL"
|
||||
Name="NameUseSsl"
|
||||
Margin="0,20,0,0"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Top"
|
||||
@@ -26,7 +27,7 @@
|
||||
FontSize="12"
|
||||
Foreground="{DynamicResource BrushTextDark}"
|
||||
IsChecked="{Binding UseSSL, Mode=TwoWay}"
|
||||
Theme="{StaticResource CheckBoxStyle}"/>
|
||||
Theme="{StaticResource CheckBoxStyle}" />
|
||||
|
||||
<TextBlock
|
||||
Margin="0,20,0,0"
|
||||
@@ -35,11 +36,18 @@
|
||||
Text="{DynamicResource UserAgent}" />
|
||||
|
||||
<TextBox
|
||||
Name="nameUserAgent"
|
||||
Name="NameUserAgent"
|
||||
Height="25"
|
||||
Margin="0,10,0,0"
|
||||
HorizontalAlignment="Stretch"
|
||||
Text="{Binding UserAgent}"/>
|
||||
Text="{Binding UserAgent}">
|
||||
<i:Interaction.Behaviors>
|
||||
<iac:KeyUpBehavior Key="Enter">
|
||||
<ia:InvokeCommandAction Command="{Binding UserAgentCommand}"
|
||||
CommandParameter="{Binding ElementName=NameUserAgent,Path=Text}" />
|
||||
</iac:KeyUpBehavior>
|
||||
</i:Interaction.Behaviors>
|
||||
</TextBox>
|
||||
|
||||
<StackPanel Margin="0,20,0,0" Orientation="Vertical">
|
||||
<TextBlock
|
||||
@@ -80,7 +88,7 @@
|
||||
Margin="0,20,0,0"
|
||||
Background="{DynamicResource BrushBorder}" />
|
||||
|
||||
<StackPanel x:Name="nameBuiltin">
|
||||
<StackPanel x:Name="NameBuiltin">
|
||||
<i:Interaction.Behaviors>
|
||||
<ia:DataTriggerBehavior Binding="{Binding Builtin}" Value="True">
|
||||
<ia:ChangePropertyAction PropertyName="IsVisible" Value="True" />
|
||||
@@ -97,7 +105,7 @@
|
||||
Foreground="{DynamicResource BrushTextDark}"
|
||||
Text="{DynamicResource MaxCurrentDownloads}" />
|
||||
<ComboBox
|
||||
Name="nameMaxCurrentDownloads"
|
||||
Name="NameMaxCurrentDownloads"
|
||||
Width="100"
|
||||
VerticalContentAlignment="Center"
|
||||
ItemsSource="{Binding MaxCurrentDownloads}"
|
||||
@@ -105,7 +113,7 @@
|
||||
<i:Interaction.Behaviors>
|
||||
<ia:EventTriggerBehavior EventName="SelectionChanged">
|
||||
<ia:InvokeCommandAction Command="{Binding MaxCurrentDownloadsCommand}"
|
||||
CommandParameter="{Binding ElementName=nameMaxCurrentDownloads, Path=SelectedValue}" />
|
||||
CommandParameter="{Binding ElementName=NameMaxCurrentDownloads, Path=SelectedValue}" />
|
||||
</ia:EventTriggerBehavior>
|
||||
</i:Interaction.Behaviors>
|
||||
</ComboBox>
|
||||
@@ -119,7 +127,7 @@
|
||||
Foreground="{DynamicResource BrushTextDark}"
|
||||
Text="{DynamicResource Split}" />
|
||||
<ComboBox
|
||||
Name="nameSplits"
|
||||
Name="NameSplits"
|
||||
Width="100"
|
||||
VerticalContentAlignment="Center"
|
||||
ItemsSource="{Binding Splits}"
|
||||
@@ -127,14 +135,14 @@
|
||||
<i:Interaction.Behaviors>
|
||||
<ia:EventTriggerBehavior EventName="SelectionChanged">
|
||||
<ia:InvokeCommandAction Command="{Binding SplitsCommand}"
|
||||
CommandParameter="{Binding ElementName=nameSplits, Path=SelectedValue}" />
|
||||
CommandParameter="{Binding ElementName=NameSplits, Path=SelectedValue}" />
|
||||
</ia:EventTriggerBehavior>
|
||||
</i:Interaction.Behaviors>
|
||||
</ComboBox>
|
||||
</StackPanel>
|
||||
|
||||
<CheckBox
|
||||
Name="nameIsHttpProxy"
|
||||
Name="NameIsHttpProxy"
|
||||
Margin="0,20,0,0"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Top"
|
||||
|
||||
@@ -286,15 +286,82 @@
|
||||
BorderThickness="1"
|
||||
BorderBrush="Gray"
|
||||
CanUserSortColumns="False"
|
||||
CanUserResizeColumns="True"
|
||||
IsReadOnly="True"
|
||||
ItemsSource="{ReflectionBinding ElementName=NameVideoSections,Path=SelectedItem.VideoPages,Mode=TwoWay}"
|
||||
SelectionMode="Extended">
|
||||
<DataGrid.ColumnHeaderTheme>
|
||||
<ControlTheme TargetType="{x:Type DataGridColumnHeader}">
|
||||
<Setter Property="Background" Value="{DynamicResource BrushHeaderGrey}" />
|
||||
<Setter Property="HorizontalContentAlignment" Value="Center"></Setter>
|
||||
<Setter Property="VerticalContentAlignment" Value="Center"></Setter>
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type DataGridColumnHeader}">
|
||||
<Grid>
|
||||
<Border
|
||||
x:Name="HeaderBorder"
|
||||
Height="30"
|
||||
Background="{TemplateBinding Background}"
|
||||
BorderBrush="{TemplateBinding BorderBrush}">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition MaxHeight="10" />
|
||||
<RowDefinition />
|
||||
</Grid.RowDefinitions>
|
||||
<Border Grid.RowSpan="2" Padding="{TemplateBinding Padding}">
|
||||
<ContentPresenter
|
||||
x:Name="HeaderContent"
|
||||
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
|
||||
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
|
||||
Content="{TemplateBinding Content}"
|
||||
ContentTemplate="{TemplateBinding ContentTemplate}"
|
||||
RecognizesAccessKey="True" />
|
||||
</Border>
|
||||
</Grid>
|
||||
</Border>
|
||||
<Canvas>
|
||||
<Thumb x:Name="PART_HeaderGripper">
|
||||
<Thumb.Theme>
|
||||
<ControlTheme TargetType="{x:Type Thumb}">
|
||||
<Setter Property="Canvas.Right" Value="-9" />
|
||||
<Setter Property="Width" Value="18" />
|
||||
<Setter Property="Height"
|
||||
Value="{Binding Bounds.Size.Height, RelativeSource={RelativeSource TemplatedParent}}" />
|
||||
<Setter Property="Padding" Value="0" />
|
||||
<Setter Property="Background" Value="White" />
|
||||
<Setter Property="Template">
|
||||
<Setter.Value>
|
||||
<ControlTemplate TargetType="{x:Type Thumb}">
|
||||
<Border Padding="{TemplateBinding Padding}"
|
||||
Background="Transparent">
|
||||
<Rectangle
|
||||
Width="1"
|
||||
HorizontalAlignment="Center"
|
||||
Fill="{TemplateBinding Background}" />
|
||||
</Border>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</ControlTheme>
|
||||
</Thumb.Theme>
|
||||
</Thumb>
|
||||
</Canvas>
|
||||
</Grid>
|
||||
</ControlTemplate>
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</ControlTheme>
|
||||
</DataGrid.ColumnHeaderTheme>
|
||||
<i:Interaction.Behaviors>
|
||||
<ia:EventTriggerBehavior EventName="SelectionChanged">
|
||||
<ia:InvokeCommandAction Command="{Binding VideoPagesCommand}"
|
||||
CommandParameter="{Binding ElementName=NameVideoPages1,Path=SelectedItems}" />
|
||||
</ia:EventTriggerBehavior>
|
||||
</i:Interaction.Behaviors>
|
||||
<DataGrid.RowTheme>
|
||||
|
||||
</DataGrid.RowTheme>
|
||||
<DataGrid.Columns>
|
||||
<DataGridTextColumn
|
||||
Width="50"
|
||||
@@ -386,6 +453,11 @@
|
||||
Watermark="{DynamicResource SearchVideoByName}"
|
||||
Text="{Binding Path=InputSearchText, Mode=TwoWay}"
|
||||
TextWrapping="Wrap">
|
||||
<i:Interaction.Behaviors>
|
||||
<iac:KeyUpBehavior Key="Enter">
|
||||
<ia:InvokeCommandAction Command="{Binding InputSearchCommand}" />
|
||||
</iac:KeyUpBehavior>
|
||||
</i:Interaction.Behaviors>
|
||||
</TextBox>
|
||||
<Button
|
||||
Grid.Column="4"
|
||||
|
||||
Reference in New Issue
Block a user