зеркало из https://github.com/DeGsoft/maui-linux.git
133 строки
6.8 KiB
XML
133 строки
6.8 KiB
XML
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:controls="clr-namespace:Xamarin.Forms.Platform.WPF.Controls">
|
|
|
|
<Style x:Key="FocusVisual">
|
|
<Setter Property="Control.Template">
|
|
<Setter.Value>
|
|
<ControlTemplate>
|
|
<Rectangle Margin="2"
|
|
SnapsToDevicePixels="true"
|
|
Stroke="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}"
|
|
StrokeThickness="1"
|
|
StrokeDashArray="1 2" />
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
|
|
<Style x:Key="NavigationButtonStyle"
|
|
TargetType="{x:Type RepeatButton}">
|
|
<Setter Property="FocusVisualStyle"
|
|
Value="{StaticResource FocusVisual}" />
|
|
<Setter Property="Foreground"
|
|
Value="#FF636161" />
|
|
<Setter Property="BorderThickness"
|
|
Value="1" />
|
|
<Setter Property="HorizontalContentAlignment"
|
|
Value="Center" />
|
|
<Setter Property="VerticalContentAlignment"
|
|
Value="Center" />
|
|
<Setter Property="Padding"
|
|
Value="1" />
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type RepeatButton}">
|
|
<Grid>
|
|
<Border x:Name="border"
|
|
SnapsToDevicePixels="true"
|
|
Background="#FFAAA4A4"
|
|
Opacity="0.79" />
|
|
<ContentPresenter x:Name="contentPresenter"
|
|
Focusable="False"
|
|
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
|
|
Margin="{TemplateBinding Padding}"
|
|
RecognizesAccessKey="True"
|
|
SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
|
|
VerticalAlignment="{TemplateBinding VerticalContentAlignment}" />
|
|
</Grid>
|
|
<ControlTemplate.Triggers>
|
|
<Trigger Property="IsMouseOver"
|
|
Value="true">
|
|
<Setter Property="Background"
|
|
TargetName="border"
|
|
Value="#FFCDCBCB" />
|
|
</Trigger>
|
|
<Trigger Property="IsPressed"
|
|
Value="true">
|
|
<Setter Property="Background"
|
|
TargetName="border"
|
|
Value="#FF272727" />
|
|
<Setter Property="TextElement.Foreground"
|
|
Value="White" />
|
|
</Trigger>
|
|
<Trigger Property="IsEnabled"
|
|
Value="false">
|
|
<Setter Property="Visibility"
|
|
Value="Collapsed" />
|
|
</Trigger>
|
|
</ControlTemplate.Triggers>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
<Setter Property="Width"
|
|
Value="75" />
|
|
<Setter Property="Height"
|
|
Value="40" />
|
|
</Style>
|
|
|
|
<Style TargetType="{x:Type controls:FormsCarouselPage}">
|
|
<Setter Property="TitleBarBackgroundColor" Value="{DynamicResource DefaultTitleBarBackgroundColor}"/>
|
|
<Setter Property="TitleBarTextColor" Value="{DynamicResource DefaultTitleBarTextColor}"/>
|
|
<Setter Property="Template">
|
|
<Setter.Value>
|
|
<ControlTemplate TargetType="{x:Type controls:FormsCarouselPage}">
|
|
<Border Background="{TemplateBinding Background}"
|
|
BorderBrush="{TemplateBinding BorderBrush}"
|
|
BorderThickness="{TemplateBinding BorderThickness}">
|
|
<Grid ClipToBounds="True"
|
|
x:Name="PART_Container">
|
|
|
|
<controls:FormsTransitioningContentControl x:Name="PART_Multi_Content"
|
|
Transition="Left"
|
|
ContentLoader="{TemplateBinding ContentLoader}"
|
|
Source="{TemplateBinding SelectedItem}" />
|
|
|
|
<Grid VerticalAlignment="Center"
|
|
x:Name="PART_ButtonPanel"
|
|
Visibility="Collapsed">
|
|
<RepeatButton x:Name="PART_NextButton"
|
|
FontFamily="Segoe UI Symbol"
|
|
Content=""
|
|
FontSize="18"
|
|
Style="{StaticResource NavigationButtonStyle}"
|
|
Command="{x:Static controls:FormsCarouselPage.NextCommand}"
|
|
HorizontalAlignment="Right" />
|
|
<RepeatButton x:Name="PART_PreviousButton"
|
|
FontFamily="Segoe UI Symbol"
|
|
Content=""
|
|
FontSize="18"
|
|
Style="{StaticResource NavigationButtonStyle}"
|
|
Command="{x:Static controls:FormsCarouselPage.PreviousCommand}"
|
|
HorizontalAlignment="Left" />
|
|
</Grid>
|
|
</Grid>
|
|
</Border>
|
|
<ControlTemplate.Triggers>
|
|
<MultiTrigger>
|
|
<MultiTrigger.Conditions>
|
|
<Condition Property="IsMouseOver"
|
|
Value="True" />
|
|
<Condition Property="IsStylusOver"
|
|
Value="False" />
|
|
</MultiTrigger.Conditions>
|
|
<Setter Property="Visibility"
|
|
Value="Visible"
|
|
TargetName="PART_ButtonPanel" />
|
|
</MultiTrigger>
|
|
</ControlTemplate.Triggers>
|
|
</ControlTemplate>
|
|
</Setter.Value>
|
|
</Setter>
|
|
</Style>
|
|
</ResourceDictionary> |