public void Dispose() { if (MonitorConfig != null) { MonitorConfig = null; } if (_instance != null) { _instance = null; } }
public void LoadMonitorConfig() { //1.判断是否有原始配置 //{ //读取原始配置给以上对象 //保存一次 //} //else //{ // 读库; //} //判断是否为空 //{ // 空的对象new一次。 // 也需要保存一次 //} MonitorConfig = new MonitorConfigData(); }
public UC_StatusRectangleLayout() { InitializeComponent(); _proposedSize = new System.Drawing.Size(int.MaxValue, int.MaxValue); _switchPen.DashStyle = System.Drawing.Drawing2D.DashStyle.Dash; //默认便见颜色 this.DefaultStyle.BoardColor = Color.Black; //默认背景颜色 this.DefaultStyle.BackColor = Color.Black; this.DefaultStyle.BoardWidth = 1; //默认字体 this.DefaultFocusStyle.GridFont = new Font("宋体", 12, FontStyle.Regular); _screenBoarderPen = new Pen(Color.SpringGreen, 2.0f); _curMonitorConfigInfo = new MonitorConfigData(); }