1 /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
3 * Copyright (C) 2018 Red Hat, Inc. (www.redhat.com)
5 * This library is free software: you can redistribute it and/or modify it
6 * under the terms of the GNU Lesser General Public License as published by
7 * the Free Software Foundation.
9 * This library is distributed in the hope that it will be useful, but
10 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
11 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License
14 * You should have received a copy of the GNU Lesser General Public License
15 * along with this library. If not, see <http://www.gnu.org/licenses/>.
18 #if !defined (__LIBEDATASERVERUI_H_INSIDE__) && !defined (LIBEDATASERVERUI_COMPILATION)
19 #error "Only <libedataserverui/libedataserverui.h> should be included directly."
22 #ifndef E_REMINDERS_WIDGET_H
23 #define E_REMINDERS_WIDGET_H
26 #include <libecal/libecal.h>
28 /* Standard GObject macros */
29 #define E_TYPE_REMINDERS_WIDGET \
30 (e_reminders_widget_get_type ())
31 #define E_REMINDERS_WIDGET(obj) \
32 (G_TYPE_CHECK_INSTANCE_CAST \
33 ((obj), E_TYPE_REMINDERS_WIDGET, ERemindersWidget))
34 #define E_REMINDERS_WIDGET_CLASS(cls) \
35 (G_TYPE_CHECK_CLASS_CAST \
36 ((cls), E_TYPE_REMINDERS_WIDGET, ERemindersWidgetClass))
37 #define E_IS_REMINDERS_WIDGET(obj) \
38 (G_TYPE_CHECK_INSTANCE_TYPE \
39 ((obj), E_TYPE_REMINDERS_WIDGET))
40 #define E_IS_REMINDERS_WIDGET_CLASS(cls) \
41 (G_TYPE_CHECK_CLASS_TYPE \
42 ((cls), E_TYPE_REMINDERS_WIDGET))
43 #define E_REMINDERS_WIDGET_GET_CLASS(obj) \
44 (G_TYPE_INSTANCE_GET_CLASS \
45 ((obj), E_TYPE_REMINDERS_WIDGET, ERemindersWidgetClass))
50 E_REMINDERS_WIDGET_COLUMN_OVERDUE
, /* gchar *, markup with time to start/overdue description */
51 E_REMINDERS_WIDGET_COLUMN_DESCRIPTION
, /* gchar *, markup describing the reminder, not component's DESCRIPTION property */
52 E_REMINDERS_WIDGET_COLUMN_REMINDER_DATA
,/* EReminderData * */
53 E_REMINDERS_WIDGET_N_COLUMNS
56 typedef struct _ERemindersWidget ERemindersWidget
;
57 typedef struct _ERemindersWidgetClass ERemindersWidgetClass
;
58 typedef struct _ERemindersWidgetPrivate ERemindersWidgetPrivate
;
63 * Contains only private data that should be read and manipulated using
64 * the functions below.
68 struct _ERemindersWidget
{
71 ERemindersWidgetPrivate
*priv
;
75 * ERemindersWidgetClass:
77 * Class structure for the #ERemindersWidget class.
81 struct _ERemindersWidgetClass
{
83 GtkGridClass parent_class
;
85 /* Signals and methods */
86 void (* changed
) (ERemindersWidget
*reminders
);
87 gboolean (* activated
) (ERemindersWidget
*reminders
,
88 const EReminderData
*rd
);
90 /* Padding for future expansion */
91 gpointer reserved
[10];
94 GType
e_reminders_widget_get_type (void) G_GNUC_CONST
;
97 e_reminders_widget_new (EReminderWatcher
*watcher
);
99 e_reminders_widget_get_watcher (ERemindersWidget
*reminders
);
100 GSettings
* e_reminders_widget_get_settings (ERemindersWidget
*reminders
);
101 gboolean
e_reminders_widget_is_empty (ERemindersWidget
*reminders
);
102 GtkTreeView
* e_reminders_widget_get_tree_view(ERemindersWidget
*reminders
);
103 void e_reminders_widget_report_error (ERemindersWidget
*reminders
,
105 const GError
*error
);
109 #endif /* E_REMINDERS_WIDGET_H */