[pitivi] Register the text/x-xptv mime type, and set pitivi as its default app.



commit 74a33863295988d3584917453cc698208e68bcbd
Author: Alessandro Decina <alessandro d gmail com>
Date:   Thu Apr 30 15:32:48 2009 +0200

    Register the text/x-xptv mime type, and set pitivi as its default app.
---
 Makefile.am       |    3 +++
 pitivi.desktop.in |    1 +
 pitivi.xml        |   11 +++++++++++
 3 files changed, 15 insertions(+), 0 deletions(-)

diff --git a/Makefile.am b/Makefile.am
index 325e755..0bc2366 100755
--- a/Makefile.am
+++ b/Makefile.am
@@ -8,6 +8,9 @@ desktop_DATA = pitivi.desktop
 icondir = $(datadir)/pixmaps
 icon_DATA = pitivi.png
 
+mimedir = $(datadir)/mime/packages
+mime_DATA = pitivi.xml
+
 EXTRA_DIST = \
 	pitivi.spec \
 	pitivi.spec.in \
diff --git a/pitivi.desktop.in b/pitivi.desktop.in
index dbfad20..ecca60e 100644
--- a/pitivi.desktop.in
+++ b/pitivi.desktop.in
@@ -7,6 +7,7 @@ Exec=pitivi
 Terminal=false
 Type=Application
 Icon=pitivi.png
+MimeType=text/x-xptv
 Categories=GNOME;GTK;Application;AudioVideo;X-Ximian-Main;X-Red-Hat-Base;
 StartupNotify=true
 X-GNOME-Bugzilla-Bugzilla=GNOME
diff --git a/pitivi.xml b/pitivi.xml
new file mode 100644
index 0000000..41e3162
--- /dev/null
+++ b/pitivi.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<mime-info xmlns='http://www.freedesktop.org/standards/shared-mime-info'>
+	<mime-type type="text/x-xptv">
+		<sub-class-of type="text/plain"/>
+		<comment>PiTiVi Project File</comment>
+		<glob pattern="*.xptv"/>
+        <magic priority="20">
+            <match value="&lt;pitivi" type="string" offset="0"/>
+        </magic>
+	</mime-type>
+</mime-info>



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]