Skip to content

Commit fd97b30

Browse files
committed
修正 Slot 属性名
更新 NuGet 依赖
1 parent a877813 commit fd97b30

3 files changed

Lines changed: 8 additions & 23 deletions

File tree

WinGetStore/Controls/Slot.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ public Orientation Orientation
6666
/// <summary>
6767
/// Identifies the <see cref="PreviousElement"/> dependency property.
6868
/// </summary>
69-
public static readonly DependencyProperty LastControlProperty =
69+
public static readonly DependencyProperty PreviousElementProperty =
7070
DependencyProperty.Register(
7171
nameof(PreviousElement),
7272
typeof(FrameworkElement),
@@ -75,8 +75,8 @@ public Orientation Orientation
7575

7676
public FrameworkElement PreviousElement
7777
{
78-
get => (FrameworkElement)GetValue(LastControlProperty);
79-
set => SetValue(LastControlProperty, value);
78+
get => (FrameworkElement)GetValue(PreviousElementProperty);
79+
set => SetValue(PreviousElementProperty, value);
8080
}
8181

8282
#endregion

WinGetStore/Helpers/WindowHelper.cs

Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -57,27 +57,12 @@ public static void TrackWindow(this Window window)
5757
}
5858
}
5959

60-
public static Size GetXAMLRootSize(this UIElement element) =>
61-
IsXamlRootSupported && element.XamlRoot != null
62-
? element.XamlRoot.Size
63-
: Window.Current is Window window
64-
? window.Bounds.ToSize()
65-
: CoreApplication.MainView.CoreWindow.Bounds.ToSize();
66-
6760
public static UIElement GetXAMLRoot(this UIElement element) =>
68-
IsXamlRootSupported && element.XamlRoot != null
69-
? element.XamlRoot.Content
61+
IsXamlRootSupported && element.XamlRoot is XamlRoot xamlRoot
62+
? xamlRoot.Content
7063
: Window.Current is Window window
7164
? window.Content : null;
7265

73-
public static void SetXAMLRoot(this UIElement element, UIElement target)
74-
{
75-
if (IsXamlRootSupported)
76-
{
77-
element.XamlRoot = target?.XamlRoot;
78-
}
79-
}
80-
8166
public static Dictionary<CoreDispatcher, Window> ActiveWindows { get; } = [];
8267
}
8368
}

WinGetStore/WinGetStore.csproj

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,15 +22,15 @@
2222
</PropertyGroup>
2323

2424
<ItemGroup>
25-
<PackageReference Include="CommunityToolkit.Labs.Uwp.Controls.MarkdownTextBlock" Version="0.1.250609-build.2144" />
25+
<PackageReference Include="CommunityToolkit.Labs.Uwp.Controls.MarkdownTextBlock" Version="0.1.250731-build.2197" />
2626
<PackageReference Include="CommunityToolkit.Uwp.Converters" Version="8.2.250402" />
2727
<PackageReference Include="CommunityToolkit.Uwp.Extensions" Version="8.2.250402" />
2828
<PackageReference Include="CommunityToolkit.Uwp.Triggers" Version="8.2.250402" />
2929
<PackageReference Include="Karambolo.Extensions.Logging.File" Version="3.6.3" />
30-
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="9.0.6" />
30+
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="9.0.7" />
3131
<PackageReference Include="Microsoft.Toolkit.Uwp.Notifications" Version="7.1.3" />
3232
<PackageReference Include="Microsoft.UI.Xaml" Version="2.8.7" />
33-
<PackageReference Include="Microsoft.WindowsPackageManager.ComInterop" Version="1.10.340" />
33+
<PackageReference Include="Microsoft.WindowsPackageManager.ComInterop" Version="1.11.430" />
3434
<PackageReference Include="System.Drawing.Common" Version="8.0.14" IsImplicitlyDefined="True" />
3535
</ItemGroup>
3636

0 commit comments

Comments
 (0)