diff options
| author | Carl Hetherington <cth@carlh.net> | 2018-07-22 00:41:03 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2018-07-22 00:41:03 +0100 |
| commit | dea824f6ff41384a5e17e23de5434cf84eccff29 (patch) | |
| tree | a40207882d506417cb5f456135b9ba4394535d00 /src/lib/dcp_content.cc | |
| parent | 9cbe57dda759fccfa9dec8a0820114d7d8583a36 (diff) | |
Display only required tabs, including subs / ccap.
Diffstat (limited to 'src/lib/dcp_content.cc')
| -rw-r--r-- | src/lib/dcp_content.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/lib/dcp_content.cc b/src/lib/dcp_content.cc index e56ad9e21..414a22256 100644 --- a/src/lib/dcp_content.cc +++ b/src/lib/dcp_content.cc @@ -191,8 +191,10 @@ DCPContent::examine (shared_ptr<Job> job) { boost::mutex::scoped_lock lm (_mutex); _name = examiner->name (); - for (int i = 0; i < examiner->captions(); ++i) { - caption.push_back (shared_ptr<CaptionContent> (new CaptionContent (this))); + for (int i = 0; i < CAPTION_COUNT; ++i) { + if (examiner->has_caption(static_cast<CaptionType>(i))) { + caption.push_back (shared_ptr<CaptionContent>(new CaptionContent(this, static_cast<CaptionType>(i)))); + } } captions = caption.size (); _encrypted = examiner->encrypted (); |
