Ticket #5057: dolby.patch

File dolby.patch, 1.0 KB (added by Scott.Atkins@…, 16 years ago)

xmltvparser.cpp patch matching the title case of dolby

  • (a) xmltvparser.cpp vs. (b) Copy

    a b  
    258258                    pginfo->audioproperties |= AUD_STEREO;
    259259                }
    260260                else if (getFirstText(info) == "dolby" ||
    261                         getFirstText(info) == "dolby digital")
     261                        getFirstText(info) == "dolby digital" ||
     262                        // XTVD Schema says these are in title case
     263                        // and XMLTV agrees.
     264                        getFirstText(info) == "Dolby" ||
     265                        getFirstText(info) == "Dolby Digital")
    262266                {
    263267                    pginfo->audioproperties |= AUD_DOLBY;
    264268                }
    265269                else if (getFirstText(info) == "surround")
    266270                {
    267271                    pginfo->audioproperties |= AUD_SURROUND;
    268                 }
     272                }
     273                else
     274                {
     275                    // Unknown types should be ignored but reported
     276                    VERBOSE(VB_XMLTV, QString("Ignoring invalid audio %1")
     277                        .arg(getFirstText(info)));
     278                }
    269279            }
    270280        }
    271281    }