Skip to content

Commit

Permalink
Forget about current chose server in menu item
Browse files Browse the repository at this point in the history
  • Loading branch information
Lomik_XP authored and madeye committed Jan 1, 2025
1 parent 6b0cbab commit 891d971
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion shadowsocks-csharp/View/MenuViewController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -678,16 +678,20 @@ private void UpdateServersMenu()
Configuration configuration = controller.GetCurrentConfiguration();
for (int i = 0; i < configuration.configs.Count; i++)
{
var server = configuration.configs[i];
try
{
if (overflow)
{
needAdd = configuration.index >= i;
if (needAdd)
{
i = configuration.index;
}
}

if (needAdd)
{
var server = configuration.configs[i];
Configuration.CheckServer(server);
var item = new MenuItem(server.ToString());
item.Tag = i;
Expand Down

0 comments on commit 891d971

Please sign in to comment.