[gnome-control-center] keyboard: typedef the shortcut types



commit 47770ed40c5a1846e14cd4b167ce5d808d52fdc9
Author: Bastien Nocera <hadess hadess net>
Date:   Tue Feb 15 17:58:25 2011 +0000

    keyboard: typedef the shortcut types

 panels/keyboard/keyboard-shortcuts.c |   20 ++++++++++----------
 1 files changed, 10 insertions(+), 10 deletions(-)
---
diff --git a/panels/keyboard/keyboard-shortcuts.c b/panels/keyboard/keyboard-shortcuts.c
index 5505b38..db86d84 100644
--- a/panels/keyboard/keyboard-shortcuts.c
+++ b/panels/keyboard/keyboard-shortcuts.c
@@ -58,13 +58,20 @@ typedef struct
   Comparison comparison;
 } KeyListEntry;
 
+typedef enum
+{
+  BINDING_GROUP_SYSTEM,
+  BINDING_GROUP_APPS,
+  BINDING_GROUP_USER,
+} BindingGroupType;
+
 typedef struct
 {
   char *gconf_key;
   guint keyval;
   guint keycode;
   EggVirtualModifierType mask;
-  int group;
+  BindingGroupType group;
   gboolean editable;
   GtkTreeModel *model;
   char *description;
@@ -80,13 +87,6 @@ typedef struct
 
 enum
 {
-  BINDING_GROUP_SYSTEM,
-  BINDING_GROUP_APPS,
-  BINDING_GROUP_USER,
-};
-
-enum
-{
   DETAIL_DESCRIPTION_COLUMN,
   DETAIL_KEYENTRY_COLUMN,
   DETAIL_N_COLUMNS
@@ -336,7 +336,7 @@ keybinding_command_changed (GConfClient *client,
 static void
 append_section (GtkBuilder         *builder,
                 const gchar        *title,
-                int                 group,
+                BindingGroupType    group,
                 const KeyListEntry *keys_list)
 {
   GPtrArray *keys_array;
@@ -439,7 +439,7 @@ append_section (GtkBuilder         *builder,
         {
           key_entry->desc_gconf_key =  g_strdup (keys_list[i].description_name);
           key_entry->desc_editable = gconf_client_key_is_writable (client, key_entry->desc_gconf_key, NULL);
-          key_entry->gconf_cnxn_desc = gconf_client_notify_add (client, 
+          key_entry->gconf_cnxn_desc = gconf_client_notify_add (client,
                                                                 key_entry->desc_gconf_key,
                                                                 (GConfClientNotifyFunc) &keybinding_description_changed,
                                                                 key_entry, NULL, NULL);



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