[gimp] app: actually edit the template's color profile in GimpTemplateEditor



commit b8db0aa54e716a9a73b2171336bef4cdc6601b46
Author: Michael Natterer <mitch gimp org>
Date:   Wed Oct 12 23:48:06 2016 +0200

    app: actually edit the template's color profile in GimpTemplateEditor
    
    The "add default profile of image type" code was resetting it without
    implementing the FIXME of setting it again. Spotted by Elle.

 app/widgets/gimptemplateeditor.c |   11 +++++++++--
 1 files changed, 9 insertions(+), 2 deletions(-)
---
diff --git a/app/widgets/gimptemplateeditor.c b/app/widgets/gimptemplateeditor.c
index 4110654..a0b3ea4 100644
--- a/app/widgets/gimptemplateeditor.c
+++ b/app/widgets/gimptemplateeditor.c
@@ -753,6 +753,7 @@ gimp_template_editor_template_notify (GimpTemplate       *template,
       ! strcmp (param_spec->name, "precision"))
     {
       GtkListStore *profile_store;
+      GFile        *profile;
       gchar        *filename;
 
       filename = gimp_personal_rc_file ("profilerc");
@@ -769,8 +770,14 @@ gimp_template_editor_template_notify (GimpTemplate       *template,
                                GTK_TREE_MODEL (profile_store));
       g_object_unref (profile_store);
 
-      /* FIXME use template's profile */
+      g_object_get (template,
+                    "color-profile", &profile,
+                    NULL);
+
       gimp_color_profile_combo_box_set_active_file (GIMP_COLOR_PROFILE_COMBO_BOX (private->profile_combo),
-                                                    NULL, NULL);
+                                                    profile, NULL);
+
+      if (profile)
+        g_object_unref (profile);
     }
 }


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