[gitg/vala] Mark translatable strings in history plugin
- From: Jesse van den Kieboom <jessevdk src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gitg/vala] Mark translatable strings in history plugin
- Date: Tue, 17 Jul 2012 08:58:30 +0000 (UTC)
commit e2b8ec4e2c8aff61757aa546310d81ed3b4f0864
Author: Jesse van den Kieboom <jesse vandenkieboom epfl ch>
Date: Tue Jul 17 10:52:59 2012 +0200
Mark translatable strings in history plugin
plugins/history/gitg-history-navigation.vala | 9 ++++++---
plugins/history/gitg-history.vala | 9 +++++----
2 files changed, 11 insertions(+), 7 deletions(-)
---
diff --git a/plugins/history/gitg-history-navigation.vala b/plugins/history/gitg-history-navigation.vala
index b855749..45ca0a8 100644
--- a/plugins/history/gitg-history-navigation.vala
+++ b/plugins/history/gitg-history-navigation.vala
@@ -21,6 +21,9 @@ namespace GitgHistory
{
private class Navigation : Object, GitgExt.Navigation
{
+ // Do this to pull in config.h before glib.h (for gettext...)
+ private const string version = Gitg.Config.VERSION;
+
public GitgExt.Application? application { owned get; construct set; }
public signal void ref_activated(Gitg.Ref r);
@@ -97,7 +100,7 @@ namespace GitgHistory
} catch {}
// Branches
- model.begin_header("Branches", null);
+ model.begin_header(_("Branches"), null);
foreach (var item in branches)
{
@@ -120,7 +123,7 @@ namespace GitgHistory
model.end_header();
// Remotes
- model.begin_header("Remotes", "network-server-symbolic");
+ model.begin_header(_("Remotes"), "network-server-symbolic");
foreach (var rname in remotenames)
{
@@ -141,7 +144,7 @@ namespace GitgHistory
model.end_header();
// Tags
- model.begin_header("Tags", null);
+ model.begin_header(_("Tags"), null);
foreach (var item in tags)
{
diff --git a/plugins/history/gitg-history.vala b/plugins/history/gitg-history.vala
index 99099df..d77d78a 100644
--- a/plugins/history/gitg-history.vala
+++ b/plugins/history/gitg-history.vala
@@ -19,14 +19,14 @@
namespace GitgHistory
{
- // Do this to pull in config.h before glib.h (for gettext...)
- private const string version = Gitg.Config.VERSION;
-
/* The main history view. This view shows the equivalent of git log, but
* in a nice way with lanes, merges, ref labels etc.
*/
public class View : Object, GitgExt.UIElement, GitgExt.View, GitgExt.ObjectSelection
{
+ // Do this to pull in config.h before glib.h (for gettext...)
+ private const string version = Gitg.Config.VERSION;
+
public GitgExt.Application? application { owned get; construct set; }
private Gtk.TreeView d_view;
@@ -42,6 +42,7 @@ namespace GitgHistory
public void foreach_selected(GitgExt.ForeachObjectSelectionFunc func)
{
bool breakit = false;
+
d_view.get_selection().selected_foreach((model, path, iter) => {
if (!breakit)
{
@@ -65,7 +66,7 @@ namespace GitgHistory
public string display_name
{
- owned get { return "History"; }
+ owned get { return _("History"); }
}
public Icon? icon
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]