Permalink
Browse files

Refs #10649. Minor rejigging of [bf7b838]; move toString() implementa…

…tion to .cpp and make more consistend with atsc/scte output.
  • Loading branch information...
daniel-kristjansson committed Jun 14, 2012
1 parent bf7b838 commit 0c8872998b191869f0c275310cc1362848ba512c
Showing with 21 additions and 12 deletions.
  1. +20 −0 mythtv/libs/libmythtv/mpeg/dvbdescriptors.cpp
  2. +1 −12 mythtv/libs/libmythtv/mpeg/dvbdescriptors.h
@@ -440,6 +440,26 @@ QString ServiceDescriptorMapping::toString() const
return str;
}
+QString TeletextDescriptor::toString(void) const
+{
+ QString str = QString("Teletext Descriptor: %1 pages")
+ .arg(StreamCount());
+
+ for (uint i = 0; i < StreamCount(); i++)
+ {
+ if (1 != StreamCount())
+ str.append("\n ");
+
+ str.append(QString(" type(%1) mag(%2) page(%3) lang(%4)")
+ .arg(TeletextType(i))
+ .arg(TeletextMagazineNum(i), 0, 16)
+ .arg(TeletextPageNum(i), 2, 16, QChar('0'))
+ .arg(LanguageString(i)));
+ }
+
+ return str;
+}
+
QString CableDeliverySystemDescriptor::toString() const
{
QString str = QString("CableDeliverySystemDescriptor: ");
@@ -1797,18 +1797,7 @@ class TeletextDescriptor : public MPEGDescriptor
uint TeletextPageNum(uint i) const
{ return _data[6 + (i*5)]; }
// } 5.0
- QString toString(void) const
- {
- QString str = QString("Teletext Descriptor: %1 pages\n")
- .arg(StreamCount());
- for (uint i=0; i<StreamCount(); i++)
- {
- if (i!=0) str.append("\n");
- str.append(QString(" Type (%1) Magazine (%2) Page (%3) Language (%4)").arg(TeletextType(i))
- .arg(TeletextMagazineNum(i), 0, 16).arg(TeletextPageNum(i), 2, 16, QChar('0')).arg(LanguageString(i)));
- }
- return str;
- }
+ QString toString(void) const;
};
// DVB Bluebook A038 (Sept 2011) p 89

0 comments on commit 0c88729

Please sign in to comment.