Skip to content

Commit 64a0714

Browse files
committed
Update package reference
1 parent 517e794 commit 64a0714

File tree

6 files changed

+11
-10
lines changed

6 files changed

+11
-10
lines changed

src/SwashbucklerDiary.Gtk/BlazorWebView/Gtk/GtkWebViewManager.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ private void ApplyDefaultWebViewSettings(BlazorWebViewDeveloperTools devTools)
170170
/// <exception cref="Exception"></exception>
171171
void HandleUriSchemeRequest(URISchemeRequest request)
172172
{
173-
if (!UriSchemeRequestHandlers.TryGetValue(request.GetWebView().Handle, out var uriSchemeHandler))
173+
if (!UriSchemeRequestHandlers.TryGetValue(request.GetWebView().Handle.DangerousGetHandle(), out var uriSchemeHandler))
174174
{
175175
throw new Exception($"Invalid scheme \"{request.GetScheme()}\"");
176176
}
@@ -215,9 +215,9 @@ void HandleUriSchemeRequest(URISchemeRequest request)
215215

216216
void RegisterUriSchemeRequestHandler()
217217
{
218-
if (!UriSchemeRequestHandlers.TryGetValue(_webview.Handle, out var uriSchemeHandler))
218+
if (!UriSchemeRequestHandlers.TryGetValue(_webview.Handle.DangerousGetHandle(), out var uriSchemeHandler))
219219
{
220-
UriSchemeRequestHandlers.Add(_webview.Handle, (_hostPageRelativePath, TryGetResponseContentInternal));
220+
UriSchemeRequestHandlers.Add(_webview.Handle.DangerousGetHandle(), (_hostPageRelativePath, TryGetResponseContentInternal));
221221
}
222222
}
223223

@@ -348,7 +348,7 @@ protected virtual void Detach()
348348
var userContentManager = _webview.GetUserContentManager();
349349
userContentManager.UnregisterScriptMessageHandler(MessageQueueId, null);
350350
userContentManager.RemoveScript(_script);
351-
UriSchemeRequestHandlers.Remove(_webview.Handle);
351+
UriSchemeRequestHandlers.Remove(_webview.Handle.DangerousGetHandle());
352352

353353
_detached = true;
354354
}

src/SwashbucklerDiary.Gtk/Essentials/AppLifecycle/AppActionsHelper.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ public static void AddMainOptionEntries(global::Gtk.Application application)
6464
entries.Add(new(){});
6565

6666
// Gio.Application Unencapsulated AddMainOptionEntries
67-
Gio.Internal.Application.AddMainOptionEntries(application.Handle, OptionEntryArrayOwnedHandle.Create(entries.ToArray()));
67+
Gio.Internal.Application.AddMainOptionEntries(application.Handle.DangerousGetHandle(), OptionEntryArrayOwnedHandle.Create(entries.ToArray()));
6868
}
6969
}
7070
}

src/SwashbucklerDiary.Gtk/Essentials/PlatformIntegration/Storage/Picker/PickFile.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public partial class PlatformIntegration
4242
for (uint i = 0; i < fileCount; i++)
4343
{
4444
nint fileValue = files.GetItem(i);
45-
var file = new Gio.FileHelper(fileValue, true);
45+
var file = new Gio.FileHelper(new(fileValue, true));
4646
string? filePath = file.GetPath();
4747

4848
if (PlatformIntegrationHelper.ValidFileExtension(filePath, fileExtensions))

src/SwashbucklerDiary.Gtk/Essentials/ThemeService/GtkSystemThemeManager.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,8 @@ private Theme GetCurrentSystemTheme()
3737
{
3838
var bus = DBusConnection.Get(BusType.Session);
3939
using var parameters = Variant.NewTuple([
40-
Variant.NewString("org.freedesktop.appearance"), Variant.NewString("color-scheme")
40+
Variant.NewString("org.freedesktop.appearance"),
41+
Variant.NewString("color-scheme")
4142
]);
4243

4344
using Variant ret = bus.CallSync(

src/SwashbucklerDiary.Gtk/MainWindow.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ public MainWindow(
2020
IServiceProvider serviceProvider,
2121
Gdk.RGBA backgroundColor
2222
)
23-
: base(global::Gtk.Internal.ApplicationWindow.New(application.Handle), false)
23+
: base(new global::Gtk.Internal.ApplicationWindowHandle(global::Gtk.Internal.ApplicationWindow.New(application.Handle.DangerousGetHandle()), false))
2424
{
2525
SetDefaultSize(1024, 768);
2626

src/SwashbucklerDiary.Gtk/SwashbucklerDiary.Gtk.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@
4242
</ItemGroup>
4343

4444
<ItemGroup>
45-
<PackageReference Include="GirCore.Gtk-4.0" Version="0.6.0-preview.1" />
46-
<PackageReference Include="GirCore.WebKit-6.0" Version="0.6.0-preview.1" />
45+
<PackageReference Include="GirCore.Gtk-4.0" Version="0.6.3" />
46+
<PackageReference Include="GirCore.WebKit-6.0" Version="0.6.3" />
4747
<PackageReference Include="Microsoft.AspNetCore.Components.WebView" Version="9.0.*" />
4848
<PackageReference Include="Serilog.Sinks.SQLite.Maui" Version="1.9.7" />
4949
</ItemGroup>

0 commit comments

Comments
 (0)