- add: Favorite, start.

This commit is contained in:
2025-01-13 19:24:12 +03:00
parent fa3b0b7a0b
commit a0b2cfd677
8 changed files with 87 additions and 34 deletions

View File

@@ -143,6 +143,7 @@ public sealed partial class ContentBrowserViewModel : ViewModelBase
if (path.Pathes.Count > 0 && (path.Pathes[0].StartsWith("ss14://") || path.Pathes[0].StartsWith("ss14s://")))
{
ServerText = path.Pathes[0];
path = new ContentPath("");
}
if (string.IsNullOrEmpty(ServerText))
@@ -157,14 +158,14 @@ public sealed partial class ContentBrowserViewModel : ViewModelBase
SelectedEntry = await CreateEntry(ServerText);
}
_debugService.Debug(path.Path);
_debugService.Debug("Going to:" + path.Path);
var oriPath = path.Clone();
try
{
if (SelectedEntry == null || !SelectedEntry.GetRoot().TryGetEntry(path, out var centry))
{
throw new Exception("Not found!");
throw new Exception("Not found! " + oriPath.Path);
}
if (appendHistory)

View File

@@ -0,0 +1,13 @@
using System;
using System.Collections.ObjectModel;
using Nebula.Shared.Models;
namespace Nebula.Launcher.ViewModels;
public class FavoriteServerListViewModel : ViewModelBase
{
public FavoriteServerListViewModel() : base(){}
public FavoriteServerListViewModel(IServiceProvider provider) : base(provider){}
public ObservableCollection<ServerHubInfo> Servers = new();
}