mirror of
https://dev.azure.com/TeilRad/sharee.bike%20App/_git/Code
synced 2024-11-14 14:26:28 +01:00
36 lines
No EOL
895 B
C#
36 lines
No EOL
895 B
C#
using System;
|
|
using System.ComponentModel;
|
|
|
|
namespace TINK.ViewModel.Settings
|
|
{
|
|
/// <summary> Manages locks services and related parameters. </summary>
|
|
public class LocksServicesViewModel : INotifyPropertyChanged
|
|
{
|
|
private TimeSpan ConnectTimeout { get; set; }
|
|
|
|
public LocksServicesViewModel(
|
|
TimeSpan connectTimeout,
|
|
ServicesViewModel servicesViewModel)
|
|
{
|
|
ConnectTimeout = connectTimeout;
|
|
Services = servicesViewModel;
|
|
}
|
|
|
|
public ServicesViewModel Services { get; }
|
|
|
|
public string ConnectTimeoutSecText { get => ConnectTimeout.TotalSeconds.ToString(); }
|
|
|
|
public double ConnectTimeoutSec
|
|
{
|
|
get => ConnectTimeout.TotalSeconds;
|
|
|
|
set
|
|
{
|
|
ConnectTimeout = TimeSpan.FromSeconds(value);
|
|
PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(nameof(ConnectTimeoutSecText)));
|
|
}
|
|
}
|
|
|
|
public event PropertyChangedEventHandler PropertyChanged;
|
|
}
|
|
} |