Release 4.0.0-preview1-00051
[platform/core/csapi/tizenfx.git] / src / ElmSharp / Interop / Interop.Elementary.CalendarView.cs
1 /*
2  * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
3  *
4  * Licensed under the Apache License, Version 2.0 (the License);
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an AS IS BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 using System;
18 using System.Runtime.InteropServices;
19
20 internal static partial class Interop
21 {
22     internal static partial class Elementary
23     {
24         internal enum Elm_Calendar_Mark_Repeat_Type
25         {
26             ELM_CALENDAR_UNIQUE = 0, /* Default value. Marks will be displayed only on event day. */
27             ELM_CALENDAR_DAILY, /* Marks will be displayed every day after event day (inclusive). */
28             ELM_CALENDAR_WEEKLY, /* Marks will be displayed every week after event day (inclusive) */
29             ELM_CALENDAR_MONTHLY, /* Marks will be displayed every month day that coincides to event day. */
30             ELM_CALENDAR_ANNUALLY, /* Marks will be displayed every year that coincides to event day (and month). */
31             LM_CALENDAR_LAST_DAY_OF_MONTH /* Marks will be displayed every last day of month after event day (inclusive). */
32         };
33
34         internal enum Elm_Calendar_Select_Mode
35         {
36             ELM_CALENDAR_SELECT_MODE_DEFAULT = 0, /* Default value. a day is always selected. */
37             ELM_CALENDAR_SELECT_MODE_ALWAYS, /* a day is always selected. */
38             ELM_CALENDAR_SELECT_MODE_NONE, /* None of the days can be selected. */
39             ELM_CALENDAR_SELECT_MODE_ONDEMAND /* User may have selected a day or not. */
40         }
41
42         [DllImport(Libraries.Elementary)]
43         internal static extern IntPtr elm_calendar_add(IntPtr parent);
44
45         [DllImport(Libraries.Elementary)]
46         internal static extern IntPtr elm_calendar_weekdays_names_get(IntPtr obj);
47
48         [DllImport(Libraries.Elementary)]
49         internal static extern void elm_calendar_weekdays_names_set(IntPtr obj, string[] weekdays);
50
51         [DllImport(Libraries.Elementary)]
52         internal static extern void elm_calendar_min_max_year_set(IntPtr obj, int min, int max);
53
54         [DllImport(Libraries.Elementary)]
55         internal static extern void elm_calendar_min_max_year_get(IntPtr obj, out int min, out int max);
56
57         [DllImport(Libraries.Elementary)]
58         internal static extern void elm_calendar_selected_time_set(IntPtr obj, ref Libc.SystemTime selectedtime);
59
60         [DllImport(Libraries.Elementary)]
61         internal static extern void elm_calendar_selected_time_get(IntPtr obj, ref Libc.SystemTime selectedtime);
62
63         [DllImport(Libraries.Elementary)]
64         internal static extern void elm_calendar_first_day_of_week_set(IntPtr obj, int day);
65
66         [DllImport(Libraries.Elementary)]
67         internal static extern int elm_calendar_first_day_of_week_get(IntPtr obj);
68
69         [DllImport(Libraries.Elementary)]
70         internal static extern void elm_calendar_selectable_set(IntPtr obj, int SelectedField);
71
72         [DllImport(Libraries.Elementary)]
73         internal static extern int elm_calendar_selectable_get(IntPtr obj);
74
75         [DllImport(Libraries.Elementary)]
76         internal static extern bool elm_calendar_displayed_time_get(IntPtr obj, out Libc.SystemTime displayedtime);
77
78         [DllImport(Libraries.Elementary)]
79         internal static extern void elm_calendar_interval_set(IntPtr obj, double interval);
80
81         [DllImport(Libraries.Elementary)]
82         internal static extern double elm_calendar_interval_get(IntPtr obj);
83
84         [DllImport(Libraries.Elementary)]
85         internal static extern void elm_calendar_select_mode_set(IntPtr obj, Elm_Calendar_Select_Mode mode);
86
87         [DllImport(Libraries.Elementary)]
88         internal static extern int elm_calendar_select_mode_get(IntPtr obj);
89
90         [DllImport(Libraries.Elementary)]
91         internal static extern IntPtr elm_calendar_mark_add(IntPtr obj, string type, ref Libc.SystemTime date, Elm_Calendar_Mark_Repeat_Type repeatType);
92
93         [DllImport(Libraries.Elementary)]
94         internal static extern void elm_calendar_mark_del(IntPtr markItem);
95
96         [DllImport(Libraries.Elementary)]
97         internal static extern void elm_calendar_marks_draw(IntPtr obj);
98
99         [DllImport(Libraries.Elementary)]
100         internal static extern void elm_calendar_marks_clear(IntPtr obj);
101
102         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
103         internal delegate string Elm_Calendar_Format_Cb(Libc.SystemTime date);
104
105         [DllImport(Libraries.Elementary)]
106         internal static extern void elm_calendar_format_function_set(IntPtr obj, Elm_Calendar_Format_Cb format_function);
107     }
108 }