private void FillTranslateGrid(string filter)
{
if (translate == null)
return;
List<TranslateItem> filterTranslate = new List<TranslateItem>();
foreach (TranslateItem translateItem in translate)
{
if (!string.IsNullOrEmpty(filter) &&
!filter.Equals(allText.Text) &&
!filter.Equals(translateItem.Category))
continue;
//Skip translated items if filter is on
if (hideTranslatedItems.Checked && !string.IsNullOrEmpty(translateItem.TranslatedValue))
continue;
filterTranslate.Add(translateItem);
}
translateGrid.DataSource = filterTranslate;
UpdateProgress();
}