summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSebastien Braun2010-10-08 22:01:39 +0200
committerSebastien Braun2010-10-10 14:05:34 +0200
commit8ed8f90effab0876a8d8374d787d8c3b6214c531 (patch)
treecac3af119687e74bcda467ad8499263a7779e836 /src
parentIt is not necessary to auto-generate policyChain_autogen.h anymore (diff)
downloadpvs-8ed8f90effab0876a8d8374d787d8c3b6214c531.tar.gz
pvs-8ed8f90effab0876a8d8374d787d8c3b6214c531.tar.xz
pvs-8ed8f90effab0876a8d8374d787d8c3b6214c531.zip
Move the translations for pvsinput into the library where they belong.
Diffstat (limited to 'src')
-rw-r--r--src/input/CMakeLists.txt27
-rw-r--r--src/input/i18n.h33
-rw-r--r--src/input/i18n/pvsinput_ar_JO.ts147
-rw-r--r--src/input/i18n/pvsinput_de_DE.ts165
-rw-r--r--src/input/i18n/pvsinput_es_MX.ts147
-rw-r--r--src/input/i18n/pvsinput_fr_FR.ts147
-rw-r--r--src/input/i18n/pvsinput_pl_PL.ts147
-rw-r--r--src/input/inputEvent.cpp48
-rw-r--r--src/input/inputEvent.h7
-rw-r--r--src/pvsmgr.cpp3
-rw-r--r--src/pvsmgrtouch.cpp3
11 files changed, 850 insertions, 24 deletions
diff --git a/src/input/CMakeLists.txt b/src/input/CMakeLists.txt
index 689fd39..e14cdb4 100644
--- a/src/input/CMakeLists.txt
+++ b/src/input/CMakeLists.txt
@@ -110,8 +110,35 @@ if(UNIX)
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ)
endif()
+set(pvsinput_TSS
+ i18n/pvsinput_de_DE.ts
+ i18n/pvsinput_fr_FR.ts
+ i18n/pvsinput_es_MX.ts
+ i18n/pvsinput_ar_JO.ts
+ i18n/pvsinput_pl_PL.ts)
+
+QT4_CREATE_TRANSLATION(pvsinput_QMS
+ ${pvsinput_SRCS}
+ ${pvsprivinputd_SRCS}
+ ${pvsinput_TSS})
+
+# Generate an RCC file for our translations:
+file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/pvsinput.qrc"
+ "<RCC version='1.0'><qresource prefix='/i18n/pvsinput'>")
+foreach(qm ${pvsinput_QMS})
+ file(RELATIVE_PATH qm_rel ${CMAKE_CURRENT_BINARY_DIR} ${qm})
+ get_filename_component(qm_basename ${qm} NAME)
+ file(APPEND "${CMAKE_CURRENT_BINARY_DIR}/pvsinput.qrc"
+ "<file alias='${qm_basename}'>${qm_rel}</file>")
+endforeach()
+file(APPEND "${CMAKE_CURRENT_BINARY_DIR}/pvsinput.qrc" "</qresource></RCC>")
+
+qt4_add_resources(pvsinput_RCS
+ "${CMAKE_CURRENT_BINARY_DIR}/pvsinput.qrc")
+
add_library(
pvsinput
STATIC
${pvsinput_SRCS}
+ ${pvsinput_RCS}
)
diff --git a/src/input/i18n.h b/src/input/i18n.h
new file mode 100644
index 0000000..d64c7cf
--- /dev/null
+++ b/src/input/i18n.h
@@ -0,0 +1,33 @@
+/*
+ # Copyright (c) 2009 - OpenSLX Project, Computer Center University of Freiburg
+ #
+ # This program is free software distributed under the GPL version 2.
+ # See http://openslx.org/COPYING
+ #
+ # If you have any feedback please consult http://openslx.org/feedback and
+ # send your suggestions, praise, or complaints to feedback@openslx.org
+ #
+ # General information about OpenSLX can be found at http://openslx.org/
+ # --------------------------------------------------------------------------
+ # i18n.h:
+ # - For library users: Make sure the translations are linked and registered
+ # --------------------------------------------------------------------------
+ */
+
+#ifndef I18N_H_
+#define I18N_H_
+
+#include <QCoreApplication>
+#include <QLocale>
+#include <QTranslator>
+
+#define USE_PVSINPUT_TRANSLATIONS \
+ do { \
+ Q_INIT_RESOURCE(pvsinput); \
+ QTranslator* translator = new QTranslator(QCoreApplication::instance()); \
+ translator->load("pvsinput_" + QLocale::system().name(), ":/i18n/pvsinput"); \
+ QCoreApplication::instance()->installTranslator(translator); \
+ } while(false)
+
+
+#endif /* I18N_H_ */
diff --git a/src/input/i18n/pvsinput_ar_JO.ts b/src/input/i18n/pvsinput_ar_JO.ts
new file mode 100644
index 0000000..1040142
--- /dev/null
+++ b/src/input/i18n/pvsinput_ar_JO.ts
@@ -0,0 +1,147 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.0" language="ar_JO">
+<context>
+ <name>InputEvent</name>
+ <message>
+ <location filename="../inputEvent.cpp" line="107"/>
+ <source>Say Hello</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="108"/>
+ <source>Reboot</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="109"/>
+ <source>Kill X Server</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="110"/>
+ <source>Reboot immediately</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="111"/>
+ <source>Power off immediately</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="112"/>
+ <source>Crash System</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="113"/>
+ <source>Turn off raw keyboard mode</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="114"/>
+ <source>Send SIGTERM to all</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="115"/>
+ <source>Send SIGKILL to all</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="116"/>
+ <source>Kill all on this terminal</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="117"/>
+ <source>Activate OOM killer</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="118"/>
+ <source>Make real-time tasks niceable</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="119"/>
+ <source>Force-thaw filesystems</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="120"/>
+ <source>Sync all mounted filesystems</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="121"/>
+ <source>Remount all readonly</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="122"/>
+ <source>Show all held locks</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="123"/>
+ <source>Show stack traces</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="124"/>
+ <source>Dump memory info</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="125"/>
+ <source>Dump registers and flags</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="126"/>
+ <source>Dump timers and clockevents</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="127"/>
+ <source>Dump task list</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="128"/>
+ <source>Dump uninterruptible tasks</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="129"/>
+ <source>Dump ftrace buffer</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>QObject</name>
+ <message>
+ <location filename="../pvsprivinputd.cpp" line="66"/>
+ <source>Usage: %1 [--help|-h] [--daemon|-d] [--log=&lt;Logger&gt;|-l&lt;Logger&gt;]
+
+Options:
+ --help, -h Show this message
+ --daemon, -d Run in background
+ --log=&lt;Logger&gt;,
+ -l&lt;Logger&gt; Redirect all output to &lt;Logger&gt;
+ valid values are:
+ - any file name
+ - `syslog&apos; to redirect output to the system log
+ - `null&apos; to discard output (default)
+ (without quotes)
+
+Signals:
+ SIGINT, SIGTERM (or press Ctrl+C when run in foreground)
+ Quit
+ SIGHUP Reload configuration and cached user data
+</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+</TS>
diff --git a/src/input/i18n/pvsinput_de_DE.ts b/src/input/i18n/pvsinput_de_DE.ts
new file mode 100644
index 0000000..56ebf26
--- /dev/null
+++ b/src/input/i18n/pvsinput_de_DE.ts
@@ -0,0 +1,165 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.0" language="de_DE">
+<context>
+ <name>InputEvent</name>
+ <message>
+ <location filename="../inputEvent.cpp" line="107"/>
+ <source>Say Hello</source>
+ <translation>Hallo sagen</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="108"/>
+ <source>Reboot</source>
+ <translation>Neustart</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="109"/>
+ <source>Kill X Server</source>
+ <translation>X-Server töten</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="110"/>
+ <source>Reboot immediately</source>
+ <translation>Sofort neu starten</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="111"/>
+ <source>Power off immediately</source>
+ <translation>Sofort abschalten</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="112"/>
+ <source>Crash System</source>
+ <translation>Systemabsturz</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="113"/>
+ <source>Turn off raw keyboard mode</source>
+ <translation>RAW-Tastatur-Modus abschalten</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="114"/>
+ <source>Send SIGTERM to all</source>
+ <translation>SIGTERM an alle Prozesse senden</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="115"/>
+ <source>Send SIGKILL to all</source>
+ <translation>SIGKILL an alle Prozesse senden</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="116"/>
+ <source>Kill all on this terminal</source>
+ <translation>Alle Prozesse an diesem Terminal töten</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="117"/>
+ <source>Activate OOM killer</source>
+ <translation>OOM-Killer aktivieren</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="118"/>
+ <source>Make real-time tasks niceable</source>
+ <translation>Nice für Echtzeitprozesse ermöglichen</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="119"/>
+ <source>Force-thaw filesystems</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="120"/>
+ <source>Sync all mounted filesystems</source>
+ <translation>Alle eingebundenen Dateisysteme sync(2)en</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="121"/>
+ <source>Remount all readonly</source>
+ <translation>Alle Dateisysteme nur-lesbar mounten</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="122"/>
+ <source>Show all held locks</source>
+ <translation>Alle gehaltenen Sperren zeigen</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="123"/>
+ <source>Show stack traces</source>
+ <translation>Stacktraces anzigen</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="124"/>
+ <source>Dump memory info</source>
+ <translation>Speicherinfo anzeigen</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="125"/>
+ <source>Dump registers and flags</source>
+ <translation>Register und Flags anzeigen</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="126"/>
+ <source>Dump timers and clockevents</source>
+ <translation>Timer und Clockevents anzeigen</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="127"/>
+ <source>Dump task list</source>
+ <translation>Taskliste anzeigen</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="128"/>
+ <source>Dump uninterruptible tasks</source>
+ <translation>Ununterbrechbare Tasks anzeigen</translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="129"/>
+ <source>Dump ftrace buffer</source>
+ <translation>ftrace-Puffer anzeigen</translation>
+ </message>
+</context>
+<context>
+ <name>QObject</name>
+ <message>
+ <location filename="../pvsprivinputd.cpp" line="66"/>
+ <source>Usage: %1 [--help|-h] [--daemon|-d] [--log=&lt;Logger&gt;|-l&lt;Logger&gt;]
+
+Options:
+ --help, -h Show this message
+ --daemon, -d Run in background
+ --log=&lt;Logger&gt;,
+ -l&lt;Logger&gt; Redirect all output to &lt;Logger&gt;
+ valid values are:
+ - any file name
+ - `syslog&apos; to redirect output to the system log
+ - `null&apos; to discard output (default)
+ (without quotes)
+
+Signals:
+ SIGINT, SIGTERM (or press Ctrl+C when run in foreground)
+ Quit
+ SIGHUP Reload configuration and cached user data
+</source>
+ <translation>Verwendung: %1 [--help|-h] [--daemon|-d] [--log=&lt;Logger&gt;|-l&lt;Logger&gt;]
+
+Optionen:
+ --help, -h Diese Nachricht anzeigen
+ --daemon, -d Im Hintergrund laufen
+ --log=&lt;Logger&gt;,
+ -l&lt;Logger&gt; Alle Ausgaben an &lt;Logger&gt; weiterleiten
+ Mögliche Werte für &lt;Logger&gt;:
+ - Ein Dateiname
+ - `syslog&apos;, um Ausgaben an das Systemlog zu leiten
+ - `null&apos;, um Ausgaben zu verwerfen
+ Standardwert: null
+ Werte ohne Anführungszeichen eingeben
+
+Signale:
+ SIGINT, SIGTERM (oder Strg+C wenn nicht im Hintergrund)
+ Beenden
+ SIGHUP Konfiguration und Benutzerdatenbank neu laden
+</translation>
+ </message>
+</context>
+</TS>
diff --git a/src/input/i18n/pvsinput_es_MX.ts b/src/input/i18n/pvsinput_es_MX.ts
new file mode 100644
index 0000000..047c59c
--- /dev/null
+++ b/src/input/i18n/pvsinput_es_MX.ts
@@ -0,0 +1,147 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.0" language="es_MX">
+<context>
+ <name>InputEvent</name>
+ <message>
+ <location filename="../inputEvent.cpp" line="107"/>
+ <source>Say Hello</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="108"/>
+ <source>Reboot</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="109"/>
+ <source>Kill X Server</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="110"/>
+ <source>Reboot immediately</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="111"/>
+ <source>Power off immediately</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="112"/>
+ <source>Crash System</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="113"/>
+ <source>Turn off raw keyboard mode</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="114"/>
+ <source>Send SIGTERM to all</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="115"/>
+ <source>Send SIGKILL to all</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="116"/>
+ <source>Kill all on this terminal</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="117"/>
+ <source>Activate OOM killer</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="118"/>
+ <source>Make real-time tasks niceable</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="119"/>
+ <source>Force-thaw filesystems</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="120"/>
+ <source>Sync all mounted filesystems</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="121"/>
+ <source>Remount all readonly</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="122"/>
+ <source>Show all held locks</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="123"/>
+ <source>Show stack traces</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="124"/>
+ <source>Dump memory info</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="125"/>
+ <source>Dump registers and flags</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="126"/>
+ <source>Dump timers and clockevents</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="127"/>
+ <source>Dump task list</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="128"/>
+ <source>Dump uninterruptible tasks</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="129"/>
+ <source>Dump ftrace buffer</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>QObject</name>
+ <message>
+ <location filename="../pvsprivinputd.cpp" line="66"/>
+ <source>Usage: %1 [--help|-h] [--daemon|-d] [--log=&lt;Logger&gt;|-l&lt;Logger&gt;]
+
+Options:
+ --help, -h Show this message
+ --daemon, -d Run in background
+ --log=&lt;Logger&gt;,
+ -l&lt;Logger&gt; Redirect all output to &lt;Logger&gt;
+ valid values are:
+ - any file name
+ - `syslog&apos; to redirect output to the system log
+ - `null&apos; to discard output (default)
+ (without quotes)
+
+Signals:
+ SIGINT, SIGTERM (or press Ctrl+C when run in foreground)
+ Quit
+ SIGHUP Reload configuration and cached user data
+</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+</TS>
diff --git a/src/input/i18n/pvsinput_fr_FR.ts b/src/input/i18n/pvsinput_fr_FR.ts
new file mode 100644
index 0000000..8e3e417
--- /dev/null
+++ b/src/input/i18n/pvsinput_fr_FR.ts
@@ -0,0 +1,147 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.0" language="fr_FR">
+<context>
+ <name>InputEvent</name>
+ <message>
+ <location filename="../inputEvent.cpp" line="107"/>
+ <source>Say Hello</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="108"/>
+ <source>Reboot</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="109"/>
+ <source>Kill X Server</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="110"/>
+ <source>Reboot immediately</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="111"/>
+ <source>Power off immediately</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="112"/>
+ <source>Crash System</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="113"/>
+ <source>Turn off raw keyboard mode</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="114"/>
+ <source>Send SIGTERM to all</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="115"/>
+ <source>Send SIGKILL to all</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="116"/>
+ <source>Kill all on this terminal</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="117"/>
+ <source>Activate OOM killer</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="118"/>
+ <source>Make real-time tasks niceable</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="119"/>
+ <source>Force-thaw filesystems</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="120"/>
+ <source>Sync all mounted filesystems</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="121"/>
+ <source>Remount all readonly</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="122"/>
+ <source>Show all held locks</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="123"/>
+ <source>Show stack traces</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="124"/>
+ <source>Dump memory info</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="125"/>
+ <source>Dump registers and flags</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="126"/>
+ <source>Dump timers and clockevents</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="127"/>
+ <source>Dump task list</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="128"/>
+ <source>Dump uninterruptible tasks</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="129"/>
+ <source>Dump ftrace buffer</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>QObject</name>
+ <message>
+ <location filename="../pvsprivinputd.cpp" line="66"/>
+ <source>Usage: %1 [--help|-h] [--daemon|-d] [--log=&lt;Logger&gt;|-l&lt;Logger&gt;]
+
+Options:
+ --help, -h Show this message
+ --daemon, -d Run in background
+ --log=&lt;Logger&gt;,
+ -l&lt;Logger&gt; Redirect all output to &lt;Logger&gt;
+ valid values are:
+ - any file name
+ - `syslog&apos; to redirect output to the system log
+ - `null&apos; to discard output (default)
+ (without quotes)
+
+Signals:
+ SIGINT, SIGTERM (or press Ctrl+C when run in foreground)
+ Quit
+ SIGHUP Reload configuration and cached user data
+</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+</TS>
diff --git a/src/input/i18n/pvsinput_pl_PL.ts b/src/input/i18n/pvsinput_pl_PL.ts
new file mode 100644
index 0000000..87527d5
--- /dev/null
+++ b/src/input/i18n/pvsinput_pl_PL.ts
@@ -0,0 +1,147 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.0" language="pl_PL">
+<context>
+ <name>InputEvent</name>
+ <message>
+ <location filename="../inputEvent.cpp" line="107"/>
+ <source>Say Hello</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="108"/>
+ <source>Reboot</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="109"/>
+ <source>Kill X Server</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="110"/>
+ <source>Reboot immediately</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="111"/>
+ <source>Power off immediately</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="112"/>
+ <source>Crash System</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="113"/>
+ <source>Turn off raw keyboard mode</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="114"/>
+ <source>Send SIGTERM to all</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="115"/>
+ <source>Send SIGKILL to all</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="116"/>
+ <source>Kill all on this terminal</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="117"/>
+ <source>Activate OOM killer</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="118"/>
+ <source>Make real-time tasks niceable</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="119"/>
+ <source>Force-thaw filesystems</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="120"/>
+ <source>Sync all mounted filesystems</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="121"/>
+ <source>Remount all readonly</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="122"/>
+ <source>Show all held locks</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="123"/>
+ <source>Show stack traces</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="124"/>
+ <source>Dump memory info</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="125"/>
+ <source>Dump registers and flags</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="126"/>
+ <source>Dump timers and clockevents</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="127"/>
+ <source>Dump task list</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="128"/>
+ <source>Dump uninterruptible tasks</source>
+ <translation type="unfinished"></translation>
+ </message>
+ <message>
+ <location filename="../inputEvent.cpp" line="129"/>
+ <source>Dump ftrace buffer</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+<context>
+ <name>QObject</name>
+ <message>
+ <location filename="../pvsprivinputd.cpp" line="66"/>
+ <source>Usage: %1 [--help|-h] [--daemon|-d] [--log=&lt;Logger&gt;|-l&lt;Logger&gt;]
+
+Options:
+ --help, -h Show this message
+ --daemon, -d Run in background
+ --log=&lt;Logger&gt;,
+ -l&lt;Logger&gt; Redirect all output to &lt;Logger&gt;
+ valid values are:
+ - any file name
+ - `syslog&apos; to redirect output to the system log
+ - `null&apos; to discard output (default)
+ (without quotes)
+
+Signals:
+ SIGINT, SIGTERM (or press Ctrl+C when run in foreground)
+ Quit
+ SIGHUP Reload configuration and cached user data
+</source>
+ <translation type="unfinished"></translation>
+ </message>
+</context>
+</TS>
diff --git a/src/input/inputEvent.cpp b/src/input/inputEvent.cpp
index f5abf43..fa623e1 100644
--- a/src/input/inputEvent.cpp
+++ b/src/input/inputEvent.cpp
@@ -99,33 +99,33 @@ InputEvent InputEvent::keyboardRelease(int key, int mods)
}
#define describe(list, description, type, code, value) \
- list.append(SpecialInputEventDescription(InputEvent::type, InputEvent::code, value, QCoreApplication::translate("InputEvent", description)))
+ list.append(SpecialInputEventDescription(InputEvent::type, InputEvent::code, value, description))
QList<SpecialInputEventDescription> SpecialInputEventDescription::describeSpecialEvents()
{
QList<SpecialInputEventDescription> list;
- describe(list, "Say Hello", ET_SPECIAL, EC_SAY_HELLO, 0);
- describe(list, "Reboot", ET_SPECIAL, EC_REBOOT, 0);
- describe(list, "Kill X Server", ET_SPECIAL, EC_KILL_X, 0);
- describe(list, "Reboot immediately", ET_SPECIAL, EC_SYSRQ, 'b');
- describe(list, "Power off immediately", ET_SPECIAL, EC_SYSRQ, 'o');
- describe(list, "Crash System", ET_SPECIAL, EC_SYSRQ, 'c');
- describe(list, "Turn off raw keyboard mode", ET_SPECIAL, EC_SYSRQ, 'r');
- describe(list, "Send SIGTERM to all", ET_SPECIAL, EC_SYSRQ, 'e');
- describe(list, "Send SIGKILL to all", ET_SPECIAL, EC_SYSRQ, 'i');
- describe(list, "Kill all on this terminal", ET_SPECIAL, EC_SYSRQ, 'k');
- describe(list, "Activate OOM killer", ET_SPECIAL, EC_SYSRQ, 'f');
- describe(list, "Make real-time tasks niceable", ET_SPECIAL, EC_SYSRQ, 'n');
- describe(list, "Force-thaw filesystems", ET_SPECIAL, EC_SYSRQ, 'j');
- describe(list, "Sync all mounted filesystems", ET_SPECIAL, EC_SYSRQ, 's');
- describe(list, "Remount all readonly", ET_SPECIAL, EC_SYSRQ, 'u');
- describe(list, "Show all held locks", ET_SPECIAL, EC_SYSRQ, 'd');
- describe(list, "Show stack traces", ET_SPECIAL, EC_SYSRQ, 'l');
- describe(list, "Dump memory info", ET_SPECIAL, EC_SYSRQ, 'm');
- describe(list, "Dump registers and flags", ET_SPECIAL, EC_SYSRQ, 'p');
- describe(list, "Dump timers and clockevents", ET_SPECIAL, EC_SYSRQ, 'q');
- describe(list, "Dump task list", ET_SPECIAL, EC_SYSRQ, 't');
- describe(list, "Dump uninterruptible tasks", ET_SPECIAL, EC_SYSRQ, 'w');
- describe(list, "Dump ftrace buffer", ET_SPECIAL, EC_SYSRQ, 'z');
+ describe(list, InputEvent::tr("Say Hello"), ET_SPECIAL, EC_SAY_HELLO, 0);
+ describe(list, InputEvent::tr("Reboot"), ET_SPECIAL, EC_REBOOT, 0);
+ describe(list, InputEvent::tr("Kill X Server"), ET_SPECIAL, EC_KILL_X, 0);
+ describe(list, InputEvent::tr("Reboot immediately"), ET_SPECIAL, EC_SYSRQ, 'b');
+ describe(list, InputEvent::tr("Power off immediately"), ET_SPECIAL, EC_SYSRQ, 'o');
+ describe(list, InputEvent::tr("Crash System"), ET_SPECIAL, EC_SYSRQ, 'c');
+ describe(list, InputEvent::tr("Turn off raw keyboard mode"), ET_SPECIAL, EC_SYSRQ, 'r');
+ describe(list, InputEvent::tr("Send SIGTERM to all"), ET_SPECIAL, EC_SYSRQ, 'e');
+ describe(list, InputEvent::tr("Send SIGKILL to all"), ET_SPECIAL, EC_SYSRQ, 'i');
+ describe(list, InputEvent::tr("Kill all on this terminal"), ET_SPECIAL, EC_SYSRQ, 'k');
+ describe(list, InputEvent::tr("Activate OOM killer"), ET_SPECIAL, EC_SYSRQ, 'f');
+ describe(list, InputEvent::tr("Make real-time tasks niceable"), ET_SPECIAL, EC_SYSRQ, 'n');
+ describe(list, InputEvent::tr("Force-thaw filesystems"), ET_SPECIAL, EC_SYSRQ, 'j');
+ describe(list, InputEvent::tr("Sync all mounted filesystems"), ET_SPECIAL, EC_SYSRQ, 's');
+ describe(list, InputEvent::tr("Remount all readonly"), ET_SPECIAL, EC_SYSRQ, 'u');
+ describe(list, InputEvent::tr("Show all held locks"), ET_SPECIAL, EC_SYSRQ, 'd');
+ describe(list, InputEvent::tr("Show stack traces"), ET_SPECIAL, EC_SYSRQ, 'l');
+ describe(list, InputEvent::tr("Dump memory info"), ET_SPECIAL, EC_SYSRQ, 'm');
+ describe(list, InputEvent::tr("Dump registers and flags"), ET_SPECIAL, EC_SYSRQ, 'p');
+ describe(list, InputEvent::tr("Dump timers and clockevents"), ET_SPECIAL, EC_SYSRQ, 'q');
+ describe(list, InputEvent::tr("Dump task list"), ET_SPECIAL, EC_SYSRQ, 't');
+ describe(list, InputEvent::tr("Dump uninterruptible tasks"), ET_SPECIAL, EC_SYSRQ, 'w');
+ describe(list, InputEvent::tr("Dump ftrace buffer"), ET_SPECIAL, EC_SYSRQ, 'z');
return list;
}
diff --git a/src/input/inputEvent.h b/src/input/inputEvent.h
index 2f557ce..82b059c 100644
--- a/src/input/inputEvent.h
+++ b/src/input/inputEvent.h
@@ -18,6 +18,7 @@
#define INPUTEVENT_H_
#include <cassert>
+#include <QCoreApplication> // for translation
#include <QString>
#ifndef __linux
@@ -211,6 +212,12 @@ public:
{
return value_ & MODIFIER_MASK;
}
+
+ // We want to enable InputEvent as a translation context, so we fake the tr method:
+ static QString tr(const char* string)
+ {
+ return QCoreApplication::translate("InputEvent", string);
+ }
};
struct SpecialInputEventDescription
diff --git a/src/pvsmgr.cpp b/src/pvsmgr.cpp
index dd00c0e..f543c6d 100644
--- a/src/pvsmgr.cpp
+++ b/src/pvsmgr.cpp
@@ -19,6 +19,7 @@
#include "gui/mainWindow.h"
#include "util/consoleLogger.h"
#include "util/CertManager.h"
+#include "src/input/i18n.h"
QApplication *qtApp;
@@ -35,6 +36,8 @@ int main(int argc, char** argv)
translator.load(":pvsmgr");
qtApp->installTranslator(&translator);
+ USE_PVSINPUT_TRANSLATIONS;
+
ConsoleLog setLogName(QString("log.server"));
ConsoleLog writeLine(QString("PVS-Server started."));
diff --git a/src/pvsmgrtouch.cpp b/src/pvsmgrtouch.cpp
index d14ea56..4a1a97d 100644
--- a/src/pvsmgrtouch.cpp
+++ b/src/pvsmgrtouch.cpp
@@ -18,6 +18,7 @@
#include <QtGui/QDesktopServices>
#include "util/consoleLogger.h"
#include "util/CertManager.h"
+#include "src/input/i18n.h"
QApplication *qtApp;
@@ -34,6 +35,8 @@ int main(int argc, char** argv)
translator.load(":pvsmgr");
qtApp->installTranslator(&translator);*/
+ USE_PVSINPUT_TRANSLATIONS;
+
ConsoleLog setLogName(QString("log.server"));
ConsoleLog writeLine(QString("PVS-Server started."));