BatchGuy.App.BluRayTitleInfoForm.SetGridRowBackgroundIfUndetermindLanguage C# (CSharp) Method

SetGridRowBackgroundIfUndetermindLanguage() private method

private SetGridRowBackgroundIfUndetermindLanguage ( ) : void
return void
        private void SetGridRowBackgroundIfUndetermindLanguage()
        {
            if (_bluRaySummaryInfo.BluRayTitleInfo.AudioList != null)
            {
                foreach (DataGridViewRow row in dgvAudio.Rows)
                {
                    string id = (string)row.Cells[1].Value;
                    BluRayTitleAudio audio = _bluRaySummaryInfo.BluRayTitleInfo.AudioList.Where(s => s.Id == id).SingleOrDefault();
                    if (audio != null && audio.MKVMergeItem.Language.Language == "Undetermined")
                    {
                        row.DefaultCellStyle.BackColor = Color.Yellow;
                        foreach (DataGridViewCell cell in row.Cells)
                        {
                            cell.ToolTipText = "eac3to language could not be matched with mkvmerge langage";
                        }
                    }
                }
            }

            if (_bluRaySummaryInfo.BluRayTitleInfo.Subtitles != null)
            {
                foreach (DataGridViewRow row in dgvSubtitles.Rows)
                {
                    string id = (string)row.Cells[1].Value;
                    BluRayTitleSubtitle subtitle = _bluRaySummaryInfo.BluRayTitleInfo.Subtitles.Where(s => s.Id == id).SingleOrDefault();
                    if (subtitle != null && subtitle.MKVMergeItem.Language.Language == "Undetermined")
                    {
                        row.DefaultCellStyle.BackColor = Color.Yellow;
                        foreach (DataGridViewCell cell in row.Cells)
                        {
                            cell.ToolTipText = "eac3to language could not be matched with mkvmerge langage";
                        }
                    }
                }
            }
        }
BluRayTitleInfoForm