From 55a67a082e13976476bdf8af30431c838bc16a5b Mon Sep 17 00:00:00 2001 From: Albert Astals Cid Date: Fri, 6 Apr 2007 21:47:06 +0000 Subject: [PATCH] Each plugin installs a application desktop so that the supported mimetypes are exactly the ones supported by the plugins installed svn path=/trunk/KDE/kdegraphics/okular/; revision=651194 --- generators/chm/CMakeLists.txt | 1 + generators/chm/okularApplication_chm.desktop | 13 +++++++++++++ generators/comicbook/CMakeLists.txt | 1 + .../comicbook/okularApplication_comicbook.desktop | 13 +++++++++++++ generators/djvu/CMakeLists.txt | 1 + generators/djvu/okularApplication_djvu.desktop | 13 +++++++++++++ generators/dvi/CMakeLists.txt | 1 + generators/dvi/okularApplication_dvi.desktop | 13 +++++++++++++ generators/fictionbook/CMakeLists.txt | 1 + generators/fictionbook/okularApplication_fb.desktop | 13 +++++++++++++ generators/ghostview/CMakeLists.txt | 1 + .../ghostview/okularApplication_ghostview.desktop | 13 +++++++++++++ generators/kimgio/CMakeLists.txt | 1 + generators/kimgio/okularApplication_kimgio.desktop | 13 +++++++++++++ generators/ooo/CMakeLists.txt | 1 + generators/ooo/okularApplication_ooo.desktop | 13 +++++++++++++ generators/plucker/CMakeLists.txt | 1 + .../plucker/okularApplication_plucker.desktop | 13 +++++++++++++ generators/poppler/CMakeLists.txt | 1 + generators/poppler/okularApplication_pdf.desktop | 13 +++++++++++++ generators/tiff/CMakeLists.txt | 1 + generators/tiff/okularApplication_tiff.desktop | 13 +++++++++++++ generators/xps/CMakeLists.txt | 3 ++- generators/xps/okularApplication_xps.desktop | 13 +++++++++++++ shell/okular.desktop | 2 -- 25 files changed, 169 insertions(+), 3 deletions(-) create mode 100644 generators/chm/okularApplication_chm.desktop create mode 100644 generators/comicbook/okularApplication_comicbook.desktop create mode 100644 generators/djvu/okularApplication_djvu.desktop create mode 100644 generators/dvi/okularApplication_dvi.desktop create mode 100644 generators/fictionbook/okularApplication_fb.desktop create mode 100644 generators/ghostview/okularApplication_ghostview.desktop create mode 100644 generators/kimgio/okularApplication_kimgio.desktop create mode 100644 generators/ooo/okularApplication_ooo.desktop create mode 100644 generators/plucker/okularApplication_plucker.desktop create mode 100644 generators/poppler/okularApplication_pdf.desktop create mode 100644 generators/tiff/okularApplication_tiff.desktop create mode 100644 generators/xps/okularApplication_xps.desktop diff --git a/generators/chm/CMakeLists.txt b/generators/chm/CMakeLists.txt index daf9e67d7..77444ec4b 100644 --- a/generators/chm/CMakeLists.txt +++ b/generators/chm/CMakeLists.txt @@ -36,4 +36,5 @@ install(TARGETS okularGenerator_chmlib DESTINATION ${PLUGIN_INSTALL_DIR}) ########### install files ############### install( FILES libokularGenerator_chmlib.desktop okularChm.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) +install( FILES okularApplication_chm.desktop DESTINATION ${XDG_APPS_DIR} ) diff --git a/generators/chm/okularApplication_chm.desktop b/generators/chm/okularApplication_chm.desktop new file mode 100644 index 000000000..567a3c42c --- /dev/null +++ b/generators/chm/okularApplication_chm.desktop @@ -0,0 +1,13 @@ +[Desktop Entry] +Encoding=UTF-8 +MimeType=application/x-chm +Terminal=false +Name=okular +GenericName=Document Viewer +Exec=okular %U %i -caption "%c" +Icon=okular +Type=Application +DocPath=okular/index.html +InitialPreference=7 +Categories=Qt;KDE;Graphics;Viewer; +NoDisplay=true diff --git a/generators/comicbook/CMakeLists.txt b/generators/comicbook/CMakeLists.txt index 1cc9b1838..8351151f9 100644 --- a/generators/comicbook/CMakeLists.txt +++ b/generators/comicbook/CMakeLists.txt @@ -23,4 +23,5 @@ install(TARGETS okularGenerator_comicbook DESTINATION ${PLUGIN_INSTALL_DIR}) ########### install files ############### install( FILES libokularGenerator_comicbook.desktop okularComicbook.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) +install( FILES okularApplication_comicbook.desktop DESTINATION ${XDG_APPS_DIR} ) diff --git a/generators/comicbook/okularApplication_comicbook.desktop b/generators/comicbook/okularApplication_comicbook.desktop new file mode 100644 index 000000000..96cd70b5c --- /dev/null +++ b/generators/comicbook/okularApplication_comicbook.desktop @@ -0,0 +1,13 @@ +[Desktop Entry] +Encoding=UTF-8 +MimeType=application/x-cbz;application/x-cbr; +Terminal=false +Name=okular +GenericName=Document Viewer +Exec=okular %U %i -caption "%c" +Icon=okular +Type=Application +DocPath=okular/index.html +InitialPreference=7 +Categories=Qt;KDE;Graphics;Viewer; +NoDisplay=true diff --git a/generators/djvu/CMakeLists.txt b/generators/djvu/CMakeLists.txt index 31bd24859..2db24d0fe 100644 --- a/generators/djvu/CMakeLists.txt +++ b/generators/djvu/CMakeLists.txt @@ -24,5 +24,6 @@ install(TARGETS okularGenerator_djvu DESTINATION ${PLUGIN_INSTALL_DIR}) ########### install files ############### install( FILES libokularGenerator_djvu.desktop okularDjvu.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) +install( FILES okularApplication_djvu.desktop DESTINATION ${XDG_APPS_DIR} ) diff --git a/generators/djvu/okularApplication_djvu.desktop b/generators/djvu/okularApplication_djvu.desktop new file mode 100644 index 000000000..f99118553 --- /dev/null +++ b/generators/djvu/okularApplication_djvu.desktop @@ -0,0 +1,13 @@ +[Desktop Entry] +Encoding=UTF-8 +MimeType=image/vnd.djvu +Terminal=false +Name=okular +GenericName=Document Viewer +Exec=okular %U %i -caption "%c" +Icon=okular +Type=Application +DocPath=okular/index.html +InitialPreference=7 +Categories=Qt;KDE;Graphics;Viewer; +NoDisplay=true diff --git a/generators/dvi/CMakeLists.txt b/generators/dvi/CMakeLists.txt index 93cbc1dc4..1be606ef8 100644 --- a/generators/dvi/CMakeLists.txt +++ b/generators/dvi/CMakeLists.txt @@ -61,4 +61,5 @@ install(TARGETS okularGenerator_dvi DESTINATION ${PLUGIN_INSTALL_DIR}) ########### install files ############### install( FILES libokularGenerator_dvi.desktop okularDvi.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) +install( FILES okularApplication_dvi.desktop DESTINATION ${XDG_APPS_DIR} ) diff --git a/generators/dvi/okularApplication_dvi.desktop b/generators/dvi/okularApplication_dvi.desktop new file mode 100644 index 000000000..492d67a2c --- /dev/null +++ b/generators/dvi/okularApplication_dvi.desktop @@ -0,0 +1,13 @@ +[Desktop Entry] +Encoding=UTF-8 +MimeType=application/x-dvi +Terminal=false +Name=okular +GenericName=Document Viewer +Exec=okular %U %i -caption "%c" +Icon=okular +Type=Application +DocPath=okular/index.html +InitialPreference=7 +Categories=Qt;KDE;Graphics;Viewer; +NoDisplay=true diff --git a/generators/fictionbook/CMakeLists.txt b/generators/fictionbook/CMakeLists.txt index 2e983efc6..c1d6e2fc3 100644 --- a/generators/fictionbook/CMakeLists.txt +++ b/generators/fictionbook/CMakeLists.txt @@ -24,3 +24,4 @@ install(TARGETS okularGenerator_fb DESTINATION ${PLUGIN_INSTALL_DIR}) ########### install files ############### install( FILES libokularGenerator_fb.desktop okularFb.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) +install( FILES okularApplication_fb.desktop DESTINATION ${XDG_APPS_DIR} ) diff --git a/generators/fictionbook/okularApplication_fb.desktop b/generators/fictionbook/okularApplication_fb.desktop new file mode 100644 index 000000000..de44a3f51 --- /dev/null +++ b/generators/fictionbook/okularApplication_fb.desktop @@ -0,0 +1,13 @@ +[Desktop Entry] +Encoding=UTF-8 +MimeType=application/x-fb +Terminal=false +Name=okular +GenericName=Document Viewer +Exec=okular %U %i -caption "%c" +Icon=okular +Type=Application +DocPath=okular/index.html +InitialPreference=7 +Categories=Qt;KDE;Graphics;Viewer; +NoDisplay=true diff --git a/generators/ghostview/CMakeLists.txt b/generators/ghostview/CMakeLists.txt index 2a82eecfe..3a9afacee 100644 --- a/generators/ghostview/CMakeLists.txt +++ b/generators/ghostview/CMakeLists.txt @@ -53,4 +53,5 @@ install(TARGETS okularGenerator_ghostview DESTINATION ${PLUGIN_INSTALL_DIR}) ########### install files ############### install( FILES libokularGenerator_ghostview.desktop okularGhostview.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) +install( FILES okularApplication_ghostview.desktop DESTINATION ${XDG_APPS_DIR} ) diff --git a/generators/ghostview/okularApplication_ghostview.desktop b/generators/ghostview/okularApplication_ghostview.desktop new file mode 100644 index 000000000..1c5cc841b --- /dev/null +++ b/generators/ghostview/okularApplication_ghostview.desktop @@ -0,0 +1,13 @@ +[Desktop Entry] +Encoding=UTF-8 +MimeType=application/postscript;image/x-eps; +Terminal=false +Name=okular +GenericName=Document Viewer +Exec=okular %U %i -caption "%c" +Icon=okular +Type=Application +DocPath=okular/index.html +InitialPreference=7 +Categories=Qt;KDE;Graphics;Viewer; +NoDisplay=true diff --git a/generators/kimgio/CMakeLists.txt b/generators/kimgio/CMakeLists.txt index 0c23e8f7d..92233c67f 100644 --- a/generators/kimgio/CMakeLists.txt +++ b/generators/kimgio/CMakeLists.txt @@ -19,4 +19,5 @@ install(TARGETS okularGenerator_kimgio DESTINATION ${PLUGIN_INSTALL_DIR}) ########### install files ############### install( FILES libokularGenerator_kimgio.desktop okularKimgio.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) +install( FILES okularApplication_kimgio.desktop DESTINATION ${XDG_APPS_DIR} ) diff --git a/generators/kimgio/okularApplication_kimgio.desktop b/generators/kimgio/okularApplication_kimgio.desktop new file mode 100644 index 000000000..f7f9d12d3 --- /dev/null +++ b/generators/kimgio/okularApplication_kimgio.desktop @@ -0,0 +1,13 @@ +[Desktop Entry] +Encoding=UTF-8 +MimeType=image/bmp;image/x-dds;image/x-eps;image/x-exr;image/gif;image/x-hdr;image/x-ico;image/jpeg2000;image/jpeg;video/x-mng;image/x-portable-bitmap;image/x-pcx;image/x-portable-graymap;image/png;image/x-portable-pixmap;image/x-psd;image/x-rgb;image/x-tga;image/tiff;image/x-xbitmap;image/x-xcf;image/x-xpixmap; +Terminal=false +Name=okular +GenericName=Document Viewer +Exec=okular %U %i -caption "%c" +Icon=okular +Type=Application +DocPath=okular/index.html +InitialPreference=7 +Categories=Qt;KDE;Graphics;Viewer; +NoDisplay=true diff --git a/generators/ooo/CMakeLists.txt b/generators/ooo/CMakeLists.txt index 19e79eece..fcb0cb21e 100644 --- a/generators/ooo/CMakeLists.txt +++ b/generators/ooo/CMakeLists.txt @@ -27,4 +27,5 @@ install(TARGETS okularGenerator_ooo DESTINATION ${PLUGIN_INSTALL_DIR}) ########### install files ############### install( FILES libokularGenerator_ooo.desktop okularOoo.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) +install( FILES okularApplication_ooo.desktop DESTINATION ${XDG_APPS_DIR} ) diff --git a/generators/ooo/okularApplication_ooo.desktop b/generators/ooo/okularApplication_ooo.desktop new file mode 100644 index 000000000..2b85d2cf4 --- /dev/null +++ b/generators/ooo/okularApplication_ooo.desktop @@ -0,0 +1,13 @@ +[Desktop Entry] +Encoding=UTF-8 +MimeType=application/vnd.oasis.opendocument.text +Terminal=false +Name=okular +GenericName=Document Viewer +Exec=okular %U %i -caption "%c" +Icon=okular +Type=Application +DocPath=okular/index.html +InitialPreference=7 +Categories=Qt;KDE;Graphics;Viewer; +NoDisplay=true diff --git a/generators/plucker/CMakeLists.txt b/generators/plucker/CMakeLists.txt index 5b7edbc62..f4e33a56b 100644 --- a/generators/plucker/CMakeLists.txt +++ b/generators/plucker/CMakeLists.txt @@ -31,4 +31,5 @@ install(TARGETS okularGenerator_plucker DESTINATION ${PLUGIN_INSTALL_DIR}) ########### install files ############### install( FILES libokularGenerator_plucker.desktop okularPlucker.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) +install( FILES okularApplication_plucker.desktop DESTINATION ${XDG_APPS_DIR} ) diff --git a/generators/plucker/okularApplication_plucker.desktop b/generators/plucker/okularApplication_plucker.desktop new file mode 100644 index 000000000..2753084d5 --- /dev/null +++ b/generators/plucker/okularApplication_plucker.desktop @@ -0,0 +1,13 @@ +[Desktop Entry] +Encoding=UTF-8 +MimeType=application/prs.plucker +Terminal=false +Name=okular +GenericName=Document Viewer +Exec=okular %U %i -caption "%c" +Icon=okular +Type=Application +DocPath=okular/index.html +InitialPreference=7 +Categories=Qt;KDE;Graphics;Viewer; +NoDisplay=true diff --git a/generators/poppler/CMakeLists.txt b/generators/poppler/CMakeLists.txt index 2f80a977e..0c7349f0e 100644 --- a/generators/poppler/CMakeLists.txt +++ b/generators/poppler/CMakeLists.txt @@ -30,4 +30,5 @@ install(TARGETS okularGenerator_poppler DESTINATION ${PLUGIN_INSTALL_DIR}) ########### install files ############### install( FILES libokularGenerator_poppler.desktop okularPoppler.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) +install( FILES okularApplication_pdf.desktop DESTINATION ${XDG_APPS_DIR} ) diff --git a/generators/poppler/okularApplication_pdf.desktop b/generators/poppler/okularApplication_pdf.desktop new file mode 100644 index 000000000..4d10f88d1 --- /dev/null +++ b/generators/poppler/okularApplication_pdf.desktop @@ -0,0 +1,13 @@ +[Desktop Entry] +Encoding=UTF-8 +MimeType=application/pdf +Terminal=false +Name=okular +GenericName=Document Viewer +Exec=okular %U %i -caption "%c" +Icon=okular +Type=Application +DocPath=okular/index.html +InitialPreference=7 +Categories=Qt;KDE;Graphics;Viewer; +NoDisplay=true diff --git a/generators/tiff/CMakeLists.txt b/generators/tiff/CMakeLists.txt index a661ef3a5..54f704532 100644 --- a/generators/tiff/CMakeLists.txt +++ b/generators/tiff/CMakeLists.txt @@ -22,4 +22,5 @@ install(TARGETS okularGenerator_tiff DESTINATION ${PLUGIN_INSTALL_DIR}) ########### install files ############### install( FILES libokularGenerator_tiff.desktop okularTiff.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) +install( FILES okularApplication_tiff.desktop DESTINATION ${XDG_APPS_DIR} ) diff --git a/generators/tiff/okularApplication_tiff.desktop b/generators/tiff/okularApplication_tiff.desktop new file mode 100644 index 000000000..5b3ad3295 --- /dev/null +++ b/generators/tiff/okularApplication_tiff.desktop @@ -0,0 +1,13 @@ +[Desktop Entry] +Encoding=UTF-8 +MimeType=image/tiff +Terminal=false +Name=okular +GenericName=Document Viewer +Exec=okular %U %i -caption "%c" +Icon=okular +Type=Application +DocPath=okular/index.html +InitialPreference=7 +Categories=Qt;KDE;Graphics;Viewer; +NoDisplay=true diff --git a/generators/xps/CMakeLists.txt b/generators/xps/CMakeLists.txt index 316ca0259..6d335014e 100644 --- a/generators/xps/CMakeLists.txt +++ b/generators/xps/CMakeLists.txt @@ -20,5 +20,6 @@ install(TARGETS okularGenerator_xps DESTINATION ${PLUGIN_INSTALL_DIR}) ########### install files ############### -install( FILES libokularGenerator_xps.desktop okularXps.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) +install( FILES libokularGenerator_xps.desktop okularXps.desktop DESTINATION ${SERVICES_INSTALL_DIR} ) +install( FILES okularApplication_xps.desktop DESTINATION ${XDG_APPS_DIR} ) diff --git a/generators/xps/okularApplication_xps.desktop b/generators/xps/okularApplication_xps.desktop new file mode 100644 index 000000000..31f85ab39 --- /dev/null +++ b/generators/xps/okularApplication_xps.desktop @@ -0,0 +1,13 @@ +[Desktop Entry] +Encoding=UTF-8 +MimeType=application/vnd.ms-xpsdocument +Terminal=false +Name=okular +GenericName=Document Viewer +Exec=okular %U %i -caption "%c" +Icon=okular +Type=Application +DocPath=okular/index.html +InitialPreference=7 +Categories=Qt;KDE;Graphics;Viewer; +NoDisplay=true diff --git a/shell/okular.desktop b/shell/okular.desktop index e8d003c09..bbfff09f8 100644 --- a/shell/okular.desktop +++ b/shell/okular.desktop @@ -1,6 +1,5 @@ [Desktop Entry] Encoding=UTF-8 -MimeType=application/pdf Terminal=false Name=okular GenericName=Document Viewer @@ -14,4 +13,3 @@ Type=Application DocPath=okular/index.html InitialPreference=7 Categories=Qt;KDE;Graphics;Viewer; -