mirror of
https://github.com/QL-Win/QuickLook.git
synced 2025-09-07 13:38:00 +00:00
Fix windows timer resolution
This commit is contained in:
@@ -31,7 +31,7 @@ namespace QuickLook.Common.Plugin
|
||||
{
|
||||
private bool _canResize = true;
|
||||
private bool _fullWindowDragging;
|
||||
private bool _isBusy = true;
|
||||
private bool _isBusy;
|
||||
private string _title = string.Empty;
|
||||
private bool _titlebarAutoHide;
|
||||
private bool _titlebarBlurVisibility;
|
||||
@@ -207,7 +207,8 @@ namespace QuickLook.Common.Plugin
|
||||
public void Reset()
|
||||
{
|
||||
Title = string.Empty;
|
||||
IsBusy = true;
|
||||
// set to False to prevent showing loading icon
|
||||
IsBusy = false;
|
||||
PreferredSize = new Size();
|
||||
CanResize = true;
|
||||
FullWindowDragging = false;
|
||||
|
@@ -70,7 +70,7 @@ namespace QuickLook.Controls.BusyDecorator
|
||||
{
|
||||
GC.SuppressFinalize(this);
|
||||
|
||||
_busyHost.ThreadedHelper.Exit();
|
||||
_busyHost.ThreadedHelper?.Exit();
|
||||
}
|
||||
|
||||
protected override Visual GetVisualChild(int index)
|
||||
|
@@ -152,35 +152,12 @@
|
||||
<ContentControl x:Name="container"
|
||||
Foreground="{DynamicResource WindowTextForeground}"
|
||||
Content="{Binding ContextObject.ViewerContent, ElementName=mainWindow}" />
|
||||
<DockPanel.Style>
|
||||
<Style TargetType="{x:Type DockPanel}">
|
||||
<Setter Property="Visibility" Value="Visible" />
|
||||
<Style.Triggers>
|
||||
<DataTrigger
|
||||
Binding="{Binding ContextObject.IsBusy, ElementName=mainWindow}"
|
||||
Value="True">
|
||||
<Setter Property="Visibility" Value="Hidden" />
|
||||
</DataTrigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</DockPanel.Style>
|
||||
</DockPanel>
|
||||
</Grid>
|
||||
<Grid x:Name="busyIndicatorLayer" ZIndex="200">
|
||||
<Grid.Style>
|
||||
<Style TargetType="{x:Type Grid}">
|
||||
<Setter Property="Visibility" Value="Collapsed" />
|
||||
<Style.Triggers>
|
||||
<DataTrigger
|
||||
Binding="{Binding ContextObject.IsBusy, ElementName=mainWindow}"
|
||||
Value="True">
|
||||
<Setter Property="Visibility" Value="Visible" />
|
||||
</DataTrigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</Grid.Style>
|
||||
<Grid x:Name="busyIndicatorLayer" ZIndex="200"
|
||||
Visibility="{Binding ElementName=mainWindow, Path=ContextObject.IsBusy, Converter={StaticResource BooleanToVisibilityConverter}}">
|
||||
<busyDecorator:BusyDecorator x:Name="busyDecorator"
|
||||
IsBusyIndicatorShowing="True"
|
||||
IsBusyIndicatorShowing="{Binding ElementName=mainWindow, Path=ContextObject.IsBusy}"
|
||||
VerticalAlignment="Center"
|
||||
HorizontalAlignment="Center" />
|
||||
</Grid>
|
||||
|
Reference in New Issue
Block a user