diff options
author | sr55 <[email protected]> | 2017-09-22 22:54:41 +0100 |
---|---|---|
committer | sr55 <[email protected]> | 2017-09-22 22:54:41 +0100 |
commit | 2123622dd5ac13ee4c600e5987d1e081d8ab7c26 (patch) | |
tree | fa34ccb11c528b97c7d2dc0d8efcf8096ae77785 /win | |
parent | 2b6a2d0478029c0f37169f25f236f040bba09dcb (diff) |
WinGui: Code tidyup / tweaks around presets.
Diffstat (limited to 'win')
-rw-r--r-- | win/CS/HandBrakeWPF/Converters/PresetsMenuConverter.cs | 2 | ||||
-rw-r--r-- | win/CS/HandBrakeWPF/Views/MainView.xaml | 45 |
2 files changed, 4 insertions, 43 deletions
diff --git a/win/CS/HandBrakeWPF/Converters/PresetsMenuConverter.cs b/win/CS/HandBrakeWPF/Converters/PresetsMenuConverter.cs index bbcfd891d..d3a114376 100644 --- a/win/CS/HandBrakeWPF/Converters/PresetsMenuConverter.cs +++ b/win/CS/HandBrakeWPF/Converters/PresetsMenuConverter.cs @@ -79,6 +79,7 @@ namespace HandBrakeWPF.Converters if (preset.IsDefault) { newMeuItem.FontStyle = FontStyles.Italic; + newMeuItem.FontSize = 14; } groupedMenu[preset.Category].Items.Add(newMeuItem); @@ -92,6 +93,7 @@ namespace HandBrakeWPF.Converters if (preset.IsDefault) { newMeuItem.FontStyle = FontStyles.Italic; + newMeuItem.FontSize = 14; } group.Items.Add(newMeuItem); diff --git a/win/CS/HandBrakeWPF/Views/MainView.xaml b/win/CS/HandBrakeWPF/Views/MainView.xaml index 06e1904f4..89fcb3830 100644 --- a/win/CS/HandBrakeWPF/Views/MainView.xaml +++ b/win/CS/HandBrakeWPF/Views/MainView.xaml @@ -22,7 +22,6 @@ <Style TargetType="Button">
<Setter Property="Padding" Value="8,2" />
- <Setter Property="FontSize" Value="11.5" />
<Setter Property="VerticalAlignment" Value="Center" />
<Setter Property="MinHeight" Value="22" />
</Style>
@@ -360,50 +359,10 @@ </Button.Content>
<Button.ContextMenu>
- <ContextMenu x:Name="PresetSelectContextMenu"
- PlacementRectangle="{Binding RelativeSource={RelativeSource Self}}"
- ItemsSource="{Binding PresetsCategories, Converter={StaticResource presetsMenuConverter}}">
+ <ContextMenu x:Name="PresetSelectContextMenu" ItemsSource="{Binding PresetsCategories, Converter={StaticResource presetsMenuConverter}}">
</ContextMenu>
</Button.ContextMenu>
</Button>
-
- <!--<ComboBox ItemsSource="{Binding PresetsCategories}" SelectedItem="{Binding SelectedPresetCategory}" Width="150" DisplayMemberPath="Category" Margin="5,0,0,0" VerticalAlignment="Center" />
- <ComboBox ItemsSource="{Binding CategoryPresets}" SelectedItem="{Binding SelectedPreset}" Width="250" Margin="10,0,0,0" VerticalAlignment="Center">
- <ComboBox.Resources>
- <Style TargetType="ToolTip">
- <Style.Resources>
- <Style TargetType="ContentPresenter">
- <Style.Resources>
- <Style TargetType="TextBlock">
- <Setter Property="TextWrapping" Value="Wrap" />
- </Style>
- </Style.Resources>
- </Style>
- </Style.Resources>
- <Setter Property="MaxWidth" Value="400" />
- </Style>
- </ComboBox.Resources>
-
- <ComboBox.ItemTemplate>
- <DataTemplate>
- <StackPanel Orientation="Horizontal" ToolTip="{Binding Description}" ToolTipService.InitialShowDelay="1500">
- <StackPanel.Resources>
- <Style TargetType="TextBlock">
- <Setter Property="FontStyle" Value="Normal" />
- <Style.Triggers>
- <DataTrigger Binding="{Binding Path=IsDefault}" Value="True">
- <Setter Property="FontStyle" Value="Italic" />
- </DataTrigger>
- </Style.Triggers>
- </Style>
-
- </StackPanel.Resources>
- <TextBlock Text="{Binding Name}" />
- <TextBlock Text="(Default)" Visibility="{Binding IsDefault, Converter={StaticResource boolToVisConverter}}" Margin="5,0,0,0" />
- </StackPanel>
- </DataTemplate>
- </ComboBox.ItemTemplate>
- </ComboBox>-->
<Button Content="Reload" cal:Message.Attach="[Event Click] = [Action PresetSelect]" Margin="15,0,0,0" VerticalAlignment="Center" />
<Button Content="Save Custom Preset" cal:Message.Attach="[Event Click] = [Action PresetAdd]" Margin="5,0,0,0" VerticalAlignment="Center" />
@@ -422,7 +381,7 @@ </Button.Content>
<Button.ContextMenu>
- <ContextMenu x:Name="MainContextMenu" PlacementRectangle="{Binding RelativeSource={RelativeSource Self}}">
+ <ContextMenu x:Name="MainContextMenu">
<MenuItem Header="{x:Static Properties:ResourcesUI.MainView_SetDefault}" cal:Message.Attach="[Event Click] = [Action PresetSetDefault]" />
<Separator />
<MenuItem Header="{x:Static Properties:ResourcesUI.MainView_UpdateSelectedPreset}" cal:Message.Attach="[Event Click] = [Action PresetUpdate]" />
|