summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2007-10-21 18:58:18 +0200
committerLennart Poettering <lennart@poettering.net>2007-10-21 18:58:18 +0200
commit09af8146071f540dfa2c935fff2cb5f0807ff281 (patch)
tree65e14460e4efe762d9c3a232e2a6d7f038eec76e
parentff466b0f090ee10ea69941b6c520fa6f6db6b641 (diff)
Beef up i18n a bit
-rw-r--r--Makefile.am3
-rw-r--r--po/POTFILES.in2
-rw-r--r--po/de.po55
-rw-r--r--src/lassi-server.c21
4 files changed, 68 insertions, 13 deletions
diff --git a/Makefile.am b/Makefile.am
index 058fae6..15ffc8e 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -56,7 +56,8 @@ mango_lassi_CFLAGS = \
$(AVAHI_UI_CFLAGS) \
$(LIBNOTIFY_CFLAGS) \
$(LIBGLADE_CFLAGS) \
- -DGLADE_FILE=\"$(gladedir)/mango-lassi.glade\"
+ -DGLADE_FILE=\"$(gladedir)/mango-lassi.glade\" \
+ -DLOCALEDIR=\"$(localedir)\"
glade_DATA = \
src/mango-lassi.glade
diff --git a/po/POTFILES.in b/po/POTFILES.in
index ecd2b60..8a5395c 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -1,2 +1,4 @@
[encoding: UTF-8]
+src/lassi-server.c
+src/lassi-prefs.c
src/mango-lassi.glade
diff --git a/po/de.po b/po/de.po
index 268a7b2..271590a 100644
--- a/po/de.po
+++ b/po/de.po
@@ -1,8 +1,9 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
-"POT-Creation-Date: \n"
-"PO-Revision-Date: 2007-10-21 18:13+0100\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2007-10-21 18:52+0200\n"
+"PO-Revision-Date: 2007-10-21 18:57+0100\n"
"Last-Translator: \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
@@ -10,15 +11,59 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"X-Poedit-Language: de\n"
+#: ../src/lassi-server.c:71
+#, c-format
+msgid ""
+"Mouse and keyboard are being redirected to <b>%s</b>, which is located to the <b>%s</b> of this screen.\n"
+"To redirect input back to this screen, press and release both shift keys simultaneously."
+msgstr ""
+"Maus und Tastatur werden auf <b>%s</b> umgelenkt, nach <b>%s</b> von diesem Desktop.\n"
+"Um die Eingabe zurück auf diesen Bildschirm zu lenken, drücken und lassen Sie beide Umschalttasten gleichzeitig los."
+
+#: ../src/lassi-server.c:382
+#, c-format
+msgid "%s now shares input with this desktop"
+msgstr "%s teilt sich nun Maus und Tastatur mit diesem Desktop"
+
+#: ../src/lassi-server.c:383
+#, c-format
+msgid "You're now sharing keyboard and mouse with <b>%s</b> which is located to the <b>%s</b>."
+msgstr "Sie teilen sich Maus und Tastatur nun mit <b>%s</b>, <b>%s</b> von diesem Destop"
+
+#: ../src/lassi-server.c:383
+#: ../src/lassi-server.c:386
+msgid "left"
+msgstr "links"
+
+#: ../src/lassi-server.c:383
+#: ../src/lassi-server.c:386
+msgid "right"
+msgstr "rechts"
+
+#: ../src/lassi-server.c:385
+#, c-format
+msgid "%s no longer shares input with this desktop"
+msgstr "%s teilt sich Maus und Tastatur nicht mehr mit diesem Desktop"
+
+#: ../src/lassi-server.c:386
+#, c-format
+msgid "You're no longer sharing keyboard and mouse with <b>%s</b> which was located to the <b>%s</b>."
+msgstr "Sie teilen sich nicht länger Maus und Tastatur mit <b>%s</b>, <b>%s</b> von diesem Bildschirm"
+
+#: ../src/lassi-server.c:1413
+#, c-format
+msgid "%s's desktop on %s"
+msgstr "%s Desktop auf %s"
+
#: ../src/mango-lassi.glade.h:1
msgid ""
"<i>Reorder the desktops you're already sharing mouse and keyboard with, or add new desktops to your session. \n"
"Order the desktops in the list above from left to right how they are positioned on your desk.\n"
"Please make sure to run Mango Lassi Input Sharing on all computers you want so share input with.</i>"
msgstr ""
-"<i>Passen Sie die Reihenfolge der bereits zu Ihrer Sitzung gehörenden Desktops, oder fügen Sie neue Desktops zu Ihrer Sitzung hinzu.\n"
-"Ordnen Sie die Desktops in obiger von links nach rechts, wie sie auf Ihrem Schreibtisch angeordnet sind.\n"
-"Bitte stelln Sie sicher, dass Mango Lassi Input Sharing auf allen Computern, mit denen Maus und Tastatur gemeinsam benutzt werden sollen, läuft.</i>"
+"<i>Passen Sie die Reihenfolge der bereits zu Ihrer Sitzung gehörenden Desktops an, oder fügen Sie neue Desktops zu Ihrer Sitzung hinzu.\n"
+"Ordnen Sie die Desktops in obiger Liste von links nach rechts an, so wie sie auf Ihrem Schreibtisch angeordnet sind.\n"
+"Bitte stellen Sie sicher, dass Mango Lassi Input Sharing auf allen Computern läuft, mit denen Maus und Tastatur gemeinsam benutzt werden sollen.</i>"
#: ../src/mango-lassi.glade.h:4
msgid "Input Sharing"
diff --git a/src/lassi-server.c b/src/lassi-server.c
index 8dcef29..6efa618 100644
--- a/src/lassi-server.c
+++ b/src/lassi-server.c
@@ -9,12 +9,14 @@
#include <sys/socket.h>
#include <netinet/in.h>
#include <netinet/tcp.h>
+#include <libintl.h>
#include <dbus/dbus-glib.h>
#include <dbus/dbus-glib-lowlevel.h>
#include <dbus/dbus.h>
#include <gtk/gtk.h>
+#include <glib/gi18n.h>
#include "lassi-server.h"
#include "lassi-grab.h"
@@ -66,8 +68,8 @@ static void server_layout_changed(LassiServer *ls, int y) {
char *t;
gboolean to_left = !!g_list_find(ls->connections_left, ls->active_connection);
- t = g_strdup_printf("Mouse and keyboard are being redirected to <b>%s</b>, which is located to the <b>%s</b> of this screen.\n"
- "To redirect input back to this screen, press and release both shift keys simultaneously.",
+ t = g_strdup_printf(_("Mouse and keyboard are being redirected to <b>%s</b>, which is located to the <b>%s</b> of this screen.\n"
+ "To redirect input back to this screen, press and release both shift keys simultaneously."),
ls->active_connection->id, to_left ? "left" : "right");
if (to_left)
@@ -377,11 +379,11 @@ static void show_welcome(LassiConnection *lc, gboolean is_connect) {
to_left = !!g_list_find(ls->connections_left, lc);
if (is_connect) {
- summary = g_strdup_printf("%s now shares input with this desktop", lc->id);
- body = g_strdup_printf("You're now sharing keyboard and mouse with <b>%s</b> which is located to the <b>%s</b>.", lc->id, to_left ? "left" : "right");
+ summary = g_strdup_printf(_("%s now shares input with this desktop"), lc->id);
+ body = g_strdup_printf(_("You're now sharing keyboard and mouse with <b>%s</b> which is located to the <b>%s</b>."), lc->id, to_left ? _("left") : _("right"));
} else {
- summary = g_strdup_printf("%s no longer shares input with this desktop", lc->id);
- body = g_strdup_printf("You're no longer sharing keyboard and mouse with <b>%s</b> which was located to the <b>%s</b>.", lc->id, to_left ? "left" : "right");
+ summary = g_strdup_printf(_("%s no longer shares input with this desktop"), lc->id);
+ body = g_strdup_printf(_("You're no longer sharing keyboard and mouse with <b>%s</b> which was located to the <b>%s</b>."), lc->id, to_left ? _("left") : _("right"));
}
lassi_tray_show_notification(&ls->tray_info, summary, body, to_left ? LASSI_TRAY_NOTIFICATION_LEFT : LASSI_TRAY_NOTIFICATION_RIGHT);
@@ -1408,7 +1410,7 @@ static int server_init(LassiServer *ls) {
ls->connections_by_id = g_hash_table_new(g_str_hash, g_str_equal);
- ls->id = g_strdup_printf("%s's desktop on %s", g_get_user_name(), g_get_host_name());
+ ls->id = g_strdup_printf(_("%s's desktop on %s"), g_get_user_name(), g_get_host_name());
if (lassi_avahi_init(&ls->avahi_info, ls) < 0)
goto finish;
@@ -1540,6 +1542,11 @@ finish:
int main(int argc, char *argv[]) {
LassiServer ls;
+ /* Initialize the i18n stuff */
+ bindtextdomain(GETTEXT_PACKAGE, LOCALEDIR);
+ bind_textdomain_codeset(GETTEXT_PACKAGE, "UTF-8");
+ textdomain(GETTEXT_PACKAGE);
+
gtk_init(&argc, &argv);
memset(&ls, 0, sizeof(ls));