[gnome-initial-setup] language: Rearrange another tiny piece of code



commit 6ddbcbf6783486f2110c22989fcd0e482d13c2e2
Author: Jasper St. Pierre <jstpierre mecheye net>
Date:   Fri Mar 15 18:56:12 2013 -0400

    language: Rearrange another tiny piece of code

 .../pages/language/cc-language-chooser.c           |   19 ++++++++++++-------
 1 files changed, 12 insertions(+), 7 deletions(-)
---
diff --git a/gnome-initial-setup/pages/language/cc-language-chooser.c 
b/gnome-initial-setup/pages/language/cc-language-chooser.c
index 684fa47..827f663 100644
--- a/gnome-initial-setup/pages/language/cc-language-chooser.c
+++ b/gnome-initial-setup/pages/language/cc-language-chooser.c
@@ -367,17 +367,22 @@ child_activated (EggListBox      *box,
                  GtkWidget       *child,
                  CcLanguageChooser *chooser)
 {
+        CcLanguageChooserPrivate *priv = chooser->priv;
+        LanguageWidget *widget;
+
         if (child == NULL)
                 return;
-        else if (child == chooser->priv->no_results)
+
+        if (child == priv->no_results)
                 return;
-        else if (child == chooser->priv->more_item)
+
+        if (child == priv->more_item) {
                 show_more (chooser);
-        else
-                {
-                        LanguageWidget *widget = get_language_widget (child);
-                        set_locale_id (chooser, widget->locale_id);
-                }
+                return;
+        }
+
+        widget = get_language_widget (child);
+        set_locale_id (chooser, widget->locale_id);
 }
 
 typedef struct {


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