2 * This file is part of hildon-libs
4 * Copyright (C) 2005, 2006 Nokia Corporation, all rights reserved.
6 * Contact: Michael Dominic Kostrzewa <michael.kostrzewa@nokia.com>
8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Lesser General Public License
10 * as published by the Free Software Foundation; version 2.1 of
13 * This library is distributed in the hope that it will be useful, but
14 * WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Lesser General Public License for more details.
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with this library; if not, write to the Free Software
20 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
25 #ifndef __HILDON_WEEKDAY_PICKER_H__
26 #define __HILDON_WEEKDAY_PICKER_H__
28 #include <gtk/gtkcontainer.h>
32 * HILDON_TYPE_WEEKDAY_PICKER:
34 * Macro for getting type of weekday picker.
37 #define HILDON_TYPE_WEEKDAY_PICKER ( hildon_weekday_picker_get_type() )
39 #define HILDON_WEEKDAY_PICKER(obj) \
40 (GTK_CHECK_CAST (obj, HILDON_TYPE_WEEKDAY_PICKER, \
42 #define HILDON_WEEKDAY_PICKER_CLASS(klass) \
43 (GTK_CHECK_CLASS_CAST ((klass), \
44 HILDON_TYPE_WEEKDAY_PICKER, HildonWeekdayPickerClass))
45 #define HILDON_IS_WEEKDAY_PICKER(obj) \
46 (GTK_CHECK_TYPE (obj, HILDON_TYPE_WEEKDAY_PICKER))
47 #define HILDON_IS_WEEKDAY_PICKER_CLASS(klass) \
48 (GTK_CHECK_CLASS_TYPE ((klass), HILDON_TYPE_WEEKDAY_PICKER))
50 * HildonWeekdayPicker:
52 * Internal struct for weekday picker.
54 typedef struct _HildonWeekdayPicker HildonWeekdayPicker;
55 typedef struct _HildonWeekdayPickerClass HildonWeekdayPickerClass;
57 struct _HildonWeekdayPicker {
61 struct _HildonWeekdayPickerClass {
62 GtkContainerClass parent_class;
64 void (*selection_changed) (HildonWeekdayPicker * self);
67 GType hildon_weekday_picker_get_type(void) G_GNUC_CONST;
70 * hildon_weekday_picker_new:
72 * Creates a new #HildonWeekdayPicker.
74 * Return value: New #HildonWeekdayPicker.
76 GtkWidget *hildon_weekday_picker_new(void);
79 * hildon_weekday_picker_set_day:
80 * @picker: #HildonWeekdayPicker.
81 * @day: #GDateWeekday.
83 * Select specified weekday.
86 void hildon_weekday_picker_set_day(HildonWeekdayPicker * picker,
90 * hildon_weekday_picker_unset_day:
91 * @picker: #HildonWeekdayPicker.
92 * @day: #GDateWeekday.
94 * Unselect specified weekday.
97 void hildon_weekday_picker_unset_day(HildonWeekdayPicker * picker,
101 * hildon_weekday_picker_toggle_day:
102 * @picker: #HildonWeekdayPicker.
103 * @day: #GDateWeekday.
105 * Toggle current status of the specified weekday.
108 void hildon_weekday_picker_toggle_day(HildonWeekdayPicker * picker,
112 * hildon_weekday_picker_set_all:
113 * @picker: #HildonWeekdayPicker.
115 * Select all weekdays.
118 void hildon_weekday_picker_set_all(HildonWeekdayPicker * picker);
121 * hildon_weekday_picker_unset_all:
122 * @picker: #HildonWeekdayPicker.
124 * Unselect all weekdays.
127 void hildon_weekday_picker_unset_all(HildonWeekdayPicker * picker);
130 * hildon_weekday_picker_isset_day:
131 * @picker: #HildonWeekdayPicker.
132 * @day: #GDateWeekday.
134 * Check if the specified weekday is set.
136 * Return value: Set/not set.
138 gboolean hildon_weekday_picker_isset_day(HildonWeekdayPicker * picker,
142 #endif /* __HILDON_WEEKDAY_PICKER_H__ */