diff options
author | Carlos Garcia Campos <carlosgc@gnome.org> | 2010-12-30 13:59:14 +0100 |
---|---|---|
committer | Carlos Garcia Campos <carlosgc@gnome.org> | 2011-01-08 11:01:20 +0100 |
commit | 0bac1fe06a00ae1d1d01e814b039c9dbde356479 (patch) | |
tree | 4d07e47183c88dd7528795e099c2d8be3492751c | |
parent | e1d489a714f4f1b899b461e8ad13a30c0ce28d64 (diff) | |
download | totem-0bac1fe06a00ae1d1d01e814b039c9dbde356479.tar.gz |
Register totem thumbnailer
This was removed in commit 9b403af7a43fe953dd6237f69a378086bd05d087 when
migrating to GSettings. This is a new version that doesn't use GConf.
Closes: bgo#638346.
-rw-r--r-- | data/Makefile.am | 16 | ||||
-rwxr-xr-x | data/thumbnailer.sh | 21 | ||||
-rw-r--r-- | data/totem.thumbnailer.in | 3 |
3 files changed, 40 insertions, 0 deletions
diff --git a/data/Makefile.am b/data/Makefile.am index 068a83978..a4dc0d7d0 100644 --- a/data/Makefile.am +++ b/data/Makefile.am @@ -65,6 +65,22 @@ CLEANFILES += \ $(desktop_in_files) \ $(desktop_DATA) +# Thumbnailer +thumbnailerdir = $(datadir)/thumbnailers +thumbnailer_in_files = totem.thumbnailer.in +thumbnailer_DATA = $(thumbnailer_in_files:.thumbnailer.in=.thumbnailer) + +totem.thumbnailer: $(thumbnailer_in_files) mime-type-list.txt thumbnailer.sh + $(AM_V_GEN)sed -e "s|\@BINDIR\@|$(bindir)|" $< > $@ &&\ + $(SHELL) $(srcdir)/thumbnailer.sh $(srcdir)/mime-type-list.txt >> $@ + +EXTRA_DIST += \ + $(thumbnailer_in_files) \ + thumbnailer.sh + +CLEANFILES += \ + $(thumbnailer_DATA) + # Content type handling nodist_noinst_HEADERS = totem-mime-types.h nautilus-audio-mime-types.h totem-mime-types.h: mime-type-include.sh mime-type-list.txt mime-functions.sh diff --git a/data/thumbnailer.sh b/data/thumbnailer.sh new file mode 100755 index 000000000..30b64a249 --- /dev/null +++ b/data/thumbnailer.sh @@ -0,0 +1,21 @@ +#!/bin/sh + +. `dirname $0`/mime-functions.sh + +echo_mime () { + printf "$i;"; +} + +printf MimeType=; + +get_video_mimetypes $1; +for i in $MIMETYPES ; do + echo_mime; +done + +get_audio_mimetypes $1; +for i in $MIMETYPES ; do + echo_mime; +done + +echo "" diff --git a/data/totem.thumbnailer.in b/data/totem.thumbnailer.in new file mode 100644 index 000000000..45be6e244 --- /dev/null +++ b/data/totem.thumbnailer.in @@ -0,0 +1,3 @@ +[Thumbnailer Entry] +TryExec=@BINDIR@/totem-video-thumbnailer +Exec=@BINDIR@/totem-video-thumbnailer -s %s %u %o |