<!--
	Copyright (c) Microsoft. All rights reserved.
-->

<UserControl x:Class="MOX.TooltipFlyout"
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
	xmlns:vsm='using:Windows.UI.Xaml'
	xmlns:mox="using:MOX"
	>
	<UserControl.Resources>
		<Storyboard x:Name="storyboardTooltipPulse">
			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Border">
				<EasingDoubleKeyFrame KeyTime="0" Value="1"/>
				<EasingDoubleKeyFrame KeyTime="0:0:0.5" Value="1"/>
				<EasingDoubleKeyFrame KeyTime="0:0:0.65" Value="0"/>
			</DoubleAnimationUsingKeyFrames>
		</Storyboard>
		<Storyboard x:Name="storyboardTooltipShowDelayed">
			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="Border">
				<EasingDoubleKeyFrame KeyTime="0" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:5" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:5.5" Value="1"/>
			</DoubleAnimationUsingKeyFrames>
		</Storyboard>
	</UserControl.Resources>
	<Border x:Name="Border"
		Background="#FFFFFFFF"
		BorderBrush="#FF808080"
		BorderThickness="2"
		HorizontalAlignment="Left"
		VerticalAlignment="Top"
		CornerRadius="0"
		MinWidth="30"
		MinHeight="20"
		MaxWidth="380"
		Padding="10,6,10,7"
		IsHitTestVisible="false"
		>
		<StackPanel Orientation="Horizontal" Margin="1" HorizontalAlignment="Center" VerticalAlignment="Center">
			<Image
				x:Name="Image"
				Width="30"
				Height="30"
				Stretch="None"
				Margin="0,0,30,0"
				VerticalAlignment="Center"
				Visibility="Collapsed"
				>
				<Image.Source>
					<mox:SmartImageSource Tcid="{Binding TcidImage, Mode=OneWay}" />
				</Image.Source>
			</Image>
			<TextBlock
				x:Name="Text"
				HorizontalAlignment="Center"
				VerticalAlignment="Center"
				Margin="0"
				Style="{StaticResource MsoTextBlockSmall}"
				Foreground="#FF666666"
				Text="{Binding Tooltip, Mode=OneWay}"
				/>
		</StackPanel>
	</Border>
</UserControl>
