Ticket #1377: austar_eit.diff

File austar_eit.diff, 3.4 KB (added by dave@…, 20 years ago)

Patch for eit fix up for Austar.

  • libs/libmythtv/eitfixup.cpp

     
    4949        FixPBS(event);
    5050    else if (kFixComHem == fix_type)
    5151        FixComHem(event);
     52    else if (kFixAU == fix_type)
     53        FixAU(event);
    5254
    5355    event.Event_Name.stripWhiteSpace();
    5456    event.Event_Subtitle.stripWhiteSpace();
     
    330332    }
    331333}
    332334
     335/** \fn EITFixUp::FixAU(Event&) const
     336 *  \brief Use this to standardize DVB-S guide in Australia.
     337 */
     338void EITFixUp::FixAU(Event &event) const
     339{
     340    event.ContentDescription = event.Event_Subtitle;
     341    /* Used for DVB-S Subtitles are seperated by a colon */
     342    int position = event.Description.find(':');
     343    if (position != -1)
     344    {
     345        const QString stmp   = event.Description;
     346        event.Event_Subtitle = stmp.left(position);
     347        event.Description    = stmp.right(stmp.length() - position - 2);
     348    }
     349    else
     350    {
     351        event.Event_Subtitle = "";
     352    }
     353}
     354
    333355/** \fn EITFixUp::FixComHem(Event&) const
    334356 *  \brief Use this to standardize ComHem DVB-C service in Sweden.
    335357 */
  • libs/libmythtv/dbcheck.cpp

     
    1010#include "mythdbcon.h"
    1111
    1212/// This is the DB schema version expected by the running MythTV instance.
    13 const QString currentDatabaseVersion = "1127";
     13const QString currentDatabaseVersion = "1128";
    1414
    1515static bool UpdateDBVersionNumber(const QString &newnumber);
    1616static bool performActualUpdate(const QString updates[], QString version,
     
    20482048            return false;
    20492049    }
    20502050
     2051    if (dbver == "1127")
     2052    {
     2053        const QString updates[] = {
     2054"INSERT INTO dtv_privatetypes (sitype,networkid,private_type,private_value) VALUES ('dvb',4096,'guide_fixup','5');",
     2055""
     2056};
     2057        if (!performActualUpdate(updates, "1128", dbver))
     2058            return false;
     2059    }
     2060
    20512061//"ALTER TABLE capturecard DROP COLUMN dvb_recordts;" in 0.21
    20522062//"ALTER TABLE capturecard DROP COLUMN dvb_hw_decoder;" in 0.21
    20532063
     
    26452655"INSERT INTO `dtv_privatetypes` VALUES ('dvb',4105,'guide_fixup','1');",
    26462656"INSERT INTO `dtv_privatetypes` VALUES ('dvb',4106,'guide_fixup','1');",
    26472657"INSERT INTO `dtv_privatetypes` VALUES ('dvb',4107,'guide_fixup','1');",
     2658"INSERT INTO  dtv_privatetypes  VALUES ('dvb',4096,'guide_fixup','5');",
    26482659"INSERT INTO `dtv_privatetypes` VALUES ('dvb',4097,'guide_fixup','1');",
    26492660"INSERT INTO `dtv_privatetypes` VALUES ('dvb',4098,'guide_fixup','1');",
    26502661"INSERT INTO `dtv_privatetypes` VALUES ('dvb',94,'tv_types','1,128');",
  • libs/libmythtv/eitfixup.h

     
    2222        kFixUK      = 2,
    2323        kFixPBS     = 3,
    2424        kFixComHem  = 4,
     25        kFixAU      = 5,
    2526    };
    2627
    2728    EITFixUp();
     
    3839    void FixUK(Event &event) const;            // UK DVB-T
    3940    void FixPBS(Event &event) const;           // USA ATSC
    4041    void FixComHem(Event &event) const;        // Sweden DVB-C
     42    void FixAU(Event &event) const;            // Australia DVB-S
    4143
    4244    /** List of ServiceID's for which to parse out subtitle
    4345     *  from the description. Used in EITFixUpStyle4().