This repository has been archived on 2024-08-06. You can view files and clone it, but cannot push or open issues or pull requests.
linear-app-launcher/Models/TileModel.cs
2020-11-17 22:44:02 +00:00

31 lines
1.3 KiB
C#

using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Drawing;
namespace AppLauncher.Models
{
public class TileModel
{
public string Title { get; set; }
public string ProcessFilename { get; set; }
public string ProcessArgument { get; set; }
public string ProcessWorkingDirectory { get; set; }
public ProcessWindowStyle ProcessWindowStyle { get; set; } = ProcessWindowStyle.Normal;
public bool ProcessAsAdmin { get; set; } = false;
public Point Position { get; set; }
public bool IsGroup { get; set; } = false;
public List<TileModel> Items { get; set; } = new List<TileModel>();
public override string ToString() => this.Title ?? string.Empty;
public string CleanProcessFilename => (string.IsNullOrWhiteSpace(this.ProcessFilename) ? string.Empty : Environment.ExpandEnvironmentVariables(this.ProcessFilename));
public string CleanProcessArgument => (string.IsNullOrWhiteSpace(this.ProcessArgument) ? string.Empty : Environment.ExpandEnvironmentVariables(this.ProcessArgument));
public string CleanProcessWorkingDirectory => (string.IsNullOrWhiteSpace(this.ProcessWorkingDirectory) ? string.Empty : Environment.ExpandEnvironmentVariables(this.ProcessWorkingDirectory));
}
}