[gimp] app: use last git commit year for copyright label



commit c9b03ef8ffa90ffe742ecbd28d88b81150db3151
Author: Nils Philippsen <nils redhat com>
Date:   Tue Sep 28 14:23:41 2010 +0200

    app: use last git commit year for copyright label

 app/about.h                |    3 ++-
 app/dialogs/about-dialog.c |    8 +++++++-
 2 files changed, 9 insertions(+), 2 deletions(-)
---
diff --git a/app/about.h b/app/about.h
index 1c7473e..24389b0 100644
--- a/app/about.h
+++ b/app/about.h
@@ -25,8 +25,9 @@
 #define GIMP_NAME \
   _("GNU Image Manipulation Program")
 
+/* The year of the last commit (UTC) will be inserted into this string. */
 #define GIMP_COPYRIGHT \
-  _("Copyright © 1995-2010\n" \
+  _("Copyright © 1995-%s\n" \
     "Spencer Kimball, Peter Mattis and the GIMP Development Team")
 
 #define GIMP_LICENSE \
diff --git a/app/dialogs/about-dialog.c b/app/dialogs/about-dialog.c
index 04d8779..6223a34 100644
--- a/app/dialogs/about-dialog.c
+++ b/app/dialogs/about-dialog.c
@@ -33,6 +33,7 @@
 #include "pdb/gimppdb.h"
 
 #include "about.h"
+#include "git-version.h"
 
 #include "about-dialog.h"
 #include "authors.h"
@@ -89,6 +90,7 @@ about_dialog_create (GimpContext *context)
       GtkWidget *container;
       GdkPixbuf *pixbuf;
       GList     *children;
+      gchar     *copyright;
 
       dialog = g_new0 (GimpAboutDialog, 1);
 
@@ -96,13 +98,15 @@ about_dialog_create (GimpContext *context)
 
       pixbuf = about_dialog_load_logo ();
 
+      copyright = g_strdup_printf(GIMP_COPYRIGHT, GIMP_GIT_LAST_COMMIT_YEAR);
+
       widget = g_object_new (GTK_TYPE_ABOUT_DIALOG,
                              "role",               "about-dialog",
                              "window-position",    GTK_WIN_POS_CENTER,
                              "title",              _("About GIMP"),
                              "program-name",       GIMP_ACRONYM,
                              "version",            GIMP_VERSION,
-                             "copyright",          GIMP_COPYRIGHT,
+                             "copyright",          copyright,
                              "comments",           GIMP_NAME,
                              "license",            GIMP_LICENSE,
                              "wrap-license",       TRUE,
@@ -119,6 +123,8 @@ about_dialog_create (GimpContext *context)
       if (pixbuf)
         g_object_unref (pixbuf);
 
+      g_free(copyright);
+
       dialog->dialog = widget;
 
       g_object_add_weak_pointer (G_OBJECT (widget), (gpointer) &dialog);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]