Ticket #1657: ignoreincomplete.3.patch
File ignoreincomplete.3.patch, 6.3 KB (added by , 16 years ago) |
---|
-
libs/libmythtv/sr_items.cpp
31 31 addItem(dupLocItem->getItem(), -1); 32 32 connect(dupMethItem->getItem(), SIGNAL(changed(ManagedListItem*)), this, SLOT(itemChanged(ManagedListItem*))); 33 33 34 ignoreIncomplete = new SRIgnoreIncomplete(_rec, this, parentList); 35 addItem(ignoreIncomplete->getItem(), -1); 36 34 37 inactive = new SRInactive(_rec, this, _parentList); 35 38 addItem(inactive->getItem(), -1); 36 39 } -
libs/libmythtv/scheduledrecording.h
28 28 class SRAutoUserJob3; 29 29 class SRAutoUserJob4; 30 30 class SRAutoExpire; 31 class SRIgnoreIncomplete; 31 32 class SRStartOffset; 32 33 class SREndOffset; 33 34 class SRMaxEpisodes; … … 80 81 int GetAutoExpire(void) const; 81 82 void SetAutoExpire(int expire); 82 83 84 int GetIgnoreIncomplete(void) const; 85 void SetIgnoreIncomplete(int expire); 86 83 87 int GetMaxEpisodes(void) const; 84 88 bool GetMaxNewest(void) const; 85 89 … … 150 154 void setAutoUserJob3Obj(SRAutoUserJob3* val) {autouserjob3 = val;} 151 155 void setAutoUserJob4Obj(SRAutoUserJob4* val) {autouserjob4 = val;} 152 156 void setAutoExpireObj(SRAutoExpire* val) {autoexpire = val;} 157 void setIgnoreIncompleteObj(SRIgnoreIncomplete* val) {ignoreincomplete = val;} 153 158 void setStartOffsetObj(SRStartOffset* val) {startoffset = val;} 154 159 void setEndOffsetObj(SREndOffset* val) {endoffset = val;} 155 160 void setMaxEpisodesObj(SRMaxEpisodes* val) {maxepisodes = val;} … … 223 228 class SRAutoUserJob3* autouserjob3; 224 229 class SRAutoUserJob4* autouserjob4; 225 230 class SRAutoExpire* autoexpire; 231 class SRIgnoreIncomplete* ignoreincomplete; 226 232 class SRStartOffset* startoffset; 227 233 class SREndOffset* endoffset; 228 234 class SRMaxEpisodes* maxepisodes; -
libs/libmythtv/sr_items.h
394 394 class SRDupIn* dupLocItem; 395 395 class SRInput* prefInput; 396 396 class SRInactive* inactive; 397 class SRIgnoreIncomplete* ignoreIncomplete; 397 398 398 399 ScheduledRecording *schedRec; 399 400 }; … … 719 720 } 720 721 }; 721 722 723 class SRIgnoreIncomplete: public SRBoolSetting 724 { 725 public: 726 SRIgnoreIncomplete(ScheduledRecording *_parent, ManagedListGroup* _group, ManagedList* _list) 727 : SRBoolSetting(_parent, QObject::tr("Ignore generic episodes"), 728 QObject::tr("Record generic episodes"), 729 "ignoreIncompleteItem", "ignoreincomplete", _group, _list ) 730 { 731 _parent->setIgnoreIncompleteObj(this); 732 } 733 }; 734 722 735 class SRInactive: public SRBoolSetting 723 736 { 724 737 public: -
libs/libmythtv/scheduledrecording.cpp
58 58 dupin = NULL; 59 59 dupmethod = NULL; 60 60 autoexpire = NULL; 61 ignoreincomplete = NULL; 61 62 autotranscode = NULL; 62 63 transcoder = NULL; 63 64 autocommflag = NULL; … … 426 427 autoexpire->setValue(expire); 427 428 } 428 429 430 int ScheduledRecording::GetIgnoreIncomplete(void) const { 431 return(ignoreincomplete->getValue().toInt()); 432 } 433 434 void ScheduledRecording::SetIgnoreIncomplete(int expire) { 435 ignoreincomplete->setValue(expire); 436 } 437 429 438 int ScheduledRecording::GetTranscoder(void) const { 430 439 return transcoder->getValue().toInt(); 431 440 } … … 855 864 recpriority->setValue(0); 856 865 857 866 autoexpire->setValue(gContext->GetNumSetting("AutoExpireDefault", 0)); 867 ignoreincomplete->setValue(gContext->GetNumSetting("IgnoreIncompleteDefault", 0)); 858 868 859 869 autotranscode->setValue(gContext->GetNumSetting("AutoTranscode", 0)); 860 870 transcoder->fillSelections(); … … 944 954 dupin->setChanged(); 945 955 dupmethod->setChanged(); 946 956 autoexpire->setChanged(); 957 ignoreincomplete->setChanged(); 947 958 autotranscode->setChanged(); 948 959 autocommflag->setChanged(); 949 960 autouserjob1->setChanged(); -
programs/mythbackend/scheduler.cpp
2750 2750 "program.videoprop+0, program.subtitletypes+0, program.audioprop+0, " 2751 2751 "RECTABLE.storagegroup, capturecard.hostname, recordmatch.oldrecstatus, " + 2752 2752 pwrpri + QString( 2753 ", RECTABLE.ignoreincomplete " 2753 2754 "FROM recordmatch " 2754 2755 " INNER JOIN RECTABLE ON (recordmatch.recordid = RECTABLE.recordid) " 2755 2756 " INNER JOIN program ON (recordmatch.chanid = program.chanid AND " … … 2922 2923 if ((p->dupin & kDupsNewEpi) && p->repeat) 2923 2924 p->recstatus = rsRepeat; 2924 2925 2926 2927 // If we want to ignore episodes in series with bogus data. 2928 // Unfortunately the 'generic' flag doesn't work very well, since 2929 // since it is not set if there is a generic description. More fundamentally, 2930 // you need to know which of subtitle and/or description are expected before 2931 // you can determine if a program entry is generic. In this test 2932 // if you match on subtitle AND desctiption, BOTH must be set or it's 2933 // treated as generic. 2934 QRegExp exp(".*0000"); 2935 QString series("series"); 2936 2937 if (result.value(46).toInt() && p->category.compare(series) && p->programid.contains(exp)) { 2938 if( (p->dupmethod & 0x2 && p->subtitle.isEmpty()) || 2939 (p->dupmethod & 0x4 && p->description.isEmpty()) ) 2940 p->recstatus = rsRepeat; 2941 } 2942 2925 2943 if ((p->dupin & kDupsInOldRecorded) && result.value(10).toInt()) 2926 2944 { 2927 2945 if (result.value(44).toInt() == rsNeverRecord) … … 2929 2947 else 2930 2948 p->recstatus = rsPreviousRecording; 2931 2949 } 2950 2951 /* finddulicate */ 2932 2952 if ((p->dupin & kDupsInRecorded) && result.value(14).toInt()) 2933 2953 p->recstatus = rsCurrentRecording; 2934 2954 }