2006-08-30 Michael Dominic Kostrzewa <michael.kostrzewa@nokia.com>
[hildon] / hildon-widgets / hildon-get-password-dialog.h
1 /*
2  * This file is part of hildon-libs
3  *
4  * Copyright (C) 2005, 2006 Nokia Corporation.
5  *
6  * Contact: Michael Dominic Kostrzewa <michael.kostrzewa@nokia.com>
7  *
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
11  * the License.
12  *
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.
17  *
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
21  * 02110-1301 USA
22  *
23  */
24
25 #ifndef __HILDON_GET_PASSWORD_DIALOG_H__
26 #define __HILDON_GET_PASSWORD_DIALOG_H__
27
28 #include <gtk/gtkdialog.h>
29
30 G_BEGIN_DECLS
31
32 #define HILDON_TYPE_GET_PASSWORD_DIALOG ( hildon_get_password_dialog_get_type() )
33
34 #define HILDON_GET_PASSWORD_DIALOG(obj) \
35   (GTK_CHECK_CAST (obj, HILDON_TYPE_GET_PASSWORD_DIALOG,\
36    HildonGetPasswordDialog))
37
38 #define HILDON_GET_PASSWORD_DIALOG_CLASS(klass) \
39   (GTK_CHECK_CLASS_CAST ((klass), HILDON_TYPE_GET_PASSWORD_DIALOG, \
40   HildonGetPasswordDialogClass))
41
42 #define HILDON_IS_GET_PASSWORD_DIALOG(obj) \
43   (GTK_CHECK_TYPE (obj, HILDON_TYPE_GET_PASSWORD_DIALOG))
44
45 #define HILDON_IS_GET_PASSWORD_DIALOG_CLASS(klass) \
46   (GTK_CHECK_CLASS_TYPE ((klass), HILDON_TYPE_GET_PASSWORD_DIALOG))
47
48
49 #define HILDON_GET_PASSWORD_DIALOG_TITLE           "ecdg_ti_get_old_password"
50 #define HILDON_GET_PASSWORD_DIALOG_PASSWORD        "ecdg_fi_get_old_pwd_enter_pwd"
51 #define HILDON_GET_PASSWORD_DIALOG_OK              "ecdg_bd_get_old_password_dialog_ok"
52 #define HILDON_GET_PASSWORD_DIALOG_CANCEL          "ecdg_bd_get_old_password_dialog_cancel"
53
54 #define HILDON_GET_PASSWORD_VERIFY_DIALOG_TITLE    "ecdg_ti_verify_password"
55 #define HILDON_GET_PASSWORD_VERIFY_DIALOG_PASSWORD "ecdg_fi_verify_pwd_enter_pwd"
56 #define HILDON_GET_PASSWORD_VERIFY_DIALOG_OK       "ecdg_bd_verify_password_dialog_ok"
57 #define HILDON_GET_PASSWORD_VERIFY_DIALOG_CANCEL   "ecdg_bd_verify_password_dialog_cancel"
58
59 #define HILDON_GET_PASSWORD_DIALOG_MAX_CHARS       "ckdg_ib_maximum_characters_reached"
60
61 typedef struct _HildonGetPasswordDialog      HildonGetPasswordDialog;
62 typedef struct _HildonGetPasswordDialogClass HildonGetPasswordDialogClass;
63
64 struct _HildonGetPasswordDialog {
65     GtkDialog parent;
66 };
67
68 struct _HildonGetPasswordDialogClass {
69     GtkDialogClass parent_class;
70 };
71
72 GType      hildon_get_password_dialog_get_type(void) G_GNUC_CONST;
73
74 GtkWidget *hildon_get_password_dialog_new              (GtkWindow   *parent,
75                                                         gboolean     get_old);
76
77 GtkWidget *hildon_get_password_dialog_new_with_default (GtkWindow   *parent,
78                                                         const gchar *password,
79                                                         gboolean     get_old);
80
81 void       hildon_get_password_dialog_set_domain       (HildonGetPasswordDialog *dialog, 
82                                                         const gchar             *domain);
83
84 void       hildon_get_password_dialog_set_caption      (HildonGetPasswordDialog *dialog,
85                                                         const gchar             *new_caption);
86
87 void       hildon_get_password_dialog_set_max_characters(HildonGetPasswordDialog *dialog,
88                                                          gint                     max_characters);
89
90 const gchar * hildon_get_password_dialog_get_password(HildonGetPasswordDialog * dialog);
91
92
93 #ifndef HILDON_DISABLE_DEPRECATED
94 void       hildon_get_password_dialog_set_title        (HildonGetPasswordDialog *dialog,
95                                                         const gchar             *new_title);
96 #endif /* HILDON_DISABLE_DEPRECATED */
97
98 G_END_DECLS
99 #endif /* __HILDON_GET_PASSWORD_DIALOG_H__ */