aboutsummaryrefslogtreecommitdiff
path: root/plugins/openpgp/src
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/openpgp/src')
-rw-r--r--plugins/openpgp/src/account_settings_widget.vala10
-rw-r--r--plugins/openpgp/src/plugin.vala5
2 files changed, 10 insertions, 5 deletions
diff --git a/plugins/openpgp/src/account_settings_widget.vala b/plugins/openpgp/src/account_settings_widget.vala
index 026d7d3c..77121352 100644
--- a/plugins/openpgp/src/account_settings_widget.vala
+++ b/plugins/openpgp/src/account_settings_widget.vala
@@ -71,13 +71,13 @@ private class AccountSettingsWidget : Stack, Plugins.AccountSettingsWidget {
private void populate_list_store() {
if (keys.size == 0) {
- label.set_markup(build_markup_string("Key publishing disabled", "No keys available. Generate one!"));
+ label.set_markup(build_markup_string(_("Key publishing disabled"), _("No keys available. Generate one!")));
return;
}
TreeIter iter;
list_store.append(out iter);
- list_store.set(iter, 0, build_markup_string("Key publishing disabled", "Select key"), 1, "");
+ list_store.set(iter, 0, build_markup_string(_("Key publishing disabled"), _("Select key")), 1, "");
for (int i = 0; i < keys.size; i++) {
list_store.append(out iter);
list_store.set(iter, 0, @"$(Markup.escape_text(keys[i].uids[0].uid))\n<span font_family='monospace' font='8'>0x$(Markup.escape_text(keys[i].fpr[0:16]))</span>");
@@ -94,7 +94,7 @@ private class AccountSettingsWidget : Stack, Plugins.AccountSettingsWidget {
TreeIter iter;
list_store.clear();
list_store.append(out iter);
- label.set_markup(build_markup_string("Loading...", "Querying GnuPG"));
+ label.set_markup(build_markup_string(_("Loading..."), _("Querying GnuPG")));
new Thread<void*> (null, () => { // Querying GnuPG might take some time
try {
keys = GPGHelper.get_keylist(null, true);
@@ -105,7 +105,7 @@ private class AccountSettingsWidget : Stack, Plugins.AccountSettingsWidget {
});
} catch (Error e) {
Idle.add(() => {
- label.set_markup(build_markup_string("Key publishing disabled", "Error in GnuPG"));
+ label.set_markup(build_markup_string(_("Key publishing disabled"), _("Error in GnuPG")));
return false;
});
}
@@ -139,7 +139,7 @@ private class AccountSettingsWidget : Stack, Plugins.AccountSettingsWidget {
}
private string build_markup_string(string primary, string secondary) {
- return @"$(Markup.escape_text(primary))\n<span font='9'>$(Markup.escape_text(secondary))</span>";
+ return @"$(Markup.escape_text(primary))\n<span font='8'>$(Markup.escape_text(secondary))</span>";
}
}
diff --git a/plugins/openpgp/src/plugin.vala b/plugins/openpgp/src/plugin.vala
index b69f7b7a..a585b206 100644
--- a/plugins/openpgp/src/plugin.vala
+++ b/plugins/openpgp/src/plugin.vala
@@ -2,6 +2,9 @@ using Gee;
using Dino.Entities;
+extern const string GETTEXT_PACKAGE;
+extern const string LOCALE_INSTALL_DIR;
+
namespace Dino.Plugins.OpenPgp {
public class Plugin : Plugins.RootInterface, Object {
@@ -23,6 +26,8 @@ namespace Dino.Plugins.OpenPgp {
app.stream_interaction.module_manager.initialize_account_modules.connect(on_initialize_account_modules);
Manager.start(app.stream_interaction, db);
+
+ internationalize(GETTEXT_PACKAGE, app.search_path_generator.get_locale_path(GETTEXT_PACKAGE, LOCALE_INSTALL_DIR));
}
public void shutdown() { }