116 lines
7.5 KiB
XML
116 lines
7.5 KiB
XML
<ResourceDictionary
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:controls="using:TheXamlGuy.TaskbarGroup.Flyout.Controls">
|
|
<ResourceDictionary.ThemeDictionaries>
|
|
<ResourceDictionary x:Key="Default">
|
|
<AcrylicBrush
|
|
x:Key="AcrylicBackgroundFillColorBrush"
|
|
BackgroundSource="HostBackdrop"
|
|
FallbackColor="#2C2C2C"
|
|
TintColor="#2C2C2C"
|
|
TintOpacity="0.8" />
|
|
<StaticResource x:Key="TaskbarButtonFlyoutBorderBrush" ResourceKey="SurfaceStrokeColorDefaultBrush" />
|
|
<StaticResource x:Key="TaskbarButtonFlyoutBackgroundBrush" ResourceKey="AcrylicBackgroundFillColorBrush" />
|
|
<Thickness x:Key="TaskbarButtonFlyoutBorderWidth">1</Thickness>
|
|
</ResourceDictionary>
|
|
<ResourceDictionary x:Key="Light">
|
|
<AcrylicBrush
|
|
x:Key="AcrylicBackgroundFillColorBrush"
|
|
BackgroundSource="HostBackdrop"
|
|
FallbackColor="#F9F9F9"
|
|
TintColor="#FCFCFC"
|
|
TintOpacity="0.8" />
|
|
<StaticResource x:Key="TaskbarButtonFlyoutBorderBrush" ResourceKey="SurfaceStrokeColorDefaultBrush" />
|
|
<StaticResource x:Key="TaskbarButtonFlyoutBackgroundBrush" ResourceKey="AcrylicBackgroundFillColorBrush" />
|
|
<Thickness x:Key="TaskbarButtonFlyoutBorderWidth">1</Thickness>
|
|
</ResourceDictionary>
|
|
</ResourceDictionary.ThemeDictionaries>
|
|
<AcrylicBrush
|
|
x:Key="NotificationFlyoutPresenterBackgroundAccentBrush"
|
|
BackgroundSource="HostBackdrop"
|
|
FallbackColor="{ThemeResource SystemAccentColorDark1}"
|
|
TintColor="{ThemeResource SystemAccentColorDark1}"
|
|
TintOpacity="0.8" />
|
|
<Style TargetType="controls:TaskbarButtonFlyout">
|
|
<Setter Property="BorderThickness" Value="{ThemeResource TaskbarButtonFlyoutBorderWidth}" />
|
|
<Setter Property="BorderBrush" Value="{ThemeResource TaskbarButtonFlyoutBorderBrush}" />
|
|
<Setter Property="Background" Value="{ThemeResource TaskbarButtonFlyoutBackgroundBrush}" />
|
|
<Setter Property="CornerRadius" Value="{ThemeResource OverlayCornerRadius}" />
|
|
<Setter Property="HorizontalContentAlignment" Value="Stretch" />
|
|
<Setter Property="VerticalContentAlignment" Value="Stretch" />
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="controls:TaskbarButtonFlyout">
|
|
<Border x:Name="Container" Margin="{TemplateBinding Margin}">
|
|
<Grid x:Name="LayoutRoot">
|
|
<Border
|
|
x:Name="BackgroundElement"
|
|
HorizontalAlignment="Stretch"
|
|
VerticalAlignment="Stretch"
|
|
Background="{TemplateBinding Background}"
|
|
BackgroundSizing="OuterBorderEdge"
|
|
BorderBrush="{TemplateBinding BorderBrush}"
|
|
BorderThickness="{TemplateBinding BorderThickness}"
|
|
CornerRadius="{TemplateBinding CornerRadius}">
|
|
<Border.Transitions>
|
|
<TransitionCollection>
|
|
<EntranceThemeTransition x:Name="EntranceThemeTransition" />
|
|
</TransitionCollection>
|
|
</Border.Transitions>
|
|
<Grid>
|
|
<ContentControl
|
|
x:Name="ContentPresenter"
|
|
Margin="{TemplateBinding Padding}"
|
|
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"
|
|
VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}"
|
|
Content="{TemplateBinding Content}"
|
|
ContentTemplate="{TemplateBinding ContentTemplate}"
|
|
ContentTransitions="{TemplateBinding ContentTransitions}" />
|
|
</Grid>
|
|
</Border>
|
|
</Grid>
|
|
<VisualStateManager.VisualStateGroups>
|
|
<VisualStateGroup x:Name="PlacementStates">
|
|
<VisualState x:Name="DefaultPlacement" />
|
|
<VisualState x:Name="BottomPlacement">
|
|
<VisualState.Setters>
|
|
<Setter Target="EntranceThemeTransition.FromHorizontalOffset" Value="0" />
|
|
<Setter Target="EntranceThemeTransition.FromVerticalOffset" Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.Height}" />
|
|
</VisualState.Setters>
|
|
</VisualState>
|
|
<VisualState x:Name="TopPlacement">
|
|
<VisualState.Setters>
|
|
<Setter Target="EntranceThemeTransition.FromHorizontalOffset" Value="0" />
|
|
<Setter Target="EntranceThemeTransition.FromVerticalOffset" Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.NegativeHeight}" />
|
|
</VisualState.Setters>
|
|
</VisualState>
|
|
<VisualState x:Name="LeftPlacement">
|
|
<VisualState.Setters>
|
|
<Setter Target="EntranceThemeTransition.FromHorizontalOffset" Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.NegativeWidth}" />
|
|
<Setter Target="EntranceThemeTransition.FromVerticalOffset" Value="0" />
|
|
</VisualState.Setters>
|
|
</VisualState>
|
|
<VisualState x:Name="RightPlacement">
|
|
<VisualState.Setters>
|
|
<Setter Target="EntranceThemeTransition.FromHorizontalOffset" Value="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=TemplateSettings.Width}" />
|
|
<Setter Target="EntranceThemeTransition.FromVerticalOffset" Value="0" />
|
|
</VisualState.Setters>
|
|
</VisualState>
|
|
</VisualStateGroup>
|
|
<VisualStateGroup x:Name="ThemeStates">
|
|
<VisualState x:Name="DefaultTheme" />
|
|
<VisualState x:Name="ColorPrevalenceTheme">
|
|
<VisualState.Setters>
|
|
<Setter Target="BackgroundElement.Background" Value="{ThemeResource TaskbarButtonFlyoutPresenterBackgroundBrush}" />
|
|
</VisualState.Setters>
|
|
</VisualState>
|
|
</VisualStateGroup>
|
|
</VisualStateManager.VisualStateGroups>
|
|
</Border>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
</ResourceDictionary>
|