cursor-guardrail-utility/source/Dtos/AppSession.cs
2026-07-11 02:31:25 +01:00

43 lines
1.1 KiB
C#

using System.Collections.Generic;
namespace CursorGuardRail
{
public class AppSession
{
public class HotKeyOptions
{
public bool IsCtrl { get; set; } = false;
public bool IsAlt { get; set; } = false;
public bool IsShift { get; set; } = false;
public int Key { get; set; } = (int)System.Windows.Forms.Keys.None;
public int ModifierCode => ((this.IsAlt ? 1 : 0) + (this.IsCtrl ? 2 : 0) + (this.IsShift ? 4 : 0));
public System.Windows.Forms.Keys KeyCode => (System.Windows.Forms.Keys)this.Key;
}
public string SearchFilePattern { get; set; } = "*";
public List<string> SearchItems
{
get => field ?? new List<string>();
set => field = value;
}
public bool SearchTopDirectoryOnly { get; set; } = false;
public bool ClosePrevOnNext { get; set; } = false;
public int RetryOnError { get; set; } = 8;
public HotKeyOptions NextHotKey
{
get => field ?? new HotKeyOptions();
set => field = value;
}
}
}