[seahorse] documented the process of creating a new gkr keyring



commit 5c272eb9dfff23c2cde308419327131398e600c7
Author: Thorsten Sick <thorsten sick email de>
Date:   Mon Aug 24 19:20:02 2009 +0200

    documented the process of creating a new gkr keyring
    
    Signed-off-by: Stef Walter <stef memberwebs com>

 gkr/seahorse-gkr-add-keyring.c      |   39 +++++++++++++++++++++++++++++++++++
 gkr/seahorse-gkr-keyring-commands.c |    7 ++++++
 libseahorse/seahorse-widget.c       |   15 +++++++++++++
 3 files changed, 61 insertions(+), 0 deletions(-)
---
diff --git a/gkr/seahorse-gkr-add-keyring.c b/gkr/seahorse-gkr-add-keyring.c
index ca51565..81b3c24 100644
--- a/gkr/seahorse-gkr-add-keyring.c
+++ b/gkr/seahorse-gkr-add-keyring.c
@@ -29,6 +29,20 @@
 
 #include <glib/gi18n.h>
 
+/**
+ * SECTION:seahorse-gkr-add-keyring
+ * @short_description: Contains the functions to add a new gnome-keyring keyring
+ *
+ **/
+
+/**
+ * keyring_add_done:
+ * @result:GNOME_KEYRING_RESULT_CANCELLED or GNOME_KEYRING_RESULT_OK
+ * @data: the swidget
+ *
+ * This callback is called when the new keyring was created. It updates the
+ * internal seahorse list of keyrings
+ */
 static void
 keyring_add_done (GnomeKeyringResult result, gpointer data)
 {
@@ -63,6 +77,14 @@ keyring_add_done (GnomeKeyringResult result, gpointer data)
 	seahorse_widget_destroy (swidget);
 }
 
+/**
+ * on_add_keyring_name_changed:
+ * @entry: the entry widget
+ * @swidget: the seahorse widget
+ *
+ * Sets the widget named "ok" in the @swidget to sensitive as soon as the
+ * entry @entry contains text
+ */
 G_MODULE_EXPORT void
 on_add_keyring_name_changed (GtkEntry *entry, SeahorseWidget *swidget)
 {
@@ -70,6 +92,16 @@ on_add_keyring_name_changed (GtkEntry *entry, SeahorseWidget *swidget)
 	seahorse_widget_set_sensitive (swidget, "ok", keyring && keyring[0]);
 }
 
+/**
+ * on_add_keyring_properties_response:
+ * @dialog: ignored
+ * @response: the response of the choose-keyring-name dialog
+ * @swidget: the seahorse widget
+ *
+ * Requests a password using #gnome_keyring_create - the name of the keyring
+ * was already entered by the user. The password will be requested in a window
+ * provided by gnome-keyring
+ */
 G_MODULE_EXPORT void
 on_add_keyring_properties_response (GtkDialog *dialog, int response, SeahorseWidget *swidget)
 {
@@ -97,6 +129,13 @@ on_add_keyring_properties_response (GtkDialog *dialog, int response, SeahorseWid
 	}
 }
 
+/**
+ * seahorse_gkr_add_keyring_show:
+ * @parent: the parent widget of the new window
+ *
+ * Displays the window requesting the keyring name. Starts the whole
+ * "create a new keyring" process.
+ */
 void
 seahorse_gkr_add_keyring_show (GtkWindow *parent)
 {
diff --git a/gkr/seahorse-gkr-keyring-commands.c b/gkr/seahorse-gkr-keyring-commands.c
index 59bc249..cf7c5b7 100644
--- a/gkr/seahorse-gkr-keyring-commands.c
+++ b/gkr/seahorse-gkr-keyring-commands.c
@@ -94,6 +94,13 @@ refresh_all_keyrings (SeahorseCommands *self)
 	g_object_unref (op);
 }
 
+/**
+ * on_gkr_add_keyring:
+ * @action:
+ * @unused: ignored
+ *
+ * calls the function that shows the add keyring window
+ */
 static void
 on_gkr_add_keyring (GtkAction *action, gpointer unused)
 {
diff --git a/libseahorse/seahorse-widget.c b/libseahorse/seahorse-widget.c
index f55e396..ceb98f9 100644
--- a/libseahorse/seahorse-widget.c
+++ b/libseahorse/seahorse-widget.c
@@ -393,6 +393,13 @@ seahorse_widget_get_toplevel (SeahorseWidget     *swidget)
     return widget;
 }
 
+/**
+ * seahorse_widget_get_widget:
+ * @swidget: a #SeahorseWidget
+ * @identifier: the name of the widget to get
+ *
+ * Returns: the widget named @identifier in @swidget
+ */
 GtkWidget*
 seahorse_widget_get_widget (SeahorseWidget *swidget, const char *identifier)
 {
@@ -431,6 +438,14 @@ seahorse_widget_set_visible (SeahorseWidget *swidget, const char *identifier,
         gtk_widget_hide (widget);
 }
 
+/**
+ * seahorse_widget_set_sensitive:
+ * @swidget: the #SeahorseWidget to find the widget @identifier in
+ * @identifier: the name of the widget to et sensitive
+ * @sensitive: TRUE if the widget should be switched to sensitive
+ *
+ * Sets the widget @identifier 's sensitivity to @sensitive
+ */
 void             
 seahorse_widget_set_sensitive (SeahorseWidget *swidget, const char *identifier,
                                gboolean sensitive)



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]