about summary refs log tree commit diff
path: root/MatrixRoomUtils.Desktop
diff options
context:
space:
mode:
Diffstat (limited to 'MatrixRoomUtils.Desktop')
-rw-r--r--MatrixRoomUtils.Desktop/App.axaml.cs1
-rw-r--r--MatrixRoomUtils.Desktop/Components/RoomListEntry.axaml.cs4
-rw-r--r--MatrixRoomUtils.Desktop/FileStorageProvider.cs1
-rw-r--r--MatrixRoomUtils.Desktop/MRUStorageWrapper.cs7
-rw-r--r--MatrixRoomUtils.Desktop/MainWindow.axaml.cs1
-rw-r--r--MatrixRoomUtils.Desktop/MatrixRoomUtils.Desktop.csproj13
-rw-r--r--MatrixRoomUtils.Desktop/RoomInfo.cs3
7 files changed, 15 insertions, 15 deletions
diff --git a/MatrixRoomUtils.Desktop/App.axaml.cs b/MatrixRoomUtils.Desktop/App.axaml.cs
index e0b50a5..33f2c13 100644
--- a/MatrixRoomUtils.Desktop/App.axaml.cs
+++ b/MatrixRoomUtils.Desktop/App.axaml.cs
@@ -4,7 +4,6 @@ using Avalonia.Markup.Xaml;
 using LibMatrix.Services;
 using Microsoft.Extensions.DependencyInjection;
 using Microsoft.Extensions.Hosting;
-using Sentry;
 
 namespace MatrixRoomUtils.Desktop;
 
diff --git a/MatrixRoomUtils.Desktop/Components/RoomListEntry.axaml.cs b/MatrixRoomUtils.Desktop/Components/RoomListEntry.axaml.cs
index 359deb3..6cdb767 100644
--- a/MatrixRoomUtils.Desktop/Components/RoomListEntry.axaml.cs
+++ b/MatrixRoomUtils.Desktop/Components/RoomListEntry.axaml.cs
@@ -28,7 +28,7 @@ public partial class RoomListEntry : UserControl {
     private async Task GetRoomName() {
         try {
             var nameEvent = await _roomInfo.GetStateEvent("m.room.name");
-            if (nameEvent?.TypedContent is RoomNameEventData nameData)
+            if (nameEvent?.TypedContent is RoomNameEventContent nameData)
                 RoomName.Content = nameData.Name;
         }
         catch (MatrixException e) {
@@ -40,7 +40,7 @@ public partial class RoomListEntry : UserControl {
     private async Task GetRoomIcon() {
         try {
             var avatarEvent = await _roomInfo.GetStateEvent("m.room.avatar");
-            if (avatarEvent?.TypedContent is RoomAvatarEventData avatarData) {
+            if (avatarEvent?.TypedContent is RoomAvatarEventContent avatarData) {
                 var mxcUrl = avatarData.Url;
                 await using var svc = _serviceScopeFactory.CreateAsyncScope();
                 var hs = await svc.ServiceProvider.GetService<MRUStorageWrapper>().GetCurrentSessionOrPrompt();
diff --git a/MatrixRoomUtils.Desktop/FileStorageProvider.cs b/MatrixRoomUtils.Desktop/FileStorageProvider.cs
index b3850b0..7f73cf3 100644
--- a/MatrixRoomUtils.Desktop/FileStorageProvider.cs
+++ b/MatrixRoomUtils.Desktop/FileStorageProvider.cs
@@ -1,4 +1,5 @@
 using System.Text.Json;
+using ArcaneLibs.Extensions;
 using LibMatrix.Extensions;
 using LibMatrix.Interfaces.Services;
 using Microsoft.Extensions.Logging;
diff --git a/MatrixRoomUtils.Desktop/MRUStorageWrapper.cs b/MatrixRoomUtils.Desktop/MRUStorageWrapper.cs
index 2243092..bc01774 100644
--- a/MatrixRoomUtils.Desktop/MRUStorageWrapper.cs
+++ b/MatrixRoomUtils.Desktop/MRUStorageWrapper.cs
@@ -1,4 +1,5 @@
 using LibMatrix;
+using LibMatrix.Homeservers;
 using LibMatrix.Responses;
 using LibMatrix.Services;
 
@@ -44,7 +45,7 @@ public class MRUStorageWrapper(TieredStorageService storageService, HomeserverPr
             await SetCurrentToken(loginResponse);
     }
 
-    private async Task<AuthenticatedHomeServer?> GetCurrentSession() {
+    private async Task<AuthenticatedHomeserverGeneric?> GetCurrentSession() {
         var token = await GetCurrentToken();
         if (token == null) {
             return null;
@@ -53,8 +54,8 @@ public class MRUStorageWrapper(TieredStorageService storageService, HomeserverPr
         return await homeserverProviderService.GetAuthenticatedWithToken(token.Homeserver, token.AccessToken);
     }
 
-    public async Task<AuthenticatedHomeServer?> GetCurrentSessionOrPrompt() {
-        AuthenticatedHomeServer? session = null;
+    public async Task<AuthenticatedHomeserverGeneric?> GetCurrentSessionOrPrompt() {
+        AuthenticatedHomeserverGeneric? session = null;
 
         try {
             //catch if the token is invalid
diff --git a/MatrixRoomUtils.Desktop/MainWindow.axaml.cs b/MatrixRoomUtils.Desktop/MainWindow.axaml.cs
index 135542b..0bed93d 100644
--- a/MatrixRoomUtils.Desktop/MainWindow.axaml.cs
+++ b/MatrixRoomUtils.Desktop/MainWindow.axaml.cs
@@ -1,5 +1,4 @@
 using Avalonia.Controls;
-using Avalonia.Data;
 using Avalonia.Interactivity;
 using Microsoft.Extensions.DependencyInjection;
 using Microsoft.Extensions.Logging;
diff --git a/MatrixRoomUtils.Desktop/MatrixRoomUtils.Desktop.csproj b/MatrixRoomUtils.Desktop/MatrixRoomUtils.Desktop.csproj
index 4dc9558..d21b5fe 100644
--- a/MatrixRoomUtils.Desktop/MatrixRoomUtils.Desktop.csproj
+++ b/MatrixRoomUtils.Desktop/MatrixRoomUtils.Desktop.csproj
@@ -20,13 +20,13 @@
 
 
     <ItemGroup>
-        <PackageReference Include="Avalonia" Version="11.0.3" />
-        <PackageReference Include="Avalonia.Desktop" Version="11.0.3" />
-        <PackageReference Include="Avalonia.Themes.Fluent" Version="11.0.3" />
-        <PackageReference Include="Avalonia.Fonts.Inter" Version="11.0.3" />
+        <PackageReference Include="Avalonia" Version="11.0.4" />
+        <PackageReference Include="Avalonia.Desktop" Version="11.0.4" />
+        <PackageReference Include="Avalonia.Themes.Fluent" Version="11.0.4" />
+        <PackageReference Include="Avalonia.Fonts.Inter" Version="11.0.4" />
         <!--Condition below is needed to remove Avalonia.Diagnostics package from build output in Release configuration.-->
-        <PackageReference Condition="'$(Configuration)' == 'Debug'" Include="Avalonia.Diagnostics" Version="11.0.3" />
-        <PackageReference Include="Sentry" Version="3.35.0" />
+        <PackageReference Condition="'$(Configuration)' == 'Debug'" Include="Avalonia.Diagnostics" Version="11.0.4" />
+        <PackageReference Include="Sentry" Version="3.36.0" />
     </ItemGroup>
 
 
@@ -35,7 +35,6 @@
     </ItemGroup>
 
     <ItemGroup>
-        <PackageReference Include="ArcaneLibs" Version="1.0.0-preview3020494760.012ed3f" />
         <PackageReference Include="Avalonia.Xaml.Behaviors" Version="11.0.2" />
         <PackageReference Include="Microsoft.Extensions.Hosting" Version="7.0.1" />
     </ItemGroup>
diff --git a/MatrixRoomUtils.Desktop/RoomInfo.cs b/MatrixRoomUtils.Desktop/RoomInfo.cs
index 4e76247..ebd80ab 100644
--- a/MatrixRoomUtils.Desktop/RoomInfo.cs
+++ b/MatrixRoomUtils.Desktop/RoomInfo.cs
@@ -1,4 +1,5 @@
 using LibMatrix;
+using LibMatrix.Interfaces;
 using LibMatrix.Responses;
 using LibMatrix.RoomTypes;
 
@@ -23,7 +24,7 @@ public class RoomInfo {
             StateKey = stateKey
         };
         try {
-            @event.TypedContent = await Room.GetStateAsync<object>(type, stateKey);
+            @event.TypedContent = await Room.GetStateAsync<EventContent>(type, stateKey);
         }
         catch (MatrixException e) {
             if (e is { ErrorCode: "M_NOT_FOUND" }) @event.TypedContent = default!;