Ticket #11954: recinput.mythtv.v0.28-pre-1480-g7265c8f.patch

File recinput.mythtv.v0.28-pre-1480-g7265c8f.patch, 28.6 KB (added by gnassas@…, 6 years ago)

rebase to reflect recordedid change

  • mythtv/bindings/perl/MythTV.pm

    From e1145faca8b4271898edc6c84c949ea476edf914 Mon Sep 17 00:00:00 2001
    From: George Nassas <George+Development@Nassas.com>
    Date: Tue, 3 Jun 2014 13:30:05 -0400
    Subject: [PATCH] Update
    
    ---
     mythtv/bindings/perl/MythTV.pm                     |  6 +-
     mythtv/bindings/perl/MythTV/Program.pm             |  4 +-
     mythtv/bindings/php/MythBackend.php                |  4 +-
     mythtv/bindings/php/MythTVProgram.php              |  1 +
     mythtv/bindings/php/MythTVRecording.php            |  1 +
     mythtv/bindings/python/MythTV/mythproto.py         |  8 +--
     mythtv/bindings/python/MythTV/static.py            |  4 +-
     mythtv/libs/libmyth/programinfo.cpp                | 75 +++++++++++++---------
     mythtv/libs/libmyth/programinfo.h                  | 11 +++-
     mythtv/libs/libmythbase/mythversion.h              |  4 +-
     .../datacontracts/recording.h                      |  3 +
     mythtv/libs/libmythtv/recordinginfo.cpp            |  6 +-
     mythtv/libs/libmythtv/tv_rec.cpp                   |  8 ++-
     mythtv/libs/libmythtv/videosource.cpp              |  8 +--
     .../programs/mythbackend/services/serviceUtil.cpp  |  1 +
     mythtv/programs/mythfrontend/progdetails.cpp       |  6 +-
     .../MythCenter-wide/htmls/progdetails_page2.html   |  1 +
     .../themes/MythCenter/htmls/progdetails_page2.html |  1 +
     mythtv/themes/Terra/htmls/progdetails_page2.html   |  1 +
     mythtv/themes/default/htmls/progdetails_page2.html |  1 +
     20 files changed, 97 insertions(+), 57 deletions(-)
    
    diff --git a/mythtv/bindings/perl/MythTV.pm b/mythtv/bindings/perl/MythTV.pm
    index a359ced..a9a3c67 100644
    a b package MythTV; 
    107107# Note: as of July 21, 2010, this is actually a string, to account for proto
    108108# versions of the form "58a".  This will get used if protocol versions are
    109109# changed on a fixes branch ongoing.
    110     our $PROTO_VERSION = "82";
    111     our $PROTO_TOKEN = "IdIdO";
     110    our $PROTO_VERSION = "83";
     111    our $PROTO_TOKEN = "SeaBird";
    112112
    113113# currentDatabaseVersion is defined in libmythtv in
    114114# mythtv/libs/libmythtv/dbcheck.cpp and should be the current MythTV core
    package MythTV; 
    120120# NUMPROGRAMLINES is defined in mythtv/libs/libmythtv/programinfo.h and is
    121121# the number of items in a ProgramInfo QStringList group used by
    122122# ProgramInfo::ToSringList and ProgramInfo::FromStringList.
    123     our $NUMPROGRAMLINES = 50;
     123    our $NUMPROGRAMLINES = 51;
    124124
    125125# Reasons a recording wouldn't be happening (from libs/libmythtv/programinfo.h)
    126126    our %RecStatus_Types = (
  • mythtv/bindings/perl/MythTV/Program.pm

    diff --git a/mythtv/bindings/perl/MythTV/Program.pm b/mythtv/bindings/perl/MythTV/Program.pm
    index 3e5d742..f4858d8 100644
    a b package MythTV::Program; 
    9696
    9797        $self->{'recordedid'}        = $_[49]; # recordedid
    9898
     99        $self->{'recinput'}          = $_[50]; # recording input
     100
    99101    # Load the channel data
    100102        if ($self->{'chanid'}) {
    101103            $self->{'channel'} = $self->{'_mythtv'}->channel($self->{'chanid'});
    package MythTV::Program; 
    189191                    $self->{'audio_props'}    , # 42 audio properties
    190192                    $self->{'video_props'}    , # 43 video properties
    191193                    $self->{'subtitle_type'}  , # 44 subtitle type
    192 
    193194                    $self->{'year'}           , # 45 production year
    194195                    $self->{'partnumber'}     , # 46 part number
    195196                    $self->{'parttotal'}      , # 47 part total
    196197                    $self->{'categorytype'}   , # 48 part total
    197198                    $self->{'recordedid'}     , # 49 part total
     199                    $self->{'recinput'}       , # 50 rec input
    198200                    ''                          # trailing separator
    199201                   );
    200202    }
  • mythtv/bindings/php/MythBackend.php

    diff --git a/mythtv/bindings/php/MythBackend.php b/mythtv/bindings/php/MythBackend.php
    index 77751f1..2cb7d3d 100644
    a b class MythBackend { 
    1111
    1212// MYTH_PROTO_VERSION is defined in libmyth in mythtv/libs/libmyth/mythcontext.h
    1313// and should be the current MythTV protocol version.
    14     static $protocol_version        = '82';
    15     static $protocol_token          = 'IdIdO';
     14    static $protocol_version        = '83';
     15    static $protocol_token          = 'SeaBird';
    1616
    1717// The character string used by the backend to separate records
    1818    static $backend_separator       = '[]:[]';
  • mythtv/bindings/php/MythTVProgram.php

    diff --git a/mythtv/bindings/php/MythTVProgram.php b/mythtv/bindings/php/MythTVProgram.php
    index a99741e..70c6677 100644
    a b class MythTVProgram { 
    4545    public $airdate;
    4646    public $playgroup;
    4747    public $recpriority2;
     48    public $recinput;
    4849    public $parentid;
    4950    public $storagegroup;
    5051    public $audioprop;
  • mythtv/bindings/php/MythTVRecording.php

    diff --git a/mythtv/bindings/php/MythTVRecording.php b/mythtv/bindings/php/MythTVRecording.php
    index 1174244..19db708 100644
    a b class MythTVRecording { 
    3434    public  $transcoder;
    3535    public  $timestretch;
    3636    public  $recpriority;
     37    public  $recinput;
    3738    public  $basename;
    3839    public  $progstart;
    3940    public  $progend;
  • mythtv/bindings/python/MythTV/mythproto.py

    diff --git a/mythtv/bindings/python/MythTV/mythproto.py b/mythtv/bindings/python/MythTV/mythproto.py
    index 211e372..99d4701 100644
    a b class Program( CMPRecord, DictData, RECSTATUS, AUDIO_PROPS, \ 
    842842                     'parentid',     'storagegroup', 'audio_props',
    843843                     'video_props',  'subtitle_type','year',
    844844                     'part_number',  'part_total',   'categorytype',
    845                      'recordedid']
     845                     'recordedid',   'recinput']
    846846    _field_type = [  3,      3,      3,
    847847                     0,      0,      0,
    848848                     3,
    class Program( CMPRecord, DictData, RECSTATUS, AUDIO_PROPS, \ 
    860860                     3,      3,      0,
    861861                     0,      0,      0,
    862862                     0,      0,      0,
    863                      0  ]
     863                     0,      3  ]
    864864    def __str__(self):
    865865        return u"<Program '%s','%s' at %s>" % (self.title,
    866866                 self.starttime.isoformat(' '), hex(id(self)))
    class Program( CMPRecord, DictData, RECSTATUS, AUDIO_PROPS, \ 
    888888        for key in ('title','subTitle','seriesId','programId','airdate',
    889889                'category','hostname','chanNum','callSign','playGroup',
    890890                'recGroup','rectype','programFlags','chanId','recStatus',
    891                 'commFree','stars','filesize'):
     891                'commFree','stars','filesize','recinput'):
    892892            if key in xmldat:
    893893                dat[key.lower()] = xmldat[key]
    894894        for key in ('startTime','endTime','lastModified',
    class Program( CMPRecord, DictData, RECSTATUS, AUDIO_PROPS, \ 
    916916                ('ChanId', 'CallSign', 'ChanNum', 'InputId', 'SourceId'), True)
    917917        CopyData2(prog['Channel'], dat, (('ChannelName', 'channame'),))
    918918        CopyData(prog['Recording'], dat,
    919                 ('DupMethod', 'PlayGroup', 'RecType', 'RecordId'), True)
     919                ('DupMethod', 'PlayGroup', 'RecType', 'RecordId', 'RecInput'), True)
    920920        CopyData2(prog['Recording'], dat, (('DupInType', 'dupin'),
    921921                                           ('Status', 'recstatus')))
    922922
  • mythtv/bindings/python/MythTV/static.py

    diff --git a/mythtv/bindings/python/MythTV/static.py b/mythtv/bindings/python/MythTV/static.py
    index 8b702a2..d0d99f2 100644
    a b OWN_VERSION = (0,28,-1,0) 
    88SCHEMA_VERSION = 1325
    99NVSCHEMA_VERSION = 1007
    1010MUSICSCHEMA_VERSION = 1018
    11 PROTO_VERSION = '82'
    12 PROTO_TOKEN = 'IdIdO'
     11PROTO_VERSION = '83'
     12PROTO_TOKEN = 'SeaBird'
    1313BACKEND_SEP = '[]:[]'
    1414INSTALL_PREFIX = '/usr/local'
    1515
  • mythtv/libs/libmyth/programinfo.cpp

    diff --git a/mythtv/libs/libmyth/programinfo.cpp b/mythtv/libs/libmyth/programinfo.cpp
    index 2f85136..7502710 100644
    a b const QString ProgramInfo::kFromRecordedQuery = 
    6666    "       r.findid,           rec.dupin,      rec.dupmethod,     "//45-47
    6767    "       p.syndicatedepisodenumber, p.partnumber, p.parttotal,  "//48-50
    6868    "       p.season,           p.episode,      p.totalepisodes,   "//51-53
    69     "       p.category_type,    r.recordedid                       "//54-55
     69    "       p.category_type,    r.recordedid,   r.recinput         "//54-55
    7070    "FROM recorded AS r "
    7171    "LEFT JOIN channel AS c "
    7272    "ON (r.chanid    = c.chanid) "
    ProgramInfo::ProgramInfo(void) : 
    123123    director(),
    124124
    125125    recpriority(0),
     126    recinput(),
    126127
    127128    chanid(0),
    128129    chanstr(),
    ProgramInfo::ProgramInfo(const ProgramInfo &other) : 
    209210    director(other.director),
    210211
    211212    recpriority(other.recpriority),
     213    recinput(other.recinput),
    212214
    213215    chanid(other.chanid),
    214216    chanstr(other.chanstr),
    ProgramInfo::ProgramInfo( 
    349351    CategoryType  _catType,
    350352
    351353    int _recpriority,
     354    const QString &_recinput,
    352355
    353356    uint64_t _filesize,
    354357
    ProgramInfo::ProgramInfo( 
    389392    director(),
    390393
    391394    recpriority(_recpriority),
     395    recinput(_recinput),
    392396
    393397    chanid(_chanid),
    394398    chanstr(_channum),
    ProgramInfo::ProgramInfo( 
    509513    director(),
    510514
    511515    recpriority(0),
     516    recinput(),
    512517
    513518    chanid(_chanid),
    514519    chanstr(_channum),
    ProgramInfo::ProgramInfo( 
    638643    director(),
    639644
    640645    recpriority(0),
     646    recinput(),
    641647
    642648    chanid(_chanid),
    643649    chanstr(_channum),
    ProgramInfo::ProgramInfo( 
    800806    director(),
    801807
    802808    recpriority(0),
     809    recinput(),
    803810
    804811    chanid(_chanid),
    805812    chanstr(_channum),
    void ProgramInfo::clone(const ProgramInfo &other, 
    10671074    catType = other.catType;
    10681075
    10691076    recpriority = other.recpriority;
     1077    recinput = other.recinput;
    10701078
    10711079    filesize = other.filesize;
    10721080
    void ProgramInfo::clone(const ProgramInfo &other, 
    11391147    programid.detach();
    11401148    inetref.detach();
    11411149
     1150    recinput.detach();
     1151
    11421152    sortTitle.detach();
    11431153    inUseForWhat.detach();
    11441154}
    void ProgramInfo::clear(void) 
    11761186    seriesid.clear();
    11771187    programid.clear();
    11781188    inetref.clear();
     1189    recinput.clear();
    11791190    catType = kCategoryNone;
    11801191
    11811192    sortTitle.clear();
    void ProgramInfo::ToStringList(QStringList &list) const 
    13751386    INT_TO_LIST(catType);      // 48
    13761387
    13771388    INT_TO_LIST(recordedid);   //49
     1389
     1390    STR_TO_LIST(recinput);     // 50
     1391
    13781392/* do not forget to update the NUMPROGRAMLINES defines! */
    13791393}
    13801394
    bool ProgramInfo::FromStringList(QStringList::const_iterator &it, 
    14791493    INT_FROM_LIST(partnumber);        // 46
    14801494    INT_FROM_LIST(parttotal);         // 47
    14811495    ENUM_FROM_LIST(catType, CategoryType); // 48
     1496    STR_FROM_LIST(recinput);          // 49
    14821497
    14831498    INT_FROM_LIST(recordedid);        // 49
    14841499
    void ProgramInfo::ToMap(InfoMap &progMap, 
    15991614        if (timeNow.toLocalTime().date().year() !=
    16001615            endts.toLocalTime().date().year())
    16011616            progMap["endyear"] = endts.toLocalTime().toString("yyyy");
     1617        progMap["inputname"] = recinput;
    16021618    }
    16031619
    16041620    using namespace MythDate;
    void ProgramInfo::ToMap(InfoMap &progMap, 
    16891705
    16901706    progMap["card"] = ::toString(GetRecordingStatus(), cardid);
    16911707    progMap["input"] = ::toString(GetRecordingStatus(), inputid);
    1692     progMap["inputname"] = QueryInputDisplayName();
    16931708
    16941709    progMap["recpriority"] = recpriority;
    16951710    progMap["recpriority2"] = recpriority2;
    bool ProgramInfo::LoadProgramFromRecorded( 
    20122027    catType      = string_to_myth_category_type(query.value(54).toString());
    20132028
    20142029    recpriority  = query.value(16).toInt();
     2030    recinput     = query.value(55).toString();
    20152031
    20162032    filesize     = query.value(20).toULongLong();
    20172033
    void ProgramInfo::SaveInetRef(const QString &inet) 
    45234539    SendUpdateEvent();
    45244540}
    45254541
     4542/** \fn ProgramInfo::SaveRecInput(const QString)
     4543 *  \brief Sets recording input display name in database,
     4544 *         and sets "recinput" field.
     4545 */
     4546void ProgramInfo::SaveRecInput(const QString &inputName)
     4547{
     4548    recinput = inputName;
     4549
     4550    MSqlQuery query(MSqlQuery::InitCon());
     4551
     4552    query.prepare(
     4553        "UPDATE recorded "
     4554        "SET recinput = :RECINPUT "
     4555        "WHERE chanid = :CHANID AND starttime = :STARTTIME "
     4556        "AND recordid = :RECORDID");
     4557
     4558    query.bindValue(":RECINPUT",   inputName);
     4559    query.bindValue(":CHANID",     chanid);
     4560    query.bindValue(":STARTTIME",  recstartts);
     4561    query.bindValue(":RECORDID",   recordid);
     4562    query.exec();
     4563}
     4564
    45264565/** \brief Attempts to ascertain if the main file for this ProgramInfo
    45274566 *         is readable.
    45284567 *  \note This method often initiates a QUERY_CHECKFILE MythProto
    bool ProgramInfo::QueryTuningInfo(QString &channum, QString &input) const 
    48784917    }
    48794918}
    48804919
    4881 /** \brief Returns the display name of the card input for this program.
    4882  *  \note Ideally this would call CardUtil::GetDisplayName(), but
    4883  *        that's in libmythtv.  Dupliacte code for now until a better
    4884  *        solution can be found.
    4885  */
    4886 QString ProgramInfo::QueryInputDisplayName(void) const
    4887 {
    4888     if (!inputid)
    4889         return QString::null;
    4890 
    4891     MSqlQuery query(MSqlQuery::InitCon());
    4892     query.prepare("SELECT displayname, cardid, inputname "
    4893                   "FROM cardinput "
    4894                   "WHERE cardinputid = :INPUTID");
    4895     query.bindValue(":INPUTID", inputid);
    4896 
    4897     if (!query.exec())
    4898         MythDB::DBError("ProgramInfo::GetInputDisplayName(uint)", query);
    4899     else if (query.next())
    4900     {
    4901         QString result = query.value(0).toString();
    4902         if (result.isEmpty())
    4903             result = QString("%1: %2").arg(query.value(1).toInt())
    4904                                       .arg(query.value(2).toString());
    4905         return result;
    4906     }
    4907 
    4908     return QString::null;
    4909 }
    4910 
    49114920static int init_tr(void)
    49124921{
    49134922    static bool done = false;
    void ProgramInfo::SubstituteMatches(QString &str) 
    50325041    str.replace(QString("%PLAYGROUP%"), playgroup);
    50335042    str.replace(QString("%CHANID%"), QString::number(chanid));
    50345043    str.replace(QString("%INETREF%"), inetref);
     5044    str.replace(QString("%RECINPUT%"), recinput);
    50355045    str.replace(QString("%PARTNUMBER%"), QString::number(partnumber));
    50365046    str.replace(QString("%PARTTOTAL%"), QString::number(parttotal));
    50375047    str.replace(QString("%ORIGINALAIRDATE%"),
    bool LoadFromRecorded( 
    55335543                string_to_myth_category_type(query.value(54).toString()), // category_type
    55345544
    55355545                query.value(16).toInt(),  // recpriority
     5546                query.value(55).toString(), // recinput
    55365547
    55375548                query.value(20).toULongLong(),  // filesize
    55385549
  • mythtv/libs/libmyth/programinfo.h

    diff --git a/mythtv/libs/libmyth/programinfo.h b/mythtv/libs/libmyth/programinfo.h
    index 7115b42..b5e5477 100644
    a b  
    3030   mythtv/bindings/python/MythTV/static.py (version number)
    3131   mythtv/bindings/python/MythTV/mythproto.py (layout)
    3232*/
    33 #define NUMPROGRAMLINES 50
     33#define NUMPROGRAMLINES 51
    3434
    3535class ProgramInfo;
    3636typedef AutoDeleteDeque<ProgramInfo*> ProgramList;
    class MPUBLIC ProgramInfo 
    115115                CategoryType  catType,
    116116
    117117                int recpriority,
     118                const QString &recinput,
    118119
    119120                uint64_t filesize,
    120121
    class MPUBLIC ProgramInfo 
    424425    QString GetCategoryTypeString(void)   const;
    425426    int     GetRecordingPriority(void)    const { return recpriority;  }
    426427    int     GetRecordingPriority2(void)   const { return recpriority2; }
     428    QString GetRecInput(void)             const { return recinput;     }
    427429    float   GetStars(void)                const { return stars;        }
    428430    uint    GetStars(uint range_max)      const
    429431        { return (int)(stars * range_max + 0.5f); }
    class MPUBLIC ProgramInfo 
    512514    void SetRecordingPriority2(int priority)     { recpriority2 = priority; }
    513515    void SetRecordingRuleID(uint id)                { recordid     = id;    }
    514516    void SetSourceID(uint id)                       { sourceid     = id;    }
    515     void SetInputID( uint id)                       { inputid      = id;    }
     517    virtual void
     518         SetInputID( uint id)                       { inputid      = id;    }
    516519    void SetCardID(  uint id)                       { cardid       = id;    }
     520    void SetRecInput(      const QString &inpName)  { recinput     = inpName; }
    517521    void SetReactivated(bool reactivate)
    518522    {
    519523        programflags &= ~FL_REACTIVATE;
    class MPUBLIC ProgramInfo 
    557561    AutoExpireType QueryAutoExpire(void) const;
    558562    TranscodingStatus QueryTranscodeStatus(void) const;
    559563    bool        QueryTuningInfo(QString &channum, QString &input) const;
    560     QString     QueryInputDisplayName(void) const;
    561564    uint        QueryAverageWidth(void) const;
    562565    uint        QueryAverageHeight(void) const;
    563566    uint        QueryAverageFrameRate(void) const;
    class MPUBLIC ProgramInfo 
    595598    void UpdateInUseMark(bool force = false);
    596599    void SaveSeasonEpisode(uint seas, uint ep);
    597600    void SaveInetRef(const QString &inet);
     601    void SaveRecInput(const QString &inputName);
    598602
    599603    // Extremely slow functions that cannot be called from the UI thread.
    600604    QString DiscoverRecordingDirectory(void) const;
    class MPUBLIC ProgramInfo 
    697701    QString director;
    698702
    699703    int32_t recpriority;
     704    QString recinput;
    700705
    701706    uint32_t chanid;
    702707    QString chanstr; // Channum
  • mythtv/libs/libmythbase/mythversion.h

    diff --git a/mythtv/libs/libmythbase/mythversion.h b/mythtv/libs/libmythbase/mythversion.h
    index 8c5876b..91740ca 100644
    a b  
    3939 *       http://www.mythtv.org/wiki/Category:Myth_Protocol_Commands
    4040 *       http://www.mythtv.org/wiki/Category:Myth_Protocol
    4141 */
    42 #define MYTH_PROTO_VERSION "82"
    43 #define MYTH_PROTO_TOKEN "IdIdO"
     42#define MYTH_PROTO_VERSION "83"
     43#define MYTH_PROTO_TOKEN "SeaBird"
    4444
    4545/** \brief Increment this whenever the MythTV core database schema changes.
    4646 *
  • mythtv/libs/libmythservicecontracts/datacontracts/recording.h

    diff --git a/mythtv/libs/libmythservicecontracts/datacontracts/recording.h b/mythtv/libs/libmythservicecontracts/datacontracts/recording.h
    index 8691f86..e1254b2 100644
    a b class SERVICE_PUBLIC RecordingInfo : public QObject 
    4242    Q_PROPERTY( int                     EncoderId    READ EncoderId    WRITE setEncoderId    DESIGNABLE SerializeDetails )
    4343    Q_PROPERTY( QString                 EncoderName  READ EncoderName  WRITE setEncoderName  DESIGNABLE SerializeDetails )
    4444    Q_PROPERTY( QString                 Profile      READ Profile      WRITE setProfile      DESIGNABLE SerializeDetails )
     45    Q_PROPERTY( QString                 InputName    READ InputName    WRITE setInputName    DESIGNABLE SerializeDetails )
    4546
    4647    /*
    4748    Not using since Q_ENUMS seem to require the enum be defined in this class
    class SERVICE_PUBLIC RecordingInfo : public QObject 
    6869    PROPERTYIMP     ( int                    , EncoderId   )
    6970    PROPERTYIMP     ( QString                , EncoderName )
    7071    PROPERTYIMP     ( QString                , Profile     )
     72    PROPERTYIMP     ( QString                , InputName   )
    7173
    7274    // Used only by Serializer
    7375    PROPERTYIMP( bool, SerializeDetails )
    class SERVICE_PUBLIC RecordingInfo : public QObject 
    113115            m_DupMethod       = src.m_DupMethod        ;
    114116            m_EncoderId       = src.m_EncoderId        ;
    115117            m_Profile         = src.m_Profile          ;
     118            m_InputName       = src.m_InputName        ;
    116119            m_SerializeDetails= src.m_SerializeDetails ;
    117120        }
    118121};
  • mythtv/libs/libmythtv/recordinginfo.cpp

    diff --git a/mythtv/libs/libmythtv/recordinginfo.cpp b/mythtv/libs/libmythtv/recordinginfo.cpp
    index d2bf134..063e40c 100644
    a b using namespace std; 
    3030#include "mythdb.h"
    3131#include "mythlogging.h"
    3232#include "previewgenerator.h"
     33#include "cardutil.h"
    3334#include "channelutil.h"
    3435
    3536#define LOC      QString("RecordingInfo(%1): ").arg(GetBasename())
    bool RecordingInfo::InsertProgram(RecordingInfo *pg, 
    10251026        "    stars,     previouslyshown,              originalairdate,  "
    10261027        "    findid,    transcoder,  playgroup,       recpriority,      "
    10271028        "    basename,  progstart,   progend,         profile,          "
    1028         "    duplicate, storagegroup) "
     1029        "    duplicate, storagegroup,recinput) "
    10291030        "VALUES"
    10301031        "  (:CHANID,   :STARTS,     :ENDS,           :TITLE,            "
    10311032        "   :SUBTITLE, :DESC,       :SEASON,         :EPISODE,          "
    bool RecordingInfo::InsertProgram(RecordingInfo *pg, 
    10341035        "   :STARS,    :REPEAT,                      :ORIGAIRDATE,      "
    10351036        "   :FINDID,   :TRANSCODER, :PLAYGROUP,      :RECPRIORITY,      "
    10361037        "   :BASENAME, :PROGSTART,  :PROGEND,        :PROFILE,          "
    1037         "   0,         :STORGROUP) "
     1038        "   0,         :STORGROUP,  :RECINPUT)"
    10381039        );
    10391040
    10401041    if (pg->rectype == kOverrideRecord)
    bool RecordingInfo::InsertProgram(RecordingInfo *pg, 
    10681069    query.bindValue(":TRANSCODER",  rule->m_transcoder);
    10691070    query.bindValue(":PLAYGROUP",   pg->playgroup);
    10701071    query.bindValue(":RECPRIORITY", rule->m_recPriority);
     1072    query.bindValue(":RECINPUT",    null_to_empty(pg->recinput));
    10711073    query.bindValue(":BASENAME",    pg->pathname);
    10721074    query.bindValue(":STORGROUP",   null_to_empty(pg->storagegroup));
    10731075    query.bindValue(":PROGSTART",   pg->startts);
  • mythtv/libs/libmythtv/tv_rec.cpp

    diff --git a/mythtv/libs/libmythtv/tv_rec.cpp b/mythtv/libs/libmythtv/tv_rec.cpp
    index 778f36d..a11b7a0 100644
    a b uint TVRec::TuningCheckForHWChange(const TuningRequest &request, 
    36063606        curCardID = channel->GetInputCardID(current_input);
    36073607        newCardID = channel->GetInputCardID(new_input);
    36083608        LOG(VB_GENERAL, LOG_INFO, LOC + QString("HW Tuner: %1->%2")
    3609                 .arg(curCardID).arg(newCardID));
     3609                .arg(curCardID).arg(newCardID));
    36103610    }
    36113611
    36123612    if (curCardID != newCardID || !CardUtil::IsChannelReusable(genOpt.cardtype))
    void TVRec::TuningFrequency(const TuningRequest &request) 
    37873787    else
    37883788        ok = true;
    37893789
     3790    LOG(VB_RECORD, LOG_INFO, LOC + QString("Tuning on: %1").arg(input));
     3791    if (curRecording) {
     3792        curRecording->SaveRecInput(
     3793            CardUtil::GetDisplayName(cardid,input));
     3794    }
     3795
    37903796    if (!ok)
    37913797    {
    37923798        if (!(request.flags & kFlagLiveTV) || !(request.flags & kFlagEITScan))
  • mythtv/libs/libmythtv/videosource.cpp

    diff --git a/mythtv/libs/libmythtv/videosource.cpp b/mythtv/libs/libmythtv/videosource.cpp
    index 786f22e..d183e57 100644
    a b class InputDisplayName : public LineEditSetting, public CardInputDBStorage 
    26382638    {
    26392639        setLabel(QObject::tr("Display name (optional)"));
    26402640        setHelpText(QObject::tr(
    2641                         "This name is displayed on screen when Live TV begins "
    2642                         "and when changing the selected input or card. If you "
    2643                         "use this, make sure the information is unique for "
    2644                         "each input."));
     2641                        "This name is displayed on screen when Live TV begins, "
     2642                        "when changing the selected input or card, and on a "
     2643                        "recording's info dialog. If you use this, make sure "
     2644                        "the information is unique for each input."));
    26452645    };
    26462646};
    26472647
  • mythtv/programs/mythbackend/services/serviceUtil.cpp

    diff --git a/mythtv/programs/mythbackend/services/serviceUtil.cpp b/mythtv/programs/mythbackend/services/serviceUtil.cpp
    index 5377acc..191f34c 100644
    a b void FillProgramInfo( DTC::Program *pProgram, 
    141141                                                               pProgram->Channel()->SourceId());
    142142                pRecording->setEncoderName( encoderName );
    143143            }
     144            pRecording->setInputName   ( pInfo->GetRecInput()             );
    144145
    145146            const RecordingInfo ri(*pInfo);
    146147            pRecording->setProfile( ri.GetProgramRecordingProfile() );
  • mythtv/programs/mythfrontend/progdetails.cpp

    diff --git a/mythtv/programs/mythfrontend/progdetails.cpp b/mythtv/programs/mythfrontend/progdetails.cpp
    index fcff565..c817f85 100644
    a b void ProgDetails::loadPage(void) 
    664664    addItem("FINDID", tr("Find ID"), s);
    665665
    666666    QString recordingHost;
     667    QString recordingInput;
    667668    QString recordedFilename;
    668669    QString recordedFileSize;
    669670    QString recordingGroup;
    void ProgDetails::loadPage(void) 
    671672    QString playbackGroup;
    672673    QString recordingProfile;
    673674
     675    recordingHost = m_progInfo.GetHostname();
     676    recordingInput = m_progInfo.GetRecInput();
     677
    674678    if (recorded)
    675679    {
    676         recordingHost = m_progInfo.GetHostname();
    677680        recordedFilename = m_progInfo.GetBasename();
    678681        recordedFileSize = QString("%1 ")
    679682            .arg(m_progInfo.GetFilesize()/((double)(1<<30)),0,'f',2);
    void ProgDetails::loadPage(void) 
    698701        recordingProfile =  record->m_recProfile;
    699702    }
    700703    addItem("RECORDING_HOST", tr("Recording Host"), recordingHost);
     704    addItem("RECORDING_INPUT", tr("Recording Input"), recordingInput);
    701705    addItem("RECORDED_FILE_NAME", tr("Recorded File Name"), recordedFilename);
    702706    addItem("RECORDED_FILE_SIZE", tr("Recorded File Size"), recordedFileSize);
    703707    addItem("RECORDING_PROFILE", tr("Recording Profile"), recordingProfile);
  • mythtv/themes/MythCenter-wide/htmls/progdetails_page2.html

    diff --git a/mythtv/themes/MythCenter-wide/htmls/progdetails_page2.html b/mythtv/themes/MythCenter-wide/htmls/progdetails_page2.html
    index 499bfb5..fdb9cf9 100644
    a b  
    3636    <h1>%SEARCH_PHRASE_LABEL%</h1> <p>%SEARCH_PHRASE%</p>
    3737    <h1>%FINDID_LABEL%</h1> <p>%FINDID%</p>
    3838    <h1>%RECORDING_HOST_LABEL%</h1> <p>%RECORDING_HOST%</p>
     39    <h1>%RECORDING_INPUT_LABEL%</h1> <p>%RECORDING_INPUT%</p>
    3940    <h1>%RECORDED_FILE_NAME_LABEL%</h1> <p>%RECORDED_FILE_NAME%</p>
    4041    <h1>%RECORDED_FILE_SIZE_LABEL%</h1> <p>%RECORDED_FILE_SIZE%</p>
    4142    <h1>%RECORDING_PROFILE_LABEL%</h1> <p>%RECORDING_PROFILE%</p>
  • mythtv/themes/MythCenter/htmls/progdetails_page2.html

    diff --git a/mythtv/themes/MythCenter/htmls/progdetails_page2.html b/mythtv/themes/MythCenter/htmls/progdetails_page2.html
    index 3619729..cf36332 100644
    a b  
    3838    <h1>%SEARCH_PHRASE_LABEL%</h1> <p>%SEARCH_PHRASE%</p>
    3939    <h1>%FINDID_LABEL%</h1> <p>%FINDID%</p>
    4040    <h1>%RECORDING_HOST_LABEL%</h1> <p>%RECORDING_HOST%</p>
     41    <h1>%RECORDING_INPUT_LABEL%</h1> <p>%RECORDING_INPUT%</p>
    4142    <h1>%RECORDED_FILE_NAME_LABEL%</h1> <p>%RECORDED_FILE_NAME%</p>
    4243    <h1>%RECORDED_FILE_SIZE_LABEL%</h1> <p>%RECORDED_FILE_SIZE%</p>
    4344    <h1>%RECORDING_PROFILE_LABEL%</h1> <p>%RECORDING_PROFILE%</p>
  • mythtv/themes/Terra/htmls/progdetails_page2.html

    diff --git a/mythtv/themes/Terra/htmls/progdetails_page2.html b/mythtv/themes/Terra/htmls/progdetails_page2.html
    index 243d041..a1426d6 100644
    a b  
    4141    <h1>%SEARCH_PHRASE_LABEL%</h1> <p>%SEARCH_PHRASE%</p>
    4242    <h1>%FINDID_LABEL%</h1> <p>%FINDID%</p>
    4343    <h1>%RECORDING_HOST_LABEL%</h1> <p>%RECORDING_HOST%</p>
     44    <h1>%RECORDING_INPUT_LABEL%</h1> <p>%RECORDING_INPUT%</p>
    4445    <h1>%RECORDED_FILE_NAME_LABEL%</h1> <p>%RECORDED_FILE_NAME%</p>
    4546    <h1>%RECORDED_FILE_SIZE_LABEL%</h1> <p>%RECORDED_FILE_SIZE%</p>
    4647    <h1>%RECORDING_PROFILE_LABEL%</h1> <p>%RECORDING_PROFILE%</p>
  • mythtv/themes/default/htmls/progdetails_page2.html

    diff --git a/mythtv/themes/default/htmls/progdetails_page2.html b/mythtv/themes/default/htmls/progdetails_page2.html
    index 900fd31..40fb94b 100644
    a b  
    3838    <h1>%SEARCH_PHRASE_LABEL%</h1> <p>%SEARCH_PHRASE%</p>
    3939    <h1>%FINDID_LABEL%</h1> <p>%FINDID%</p>
    4040    <h1>%RECORDING_HOST_LABEL%</h1> <p>%RECORDING_HOST%</p>
     41    <h1>%RECORDING_INPUT_LABEL%</h1> <p>%RECORDING_INPUT%</p>
    4142    <h1>%RECORDED_FILE_NAME_LABEL%</h1> <p>%RECORDED_FILE_NAME%</p>
    4243    <h1>%RECORDED_FILE_SIZE_LABEL%</h1> <p>%RECORDED_FILE_SIZE%</p>
    4344    <h1>%RECORDING_PROFILE_LABEL%</h1> <p>%RECORDING_PROFILE%</p>