summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorMichael BOUCHAUD <michael.bouchaud@gmail.com>2012-04-25 22:51:46 +0000
committerMichael BOUCHAUD <michael.bouchaud@gmail.com>2012-04-25 22:51:46 +0000
commit31967880ca1f71d1b9d077e05095600859b0fcd3 (patch)
tree9712a396dd6817e78f8785b55b6eb3a862e57446 /src/lib
parentd07ab81e7b6634cc961e5aedade22b9ff8fe6375 (diff)
elementary: calendar still need glue
SVN revision: 70484
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/elm_calendar.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/lib/elm_calendar.c b/src/lib/elm_calendar.c
index 5e1a3e85c..5ac5d8b30 100644
--- a/src/lib/elm_calendar.c
+++ b/src/lib/elm_calendar.c
@@ -928,6 +928,13 @@ elm_calendar_selected_time_set(Evas_Object *obj, struct tm *selected_time)
928 928
929 EINA_SAFETY_ON_NULL_RETURN(selected_time); 929 EINA_SAFETY_ON_NULL_RETURN(selected_time);
930 wd->selected_time = *selected_time; 930 wd->selected_time = *selected_time;
931 if (!wd->selected)
932 wd->selected = EINA_TRUE;
933 if (wd->selected_time.tm_year != wd->showed_time.tm_year)
934 wd->showed_time.tm_year = wd->selected_time.tm_year;
935 if (wd->selected_time.tm_mon != wd->showed_time.tm_mon)
936 wd->showed_time.tm_mon = wd->selected_time.tm_mon;
937
931 _fix_selected_time(wd); 938 _fix_selected_time(wd);
932 _populate(obj); 939 _populate(obj);
933 return; 940 return;
@@ -940,6 +947,9 @@ elm_calendar_selected_time_get(const Evas_Object *obj, struct tm *selected_time)
940 Widget_Data *wd = elm_widget_data_get(obj); 947 Widget_Data *wd = elm_widget_data_get(obj);
941 if (!wd) return EINA_FALSE; 948 if (!wd) return EINA_FALSE;
942 EINA_SAFETY_ON_NULL_RETURN_VAL(selected_time, EINA_FALSE); 949 EINA_SAFETY_ON_NULL_RETURN_VAL(selected_time, EINA_FALSE);
950 if ((wd->select_mode == ELM_CALENDAR_SELECT_MODE_ONDEMAND)
951 && (!wd->selected))
952 return EINA_FALSE;
943 *selected_time = wd->selected_time; 953 *selected_time = wd->selected_time;
944 return EINA_TRUE; 954 return EINA_TRUE;
945} 955}