VSoft/Source/VSoft_Dll/Config/Soft_Config.cs

56 lines
1.9 KiB
C#
Raw Normal View History

2020-11-28 07:44:21 +00:00
using ryCommon;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace VSoft.Config
{
/// <summary>
/// 配置类,保存在运行期间会被改变的配置信息(本系统基于乘黄V2架构)
/// </summary>
public static class Soft_Config
{
/// <summary>
/// 是否能关闭窗体。
/// </summary>
public static bool IsCanCloseForm = true;
/// <summary>
/// 在点击主窗口关闭按钮时,隐藏窗体(只有开启了托盘图标,本功能才能生效,此时需要通过托盘图标进行关闭)。
/// </summary>
public static bool HideByCloseBtn = true;
/// <summary>
/// 显示主窗体的热键
/// </summary>
public static string ShowMainHotKey = "";
/// <summary>
/// 是否开启鼠标快捷键
/// </summary>
public static bool ShowMainMouseKeyOn = true;
/// <summary>
/// 鼠标快捷键
/// </summary>
public static int ShowMainMouseKey = 0;
2020-11-28 07:44:21 +00:00
/// <summary>
/// 单击打开软件
/// </summary>
public static bool OpenByClick = false;
/// <summary>
/// 启动软件后隐藏自身
/// </summary>
public static bool HideAfterRun = true;
public static void LoadSetting()
{
ryCommon.Storage Stor = new Storage();
Stor.LoadFromFile(Soft_Info.UserDataFolder + "\\Setting.xml");
Stor.SelectNodeBySet();
ShowMainHotKey = Stor.GetAttrValue("ShowMainHotKey", "1+88");
OpenByClick = Stor.GetAttrValue("OpenByClick", false);
HideAfterRun = Stor.GetAttrValue("HideAfterRun", true);
ShowMainMouseKeyOn = Stor.GetAttrValue("ShowMainMouseKeyOn", true);
ShowMainMouseKey = Stor.GetAttrValue("ShowMainMouseKey", 0);
2020-11-28 07:44:21 +00:00
//low_count = Stor.GetAttrValue("LowCount", 10);
}
}
}