Migrated aurora-sharp-desktop to /aurora-sharp-desktop

This commit is contained in:
Brandon Watson
2021-03-05 22:45:05 -05:00
parent 3d4dada7c2
commit a8e418cc1b
187 changed files with 10337 additions and 0 deletions

View File

@ -0,0 +1,46 @@
using System;
using Aurora.Services.Settings;
namespace Aurora.Design.Views.Profile
{
public class ProfileViewModel : BaseViewModel
{
private ISettingsService _settingsService;
public ProfileViewModel(ISettingsService settingsService)
{
this._settingsService = settingsService;
}
public string Username
{
get { return this._settingsService.Username; }
set
{
this._settingsService.Username = value;
OnPropertyChanged("Username");
}
}
public string Port
{
get { return this._settingsService.DefaultPort.ToString(); }
set
{
Int32.TryParse(value, out int portNum);
this._settingsService.DefaultPort = portNum;
OnPropertyChanged("Port");
}
}
public string LibraryPath
{
get { return this._settingsService.LibraryLocation; }
set
{
this._settingsService.LibraryLocation = value;
OnPropertyChanged("LibraryPath");
}
}
}
}