[gnome-photos] source: Mark "name" as readable too



commit 8217fd74b414da5b25f0eb5fb024734e5f91b4a8
Author: Debarshi Ray <debarshir gnome org>
Date:   Tue Jul 2 18:39:57 2013 +0200

    source: Mark "name" as readable too
    
    We have an accessor to get the value of the property, so it only makes
    sense to mark it as such.

 src/photos-source.c |    9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)
---
diff --git a/src/photos-source.c b/src/photos-source.c
index 5112a21..32cc44e 100644
--- a/src/photos-source.c
+++ b/src/photos-source.c
@@ -116,11 +116,16 @@ static void
 photos_source_get_property (GObject *object, guint prop_id, GValue *value, GParamSpec *pspec)
 {
   PhotosSource *self = PHOTOS_SOURCE (object);
+  PhotosSourcePrivate *priv = self->priv;
 
   switch (prop_id)
     {
     case PROP_ID:
-      g_value_set_string (value, self->priv->id);
+      g_value_set_string (value, priv->id);
+      break;
+
+    case PROP_NAME:
+      g_value_set_string (value, priv->name);
       break;
 
     default:
@@ -221,7 +226,7 @@ photos_source_class_init (PhotosSourceClass *class)
                                                         "",
                                                         "",
                                                         "",
-                                                        G_PARAM_CONSTRUCT_ONLY | G_PARAM_WRITABLE));
+                                                        G_PARAM_CONSTRUCT_ONLY | G_PARAM_READWRITE));
 
   g_object_class_install_property (object_class,
                                    PROP_OBJECT,



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