2008-07-30 Claudio Saavedra <csaavedra@igalia.com>
[hildon] / src / hildon-picker-dialog.h
1 /*
2  * This file is a part of hildon
3  *
4  * Copyright (C) 2005, 2008 Nokia Corporation.
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2 of the License, or (at your option) any later version. or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with this library; if not, write to the Free
18  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
19  */
20
21 #ifndef __HILDON_PICKER_DIALOG_H__
22 #define __HILDON_PICKER_DIALOG_H__
23
24 #include <gtk/gtk.h>
25
26 G_BEGIN_DECLS
27
28 #define HILDON_TYPE_PICKER_DIALOG             (hildon_picker_dialog_get_type ())
29 #define HILDON_PICKER_DIALOG(obj)             (G_TYPE_CHECK_INSTANCE_CAST ((obj), HILDON_TYPE_PICKER_DIALOG, HildonPickerDialog))
30 #define HILDON_PICKER_DIALOG_CLASS(vtable)    (G_TYPE_CHECK_CLASS_CAST ((vtable), HILDON_TYPE_PICKER_DIALOG, HildonPickerDialogClass))
31 #define HILDON_IS_PICKER_DIALOG(obj)          (G_TYPE_CHECK_INSTANCE_TYPE ((obj), HILDON_TYPE_PICKER_DIALOG))
32 #define HILDON_IS_PICKER_DIALOG_CLASS(vtable) (G_TYPE_CHECK_CLASS_TYPE ((vtable), HILDON_TYPE_PICKER_DIALOG))
33 #define HILDON_PICKER_DIALOG_GET_CLASS(inst)  (G_TYPE_INSTANCE_GET_CLASS ((inst), HILDON_TYPE_PICKER_DIALOG, HildonPickerDialogClass))
34
35 typedef struct _HildonPickerDialog HildonPickerDialog;
36 typedef struct _HildonPickerDialogClass HildonPickerDialogClass;
37 typedef struct _HildonPickerDialogPrivate HildonPickerDialogPrivate;
38
39 struct _HildonPickerDialog
40 {
41   GtkDialog parent_instance;
42
43   /*< private > */
44   HildonPickerDialogPrivate *priv;
45 };
46
47 struct _HildonPickerDialogClass
48 {
49   GtkDialogClass parent_class;
50
51   gboolean (* set_selector) (HildonPickerDialog * dialog,
52                              HildonTouchSelector * selector);
53 };
54
55 /* construction */
56 GType                hildon_picker_dialog_get_type         (void) G_GNUC_CONST;
57 GtkWidget           *hildon_picker_dialog_new              (GtkWindow * parent);
58
59 gboolean             hildon_picker_dialog_set_selector     (HildonPickerDialog * dialog,
60                                                             HildonTouchSelector * selector);
61 void                 hildon_picker_dialog_set_done_label   (HildonPickerDialog * dialog,
62                                                             const gchar * label);
63 const gchar         *hildon_picker_dialog_get_done_label   (HildonPickerDialog * dialog);
64 HildonTouchSelector *hildon_picker_dialog_get_selector     (HildonPickerDialog * dialog);
65
66 G_END_DECLS
67
68 #endif /* __HILDON_SELECTOR_H__ */