Skip to content
This repository has been archived by the owner on Sep 2, 2019. It is now read-only.

Commit

Permalink
Merge remote-tracking branch 'refs/remotes/ZCube/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
lalafellsleep committed Jan 19, 2017
2 parents ddc537b + 810ab98 commit 9a43f5f
Showing 1 changed file with 18 additions and 8 deletions.
26 changes: 18 additions & 8 deletions ACTWebSocket.Core/ACTWebSocket.cs
Original file line number Diff line number Diff line change
Expand Up @@ -677,13 +677,11 @@ void LoadSettings()
if(obj.TryGetValue("SkinURLList", out token))
{
SkinURLList.Clear();
buttonRefresh_Click(null, null);
foreach (var a in token.Values<string>())
{
SkinURLList.Add(a);
AddURL(a);
}

buttonRefresh_Click(null, null);
}
}
catch (Exception e)
Expand Down Expand Up @@ -1218,11 +1216,23 @@ private void AddURL(string a)
});
Task UITask = task.ContinueWith((t) =>
{
title = title == null ? a : title;
ListViewItem lvi = new ListViewItem();
lvi.Text = title;
lvi.Tag = a;
skinList.Items.Add(lvi);
bool find = false;
foreach (ListViewItem i in skinList.Items)
{
if (((string)i.Tag).CompareTo(a) == 0)
{
find = true;
}
}

if(!find)
{
title = title == null ? a : title;
ListViewItem lvi = new ListViewItem();
lvi.Text = title;
lvi.Tag = a;
skinList.Items.Add(lvi);
}
}, TaskScheduler.FromCurrentSynchronizationContext());
}

Expand Down

0 comments on commit 9a43f5f

Please sign in to comment.