[gimp] app: (re-)add GimpDisplayShell::show-all property



commit 02654b0ac04ae6b88df027c72570c9da5bf930fd
Author: Ell <ell_se yahoo com>
Date:   Mon Nov 4 13:03:48 2019 +0200

    app: (re-)add GimpDisplayShell::show-all property
    
    ... which corresponds to the shell's show-all mode.  We'll listen
    to its "notify" signal in the bucket-fill tool.

 app/display/gimpdisplayshell.c | 14 ++++++++++++++
 1 file changed, 14 insertions(+)
---
diff --git a/app/display/gimpdisplayshell.c b/app/display/gimpdisplayshell.c
index 365e7d08e7..4edca724e2 100644
--- a/app/display/gimpdisplayshell.c
+++ b/app/display/gimpdisplayshell.c
@@ -105,6 +105,7 @@ enum
   PROP_TITLE,
   PROP_STATUS,
   PROP_ICON,
+  PROP_SHOW_ALL,
   PROP_INFINITE_CANVAS
 };
 
@@ -295,6 +296,12 @@ gimp_display_shell_class_init (GimpDisplayShellClass *klass)
                                                         GDK_TYPE_PIXBUF,
                                                         GIMP_PARAM_READWRITE));
 
+  g_object_class_install_property (object_class, PROP_SHOW_ALL,
+                                   g_param_spec_boolean ("show-all",
+                                                         NULL, NULL,
+                                                         FALSE,
+                                                         GIMP_PARAM_READWRITE));
+
   g_object_class_install_property (object_class, PROP_INFINITE_CANVAS,
                                    g_param_spec_boolean ("infinite-canvas",
                                                          NULL, NULL,
@@ -854,6 +861,9 @@ gimp_display_shell_set_property (GObject      *object,
         g_object_unref (shell->icon);
       shell->icon = g_value_dup_object (value);
       break;
+    case PROP_SHOW_ALL:
+      gimp_display_shell_set_show_all (shell, g_value_get_boolean (value));
+      break;
 
     default:
       G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
@@ -892,6 +902,9 @@ gimp_display_shell_get_property (GObject    *object,
     case PROP_ICON:
       g_value_set_object (value, shell->icon);
       break;
+    case PROP_SHOW_ALL:
+      g_value_set_boolean (value, shell->show_all);
+      break;
     case PROP_INFINITE_CANVAS:
       g_value_set_boolean (value,
                            gimp_display_shell_get_infinite_canvas (shell));
@@ -1792,6 +1805,7 @@ gimp_display_shell_set_show_all (GimpDisplayShell *shell,
             }
         }
 
+      g_object_notify (G_OBJECT (shell), "show-all");
       g_object_notify (G_OBJECT (shell), "infinite-canvas");
     }
 }


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