aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkarl-qdh <karl@qdh.org.uk>2011-02-25 15:25:47 +0000
committerkarl-qdh <karl@qdh.org.uk>2011-02-25 15:25:47 +0000
commitacbbf01f8ad7b09e618227449a041cc4d0b9e267 (patch)
treeb6754acbdfd1eaf9b153c15e7d29a5a46db00d3d
parentae4456bf22db293559fc5e9e90ea45484e08711f (diff)
downloadayatana-ido-acbbf01f8ad7b09e618227449a041cc4d0b9e267.tar.gz
ayatana-ido-acbbf01f8ad7b09e618227449a041cc4d0b9e267.tar.bz2
ayatana-ido-acbbf01f8ad7b09e618227449a041cc4d0b9e267.zip
Added return if fails to public api
-rw-r--r--src/idocalendarmenuitem.c16
1 files changed, 14 insertions, 2 deletions
diff --git a/src/idocalendarmenuitem.c b/src/idocalendarmenuitem.c
index 4fa0061..ba46ae2 100644
--- a/src/idocalendarmenuitem.c
+++ b/src/idocalendarmenuitem.c
@@ -280,30 +280,41 @@ ido_calendar_menu_item_new (void)
gboolean
ido_calendar_menu_item_mark_day (IdoCalendarMenuItem *menuitem, guint day)
{
+ g_return_val_if_fail(IDO_IS_CALENDAR_MENU_ITEM(menuitem), FALSE);
+
return gtk_calendar_mark_day(GTK_CALENDAR (menuitem->priv->calendar), day);
}
gboolean
ido_calendar_menu_item_unmark_day (IdoCalendarMenuItem *menuitem, guint day)
{
+ g_return_val_if_fail(IDO_IS_CALENDAR_MENU_ITEM(menuitem), FALSE);
+
return gtk_calendar_unmark_day(GTK_CALENDAR (menuitem->priv->calendar), day);
}
void
ido_calendar_menu_item_clear_marks (IdoCalendarMenuItem *menuitem)
{
+ g_return_if_fail(IDO_IS_CALENDAR_MENU_ITEM(menuitem));
+
gtk_calendar_clear_marks(GTK_CALENDAR (menuitem->priv->calendar));
}
void
ido_calendar_menu_item_set_display_options (IdoCalendarMenuItem *menuitem, GtkCalendarDisplayOptions flags)
{
+ g_return_if_fail(IDO_IS_CALENDAR_MENU_ITEM(menuitem));
+
gtk_calendar_set_display_options (GTK_CALENDAR (menuitem->priv->calendar), flags);
}
GtkCalendarDisplayOptions
ido_calendar_menu_item_get_display_options (IdoCalendarMenuItem *menuitem)
{
+
+ g_return_val_if_fail(IDO_IS_CALENDAR_MENU_ITEM(menuitem), NULL);
+
return gtk_calendar_get_display_options (GTK_CALENDAR (menuitem->priv->calendar));
}
@@ -312,6 +323,7 @@ ido_calendar_menu_item_get_date (IdoCalendarMenuItem *menuitem,
guint *year,
guint *month,
guint *day) {
-
- gtk_calendar_get_date (GTK_CALENDAR (menuitem->priv->calendar), year, month, day);
+
+ g_return_if_fail(IDO_IS_CALENDAR_MENU_ITEM(menuitem));
+ gtk_calendar_get_date (GTK_CALENDAR (menuitem->priv->calendar), year, month, day);
}