From ede3857084bc7c6e65b7d36cbf913b09596e2787 Mon Sep 17 00:00:00 2001 From: Rory& Date: Mon, 8 Jan 2024 13:55:15 +0100 Subject: Internal changes to policy list viewer (extensibility), fix duplicating change handler for room list page (performance), use /state in room list page before sync --- MatrixRoomUtils.Desktop/MainWindow.axaml.cs | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'MatrixRoomUtils.Desktop/MainWindow.axaml.cs') diff --git a/MatrixRoomUtils.Desktop/MainWindow.axaml.cs b/MatrixRoomUtils.Desktop/MainWindow.axaml.cs index 9db59c5..6ef573e 100644 --- a/MatrixRoomUtils.Desktop/MainWindow.axaml.cs +++ b/MatrixRoomUtils.Desktop/MainWindow.axaml.cs @@ -1,5 +1,7 @@ using Avalonia.Controls; using Avalonia.Interactivity; +using MatrixRoomUtils.Abstractions; +using MatrixRoomUtils.Desktop.Components; using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.Logging; @@ -26,7 +28,6 @@ public partial class MainWindow : Window { _logger.LogInformation("Cache location: {}", _configuration.CacheStoragePath); _logger.LogInformation("Data location: {}", _configuration.DataStoragePath); - // for (int i = 0; i < 100; i++) { // roomList.Children.Add(new RoomListEntry()); // } @@ -39,12 +40,18 @@ public partial class MainWindow : Window { var rooms = await hs.GetJoinedRooms(); foreach (var room in rooms) { // roomList.Children.Add(new RoomListEntry(_scopeFactory, new RoomInfo(room))); + + windowContent.Push("home", new RoomListEntry() { + Room = new RoomInfo() { + Room = room + } + }); + base.OnLoaded(e); } - base.OnLoaded(e); } // public Command // protected void LoadedCommand() { // _logger.LogInformation("async command"); // } -} +} \ No newline at end of file -- cgit 1.4.1