After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 390991 - Add filter for supported audio and video files
Add filter for supported audio and video files
Status: RESOLVED FIXED
Product: totem
Classification: Core
Component: general
2.17.x
Other Linux
: Normal enhancement
: ---
Assigned To: General Totem maintainer(s)
General Totem maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2006-12-30 14:59 UTC by Hendrik Richter
Modified: 2007-02-06 15:36 UTC
See Also:
GNOME target: ---
GNOME version: 2.17/2.18


Attachments
Patch to this bug (4.78 KB, patch)
2006-12-30 15:10 UTC, Hendrik Richter
rejected Details | Review

Description Hendrik Richter 2006-12-30 14:59:39 UTC
In addition to the existing filters "All files" and "Supported files" Totem should offer filters to only show supported audio or video files in the file chooser.

Use case:
While surfing the web you randomly download video files from fun sites and music from an online music store. When you want to listen to your new music you don't care about the videos, and vice versa. Hence it would be nice to only see music or video files, but not both.
Comment 1 Hendrik Richter 2006-12-30 15:10:13 UTC
Created attachment 79066 [details] [review]
Patch to this bug
Comment 2 Hendrik Richter 2006-12-30 15:21:35 UTC
This patch splits data/mime-type-list.txt into two seperate files for audio and video files. Though not perfect for every possible container format it should work well enough for most cases and media files.

But I have to admit that I don't know if it's wise to now have three char arrays in the generated data/totem-mime-types.h or if it's better to iterate both mime_types_audio and mime_types_video when needed and get rid of mime_types.

Comments appreciated.
Comment 3 Bastien Nocera 2007-01-04 16:15:25 UTC
schemas.sh already has some code to "split" the video and audio files.

I think it'd be easier to use the same logic (and possibly share it), rather than having 2 new files.
Comment 4 Bastien Nocera 2007-02-06 15:36:11 UTC
2007-02-06  Bastien Nocera  <hadess@hadess.net>

        * data/Makefile.am:
        * data/mime-functions.sh:
        * data/mime-type-include.sh:
        * data/mime-type-list.txt:
        * data/schemas.sh:
        * src/totem-uri.c: (totem_setup_file_filters),
        (totem_destroy_file_filters), (totem_add_files):
        Move functions to split the mime-types in video/audio types to
        mime-functions.sh, add "Audio files" and "Video files" filters
        to the Open dialogues (Closes: #390991)