修复 Modes 添加删除不更新 ModeComboBox,从剪切板导入服务器 ServerComboBox

不更新
This commit is contained in:
ChsBuffer
2020-08-25 18:12:05 +08:00
parent 388896f161
commit 5755230000
3 changed files with 4 additions and 1 deletions

View File

@@ -45,6 +45,7 @@ namespace Netch.Forms
MessageBoxX.Show(i18N.Translate("Import servers error!"), LogLevel.ERROR);
}
InitServer();
Configuration.Save();
}
}

View File

@@ -61,7 +61,7 @@ namespace Netch.Forms
#region Mode
private void InitMode()
public void InitMode()
{
var comboBoxInitialized = _comboBoxInitialized;
_comboBoxInitialized = false;

View File

@@ -97,12 +97,14 @@ namespace Netch.Utils
{
Global.Modes.Add(mode);
Sort();
Global.MainForm.InitMode();
}
public static void Delete(Mode mode)
{
mode.DeleteFile();
Global.Modes.Remove(mode);
Global.MainForm.InitMode();
}
}
}