<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:charts="clr-namespace:Microsoft.Research.DynamicDataDisplay.Charts"
	xmlns:shapes="clr-namespace:Microsoft.Research.DynamicDataDisplay.Charts.Shapes"
	xmlns:navigation="clr-namespace:Microsoft.Research.DynamicDataDisplay.Charts.Navigation"
	xmlns:markup="clr-namespace:Microsoft.Research.DynamicDataDisplay.MarkupExtensions">

	<ResourceDictionary.MergedDictionaries>
		<ResourceDictionary Source="/DynamicDataDisplay;component/Charts/Legend items/LegendResources.xaml"/>
	</ResourceDictionary.MergedDictionaries>

	<!--Draggable Point-->
	<Style TargetType="{x:Type shapes:DraggablePoint}">
		<Style.Resources>
			<Storyboard x:Key="story">
				<DoubleAnimation Storyboard.TargetProperty="Opacity" 
									 From="1" 
									 To="0.1" Duration="0:0:0.4" AutoReverse="True"
									 RepeatBehavior="Forever"/>
			</Storyboard>
		</Style.Resources>

		<Setter Property="Focusable" Value="False"/>
		<Setter Property="Opacity" Value="1"/>
		<Setter Property="Cursor" Value="ScrollAll"/>
		<Setter Property="HorizontalContentAlignment" Value="Center"/>
		<Setter Property="VerticalContentAlignment" Value="Center"/>

		<Style.Triggers>
			<MultiTrigger>
				<MultiTrigger.Conditions>
					<Condition Property="IsMouseOver" Value="True"/>
					<Condition Property="IsMouseCaptured" Value="False"/>
				</MultiTrigger.Conditions>
				<MultiTrigger.EnterActions>
					<BeginStoryboard Name="storyboard" Storyboard="{StaticResource story}"/>
				</MultiTrigger.EnterActions>
				<MultiTrigger.ExitActions>
					<RemoveStoryboard BeginStoryboardName="storyboard"/>
				</MultiTrigger.ExitActions>
			</MultiTrigger>
		</Style.Triggers>
	</Style>

	<DropShadowEffect Direction="315" Opacity="0.4" ShadowDepth="4" x:Key="liveTooltipDefaultEffect"/>


	<!--LiveTooltip-->
	<Style TargetType="{x:Type charts:LiveToolTip}">
		<Setter Property="Template">
			<Setter.Value>
				<ControlTemplate TargetType="{x:Type charts:LiveToolTip}">
					<Grid>
						<Rectangle Fill="{TemplateBinding Background}"
								   Stroke="{TemplateBinding BorderBrush}"
								   StrokeThickness="{TemplateBinding BorderThickness}"
								   RadiusX="1" RadiusY="1" Opacity="{TemplateBinding Opacity}"
								   Effect="{markup:XbapConditionalExpression liveTooltipDefaultEffect}">
							<!--<Rectangle.Effect>
								<DropShadowEffect Direction="315" Opacity="0.4" ShadowDepth="4"/>
							</Rectangle.Effect>-->
						</Rectangle>
						<ContentPresenter Margin="5" Content="{TemplateBinding Content}"/>
					</Grid>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>

</ResourceDictionary>
