[gnome-photos] done-notification: Fix the property type of "item"
- From: Debarshi Ray <debarshir src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-photos] done-notification: Fix the property type of "item"
- Date: Tue, 24 Oct 2017 17:46:33 +0000 (UTC)
commit ce6a431a9055e88de435fb2dcde3449044736838
Author: Debarshi Ray <debarshir gnome org>
Date: Tue Oct 24 19:36:57 2017 +0200
done-notification: Fix the property type of "item"
Fallout from 0e9b118c793b99c20008d82f814e1a19bf7bcfd7
src/photos-done-notification.c | 16 +++++++---------
1 files changed, 7 insertions(+), 9 deletions(-)
---
diff --git a/src/photos-done-notification.c b/src/photos-done-notification.c
index f2bcf50..257afe8 100644
--- a/src/photos-done-notification.c
+++ b/src/photos-done-notification.c
@@ -181,11 +181,8 @@ photos_done_notification_set_property (GObject *object, guint prop_id, const GVa
switch (prop_id)
{
case PROP_ITEM:
- {
- PhotosBaseItem *item = (PhotosBaseItem *) g_value_get_pointer (value);
- self->item = g_object_ref (item);
- break;
- }
+ self->item = PHOTOS_BASE_ITEM (g_value_dup_object (value));
+ break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
@@ -217,10 +214,11 @@ photos_done_notification_class_init (PhotosDoneNotificationClass *class)
g_object_class_install_property (object_class,
PROP_ITEM,
- g_param_spec_pointer ("item",
- "PhotosBaseItem instance",
- "The edited PhotosBaseItem",
- G_PARAM_CONSTRUCT_ONLY | G_PARAM_WRITABLE));
+ g_param_spec_object ("item",
+ "PhotosBaseItem instance",
+ "The edited PhotosBaseItem",
+ PHOTOS_TYPE_BASE_ITEM,
+ G_PARAM_CONSTRUCT_ONLY | G_PARAM_WRITABLE));
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]