changeset 411:413b29f6758f

Add translation infrastructure and a file for the Administrator application
author Andre Heinecke <aheinecke@intevation.de>
date Wed, 16 Apr 2014 16:05:46 +0000
parents 3132ba0a305d
children 1be8826207ca 16b6d5686835
files ui/CMakeLists.txt ui/l10n/administrator.ts
diffstat 2 files changed, 222 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/ui/CMakeLists.txt	Wed Apr 16 14:19:49 2014 +0000
+++ b/ui/CMakeLists.txt	Wed Apr 16 16:05:46 2014 +0000
@@ -10,6 +10,8 @@
 include_directories(${CMAKE_CURRENT_SOURCE_DIR}/../common)
 add_definitions(${Qt5Widgets_DEFINITIONS})
 
+find_package(Qt5LinguistTools)
+
 set(CERTIFICATELIST_SOURCES
     ${CMAKE_CURRENT_SOURCE_DIR}/certificatelist.cpp
     ${CMAKE_CURRENT_SOURCE_DIR}/certificate.cpp
@@ -108,7 +110,14 @@
 
 set(ADMINSTRATOR_SOURCES_WITH_RESOURCES ${ADMINSTRATOR_SOURCES})
 qt5_add_resources(ADMINSTRATOR_SOURCES_WITH_RESOURCES ${ADMINSTRATOR_RESOURCES})
-add_executable(administrator ${ADMINSTRATOR_SOURCES_WITH_RESOURCES})
+
+if(Qt5LinguistTools_FOUND)
+   qt5_create_translation(ADMINISTRATOR_TRANSLATION ${ADMINSTRATOR_SOURCES_WITH_RESOURCES}
+      ${CMAKE_CURRENT_SOURCE_DIR}/l10n/administrator.ts)
+  add_executable(administrator ${ADMINSTRATOR_SOURCES_WITH_RESOURCES} ${ADMINISTRATOR_TRANSLATION})
+else()
+   message (STATUS "WARNING: Could not find qt linguist tools. Translation will not be included.")
+endif()
 
 target_link_libraries(administrator Qt5::Widgets
    trustbridge_common
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/ui/l10n/administrator.ts	Wed Apr 16 16:05:46 2014 +0000
@@ -0,0 +1,212 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.1" language="de">
+<context>
+    <name>AdministratorWindow</name>
+    <message>
+        <location filename="../administratorwindow.cpp" line="49"/>
+        <source>Menu</source>
+        <translation>MenĂ¼</translation>
+    </message>
+    <message>
+        <location filename="../administratorwindow.cpp" line="51"/>
+        <source>Create Installer</source>
+        <translation>Installationspaket erstellen</translation>
+    </message>
+    <message>
+        <location filename="../administratorwindow.cpp" line="52"/>
+        <source>Settings</source>
+        <translation>Einstellungen</translation>
+    </message>
+    <message>
+        <location filename="../administratorwindow.cpp" line="54"/>
+        <source>Help</source>
+        <translation>Hilfe</translation>
+    </message>
+    <message>
+        <location filename="../administratorwindow.cpp" line="55"/>
+        <source>About</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../administratorwindow.cpp" line="57"/>
+        <source>Quit</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../administratorwindow.cpp" line="79"/>
+        <source>Managed Certificates</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../administratorwindow.cpp" line="102"/>
+        <source>Administrator Application</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../administratorwindow.cpp" line="113"/>
+        <source>Save</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../administratorwindow.cpp" line="115"/>
+        <source>Load</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../administratorwindow.cpp" line="117"/>
+        <source>Add</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../administratorwindow.cpp" line="119"/>
+        <source>Remove</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../administratorwindow.cpp" line="144"/>
+        <source>Select certificate file</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../administratorwindow.cpp" line="165"/>
+        <source>Select certificate</source>
+        <translation type="unfinished"></translation>
+    </message>
+</context>
+<context>
+    <name>CertificateTabelModel</name>
+    <message>
+        <location filename="../certificatetablemodel.cpp" line="16"/>
+        <source>Subject CN</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../certificatetablemodel.cpp" line="17"/>
+        <source>Subject O</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../certificatetablemodel.cpp" line="18"/>
+        <source>Issuer CN</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../certificatetablemodel.cpp" line="19"/>
+        <source>Issuer O</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../certificatetablemodel.cpp" line="20"/>
+        <source>valid from</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../certificatetablemodel.cpp" line="21"/>
+        <source>valid to</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../certificatetablemodel.cpp" line="22"/>
+        <source>SHA1 Fingerprint</source>
+        <translation type="unfinished"></translation>
+    </message>
+</context>
+<context>
+    <name>CertificateTableDelegate</name>
+    <message>
+        <location filename="../certificatetabledelegate.cpp" line="51"/>
+        <source>add</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../certificatetabledelegate.cpp" line="54"/>
+        <source>remove</source>
+        <translation type="unfinished"></translation>
+    </message>
+</context>
+<context>
+    <name>CreateCertListDialog</name>
+    <message>
+        <location filename="../createcertlistdialog.cpp" line="21"/>
+        <source>adminstrator - Create signed certificate list</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../createcertlistdialog.cpp" line="35"/>
+        <source>Create a new, signed certificate list.
+</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../createcertlistdialog.cpp" line="63"/>
+        <source>Create List</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../createcertlistdialog.cpp" line="81"/>
+        <source>Select certificate</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../createcertlistdialog.cpp" line="88"/>
+        <source>Select target location</source>
+        <translation type="unfinished"></translation>
+    </message>
+</context>
+<context>
+    <name>CreateInstallerDialog</name>
+    <message>
+        <location filename="../createinstallerdialog.cpp" line="21"/>
+        <source>adminstrator - Create signed installer binary</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../createinstallerdialog.cpp" line="36"/>
+        <source>Create a new signed installer binary.
+</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../createinstallerdialog.cpp" line="75"/>
+        <source>Create Installer</source>
+        <translation type="unfinished">Installationspaket erstellen</translation>
+    </message>
+    <message>
+        <location filename="../createinstallerdialog.cpp" line="93"/>
+        <source>Select certificate</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../createinstallerdialog.cpp" line="100"/>
+        <source>Select source archive</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../createinstallerdialog.cpp" line="107"/>
+        <source>Select target location</source>
+        <translation type="unfinished"></translation>
+    </message>
+</context>
+<context>
+    <name>QObject</name>
+    <message>
+        <location filename="../certificate.cpp" line="75"/>
+        <source>Certificate:
+    &lt;bold&gt;%1&lt;/bold&gt;
+    %2, %3
+
+Serial number:
+%4
+Valid from: &lt;bold&gt;%5&lt;/bold&gt; to &lt;bold&gt;%6&lt;/bold&gt;
+
+Issued by: ..</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../certificate.cpp" line="129"/>
+        <source>Failed to parse certificate</source>
+        <translation type="unfinished"></translation>
+    </message>
+</context>
+</TS>

http://wald.intevation.org/projects/trustbridge/