Fix #166: hide controls from beginning

This commit is contained in:
Paddy Xu
2018-06-23 16:39:32 +03:00
parent c771c72017
commit 2743a83e27
5 changed files with 24 additions and 3 deletions

View File

@@ -80,6 +80,7 @@ namespace QuickLook.Plugin.VideoViewer
else
{
context.TitlebarAutoHide = true;
context.Theme = Themes.Dark;
context.TitlebarBlurVisibility = true;
}
}

View File

@@ -90,6 +90,16 @@
</Grid>
<Grid x:Name="videoControlContainer" HorizontalAlignment="Stretch" VerticalAlignment="Bottom" Height="32">
<Grid.Style>
<Style TargetType="Grid">
<Setter Property="Opacity" Value="1" />
<Style.Triggers>
<DataTrigger Binding="{Binding HasVideo, ElementName=viewerPanel}" Value="True">
<Setter Property="Opacity" Value="0" />
</DataTrigger>
</Style.Triggers>
</Style>
</Grid.Style>
<Grid.Resources>
<Storyboard x:Key="ShowControlStoryboard" Completed="AutoHideViedoControlContainer">
<DoubleAnimation

View File

@@ -60,7 +60,7 @@ namespace QuickLook.Plugin.VideoViewer
// apply global theme
Resources.MergedDictionaries[0].MergedDictionaries.Clear();
ShowViedoControlContainer(null, null);
//ShowViedoControlContainer(null, null);
viewerPanel.PreviewMouseMove += ShowViedoControlContainer;
mediaElement.PropertyChanged += PlayerPropertyChanged;