From 47c2f936d8823148bdbd45917af43e55a39bfc95 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sl=C3=A1vek=20Banko?= Date: Tue, 24 Mar 2020 16:51:10 +0100 Subject: Desktop file translations: + Creation of POT template for desktop files added to CMakeL10n rules. + Added creation of translated desktop files during build. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Slávek Banko (cherry picked from commit c5a99d8b5eb021416b571874a1591753df9669cc) --- src/CMakeL10n.txt | 5 +++ src/CMakeLists.txt | 22 +++++++++----- translations/desktop_files/tdeio-apt-desktops.pot | 37 +++++++++++++++++++++++ 3 files changed, 56 insertions(+), 8 deletions(-) create mode 100644 translations/desktop_files/tdeio-apt-desktops.pot diff --git a/src/CMakeL10n.txt b/src/CMakeL10n.txt index 058043e..e7bf2af 100644 --- a/src/CMakeL10n.txt +++ b/src/CMakeL10n.txt @@ -1,3 +1,8 @@ ##### create translation templates ############## tde_l10n_create_template( "messages/tdeio-apt" ) + +tde_l10n_create_template( + CATALOG "desktop_files/tdeio-apt-desktops" + SOURCES *.protocol *.desktop +) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 95624d8..7d9cf9e 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -37,17 +37,23 @@ tde_add_kpart( tdeio_apt MODULE AUTOMOC ##### other data -install( - FILES apt.protocol apt+http.protocol +foreach( _protocol apt.protocol apt+http.protocol ) + tde_create_translated_desktop( + SOURCE ${_protocol} DESTINATION ${SERVICES_INSTALL_DIR} -) + PO_DIR ${CMAKE_SOURCE_DIR}/translations/desktop_files + ) +endforeach( ) + +foreach( _desktop apt-file.desktop apt-files.desktop apt-search.desktop ) + tde_create_translated_desktop( + SOURCE ${_desktop} + DESTINATION ${SERVICES_INSTALL_DIR}/searchproviders + PO_DIR ${CMAKE_SOURCE_DIR}/translations/desktop_files + ) +endforeach( ) install( FILES tdeio_apt.css tdedeb_logo.png DESTINATION ${DATA_INSTALL_DIR}/tdeio_apt/ ) - -install( - FILES apt-search.desktop apt-file.desktop apt-files.desktop - DESTINATION ${SERVICES_INSTALL_DIR}/searchproviders -) diff --git a/translations/desktop_files/tdeio-apt-desktops.pot b/translations/desktop_files/tdeio-apt-desktops.pot new file mode 100644 index 0000000..b6e481f --- /dev/null +++ b/translations/desktop_files/tdeio-apt-desktops.pot @@ -0,0 +1,37 @@ +# SOME DESCRIPTIVE TITLE. +# This file is put in the public domain. +# FIRST AUTHOR , YEAR. +# +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2020-03-24 16:31+0100\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" +"Last-Translator: FULL NAME \n" +"Language-Team: LANGUAGE \n" +"Language: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#. Description +#: apt+http.protocol:9 apt.protocol:9 +msgid "A tdeioslave for using apt-cache functionalities inside konqueror" +msgstr "" + +#. Name +#: apt-file.desktop:5 +msgid "APT - Find File" +msgstr "" + +#. Name +#: apt-files.desktop:5 +msgid "APT - Filelist" +msgstr "" + +#. Name +#: apt-search.desktop:5 +msgid "APT - Search Package" +msgstr "" -- cgit v1.2.1