mirror of
https://github.com/QL-Win/QuickLook.git
synced 2025-12-24 02:00:55 +08:00
finish auto-hide
This commit is contained in:
@@ -9,7 +9,7 @@
|
||||
x:Name="imagePanel"
|
||||
d:DesignHeight="300" d:DesignWidth="300">
|
||||
<Grid>
|
||||
<Rectangle>
|
||||
<Rectangle Visibility="{Binding BackgroundVisibility, ElementName=imagePanel}">
|
||||
<Rectangle.Fill>
|
||||
<ImageBrush x:Name="backgroundBrush" ImageSource="Resources/background.png" AlignmentY="Top" Viewport="0,0,32,32"
|
||||
ViewportUnits="Absolute" Stretch="UniformToFill" TileMode="Tile" />
|
||||
|
||||
@@ -45,6 +45,7 @@ namespace QuickLook.Plugin.ImageViewer
|
||||
private BitmapScalingMode _renderMode = BitmapScalingMode.HighQuality;
|
||||
private BitmapSource _source;
|
||||
private double _zoomFactor = 1d;
|
||||
private Visibility _backgroundVisibility = Visibility.Visible;
|
||||
|
||||
private bool _zoomToFit = true;
|
||||
|
||||
@@ -88,6 +89,16 @@ namespace QuickLook.Plugin.ImageViewer
|
||||
}
|
||||
}
|
||||
|
||||
public Visibility BackgroundVisibility
|
||||
{
|
||||
get => _backgroundVisibility;
|
||||
set
|
||||
{
|
||||
_backgroundVisibility = value;
|
||||
OnPropertyChanged();
|
||||
}
|
||||
}
|
||||
|
||||
public double MinZoomFactor
|
||||
{
|
||||
get => _minZoomFactor;
|
||||
|
||||
@@ -64,8 +64,7 @@ namespace QuickLook.Plugin.ImageViewer
|
||||
context.PreferredSize = new Size(1024, 768);
|
||||
|
||||
Directory.SetCurrentDirectory(App.AppPath);
|
||||
|
||||
context.AutoHideTitlebar = true;
|
||||
|
||||
context.TitlebarOverlap = true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user