mirror of
https://github.com/proxysu/ProxySU.git
synced 2024-11-25 06:36:08 +03:00
59 lines
1.2 KiB
C#
59 lines
1.2 KiB
C#
using ProxySU_Core.Models;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Collections.ObjectModel;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace ProxySU_Core.ViewModels
|
|
{
|
|
public class RecordViewModel : BaseViewModel
|
|
{
|
|
public Record record;
|
|
private bool _isChecked;
|
|
|
|
public RecordViewModel(Record record)
|
|
{
|
|
this.record = record;
|
|
this._isChecked = false;
|
|
}
|
|
|
|
public bool IsChecked
|
|
{
|
|
get => _isChecked;
|
|
set
|
|
{
|
|
_isChecked = value;
|
|
Notify("IsChecked");
|
|
}
|
|
}
|
|
|
|
public Host Host
|
|
{
|
|
get => record.Host;
|
|
set
|
|
{
|
|
record.Host = value;
|
|
Notify("Host");
|
|
}
|
|
}
|
|
|
|
public XraySettings Settings
|
|
{
|
|
get => record.Settings;
|
|
set
|
|
{
|
|
record.Settings = value;
|
|
Notify("Settings");
|
|
}
|
|
}
|
|
|
|
public void Notify()
|
|
{
|
|
Notify("Host");
|
|
Notify("Settings");
|
|
}
|
|
}
|
|
}
|