info: improve tag filtering
Hide duration as well. Also skip all tags where the name starts with "private-".
This commit is contained in:
parent
fa4693f2e0
commit
0b6303a667
@ -96,8 +96,9 @@ public class MediaInfo.Info : VBox
|
|||||||
// tags to skip (already extraced to specific discoverer fields)
|
// tags to skip (already extraced to specific discoverer fields)
|
||||||
tag_black_list = new HashSet<string> ();
|
tag_black_list = new HashSet<string> ();
|
||||||
tag_black_list.add ("bitrate");
|
tag_black_list.add ("bitrate");
|
||||||
tag_black_list.add ("maximum-bitrate");
|
|
||||||
tag_black_list.add ("container-format");
|
tag_black_list.add ("container-format");
|
||||||
|
tag_black_list.add ("duration");
|
||||||
|
tag_black_list.add ("maximum-bitrate");
|
||||||
|
|
||||||
// add widgets
|
// add widgets
|
||||||
// FIXME: handle aspect ratio (AspectFrame.ratio)
|
// FIXME: handle aspect ratio (AspectFrame.ratio)
|
||||||
@ -538,13 +539,18 @@ public class MediaInfo.Info : VBox
|
|||||||
string str, fn, vstr;
|
string str, fn, vstr;
|
||||||
Gst.Value v;
|
Gst.Value v;
|
||||||
|
|
||||||
// TODO: remove some binary tags
|
// TODO: add special handling for certain tags
|
||||||
|
// image, uris, ...
|
||||||
|
|
||||||
str = "";
|
str = "";
|
||||||
for (i = 0; i < s.n_fields(); i++) {
|
for (i = 0; i < s.n_fields(); i++) {
|
||||||
fn = s.nth_field_name (i);
|
fn = s.nth_field_name (i);
|
||||||
|
// skip a few tags
|
||||||
if (tag_black_list.contains (fn))
|
if (tag_black_list.contains (fn))
|
||||||
continue;
|
continue;
|
||||||
|
if (fn.has_prefix("private-"))
|
||||||
|
continue;
|
||||||
|
|
||||||
if (str.length > 0)
|
if (str.length > 0)
|
||||||
str += "\n";
|
str += "\n";
|
||||||
v = s.get_value (fn);
|
v = s.get_value (fn);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user