--- gdm-2.27.4/gui/simple-greeter/gdm-greeter-panel.c.orig	2009-09-06 11:02:08.080991001 +0900
+++ gdm-2.27.4/gui/simple-greeter/gdm-greeter-panel.c	2009-09-06 20:47:22.197673747 +0900
@@ -77,6 +77,7 @@ enum {
         LANGUAGE_SELECTED,
         LAYOUT_SELECTED,
         SESSION_SELECTED,
+        HIDE_DIALOG_SELECTED,
         NUMBER_OF_SIGNALS
 };
 
@@ -456,6 +457,17 @@ gdm_greeter_panel_class_init (GdmGreeter
                               G_TYPE_NONE,
                               1, G_TYPE_STRING);
 
+        signals[HIDE_DIALOG_SELECTED] =
+                g_signal_new ("hide-dialog-selected",
+                              G_TYPE_FROM_CLASS (object_class),
+                              G_SIGNAL_RUN_LAST,
+                              G_STRUCT_OFFSET (GdmGreeterPanelClass, hide_dialog_selected),
+                              NULL,
+                              NULL,
+                              g_cclosure_marshal_VOID__VOID,
+                              G_TYPE_NONE,
+                              0);
+
         g_object_class_install_property (object_class,
                                          PROP_MONITOR,
                                          g_param_spec_int ("monitor",
@@ -488,6 +500,14 @@ on_language_activated (GdmLanguageOption
 }
 
 static void
+on_language_hide_dialog (GdmLanguageOptionWidget *widget,
+                         GdmGreeterPanel         *panel)
+{
+
+        g_signal_emit (panel, signals[HIDE_DIALOG_SELECTED], 0);
+}
+
+static void
 on_layout_activated (GdmLayoutOptionWidget *widget,
                      GdmGreeterPanel       *panel)
 {
@@ -507,6 +527,15 @@ on_layout_activated (GdmLayoutOptionWidg
 
         g_free (layout);
 }
+
+static void
+on_layout_hide_dialog (GdmLayoutOptionWidget *widget,
+                         GdmGreeterPanel         *panel)
+{
+
+        g_signal_emit (panel, signals[HIDE_DIALOG_SELECTED], 0);
+}
+
 static void
 on_session_activated (GdmSessionOptionWidget *widget,
                       GdmGreeterPanel        *panel)
@@ -580,6 +609,9 @@ gdm_greeter_panel_init (GdmGreeterPanel 
         g_signal_connect (G_OBJECT (panel->priv->language_option_widget),
                           "language-activated",
                           G_CALLBACK (on_language_activated), panel);
+        g_signal_connect (G_OBJECT (panel->priv->language_option_widget),
+                          "language-hide-dialog",
+                          G_CALLBACK (on_language_hide_dialog), panel);
         gtk_box_pack_start (GTK_BOX (panel->priv->option_hbox), panel->priv->language_option_widget, FALSE, FALSE, 6);
         gdm_profile_end ("creating option widget");
 
@@ -587,6 +619,9 @@ gdm_greeter_panel_init (GdmGreeterPanel 
         g_signal_connect (G_OBJECT (panel->priv->layout_option_widget),
                           "layout-activated",
                           G_CALLBACK (on_layout_activated), panel);
+        g_signal_connect (G_OBJECT (panel->priv->layout_option_widget),
+                          "layout-hide-dialog",
+                          G_CALLBACK (on_layout_hide_dialog), panel);
         gtk_box_pack_start (GTK_BOX (panel->priv->option_hbox), panel->priv->layout_option_widget, FALSE, FALSE, 6);
 
         panel->priv->session_option_widget = gdm_session_option_widget_new ();
--- gdm-2.27.4/gui/simple-greeter/gdm-greeter-panel.h.orig	2009-09-06 11:02:22.045475854 +0900
+++ gdm-2.27.4/gui/simple-greeter/gdm-greeter-panel.h	2009-09-06 20:48:30.346016000 +0900
@@ -53,6 +53,8 @@ typedef struct
 
         void (* session_selected)            (GdmGreeterPanel *panel,
                                               const char      *text);
+
+        void (* hide_dialog_selected)        (GdmGreeterPanel *panel);
 } GdmGreeterPanelClass;
 
 GType                  gdm_greeter_panel_get_type                       (void);
--- gdm/gui/simple-greeter/gdm-greeter-session.c.orig	2009-06-26 12:51:54.000000000 +0900
+++ gdm/gui/simple-greeter/gdm-greeter-session.c	2009-09-07 10:33:19.000000000 +0900
@@ -236,6 +236,12 @@ on_select_layout (GdmGreeterSession     
 }
 
 static void
+on_select_hide_dialog (GdmGreeterSession     *session)
+{
+        gtk_window_present (GTK_WINDOW (session->priv->login_window));
+}
+
+static void
 on_select_user (GdmGreeterLoginWindow *login_window,
                 const char            *text,
                 GdmGreeterSession     *session)
@@ -336,6 +342,11 @@ toggle_panel (GdmGreeterSession *session
                                           G_CALLBACK (on_select_session),
                                           session);
 
+                g_signal_connect_swapped (session->priv->panel,
+                                          "hide-dialog-selected",
+                                          G_CALLBACK (on_select_hide_dialog),
+                                          session);
+
                 gtk_widget_show (session->priv->panel);
         } else {
                 gtk_widget_destroy (session->priv->panel);
--- gdm-2.27.4/gui/simple-greeter/gdm-language-option-widget.c.orig	2009-09-06 11:02:48.755326290 +0900
+++ gdm-2.27.4/gui/simple-greeter/gdm-language-option-widget.c	2009-09-06 11:03:18.154593003 +0900
@@ -50,6 +50,7 @@ struct GdmLanguageOptionWidgetPrivate
 
 enum {
         LANGUAGE_ACTIVATED,
+        LANGUAGE_HIDE_DIALOG,
         NUMBER_OF_SIGNALS
 };
 
@@ -94,6 +95,7 @@ gdm_language_option_widget_hide_dialog (
 {
         gtk_widget_destroy (widget->priv->dialog);
         widget->priv->dialog = NULL;
+        g_signal_emit (G_OBJECT (widget), signals[LANGUAGE_HIDE_DIALOG], 0);
 }
 
 static void
@@ -170,6 +172,16 @@ gdm_language_option_widget_class_init (G
                                                      G_TYPE_NONE,
                                                      0);
 
+        signals[LANGUAGE_HIDE_DIALOG] = g_signal_new ("language-hide-dialog",
+                                                       G_TYPE_FROM_CLASS (object_class),
+                                                       G_SIGNAL_RUN_FIRST,
+                                                       G_STRUCT_OFFSET (GdmLanguageOptionWidgetClass, language_hide_dialog),
+                                                       NULL,
+                                                       NULL,
+                                                       g_cclosure_marshal_VOID__VOID,
+                                                       G_TYPE_NONE,
+                                                       0);
+
         g_type_class_add_private (klass, sizeof (GdmLanguageOptionWidgetPrivate));
 }
 
--- gdm-2.27.4/gui/simple-greeter/gdm-language-option-widget.h.orig	2009-09-06 11:03:00.183503178 +0900
+++ gdm-2.27.4/gui/simple-greeter/gdm-language-option-widget.h	2009-09-06 11:03:18.155232364 +0900
@@ -48,6 +48,7 @@ typedef struct
         GdmRecentOptionWidgetClass    parent_class;
 
         void (* language_activated)        (GdmLanguageOptionWidget *widget);
+        void (* language_hide_dialog)      (GdmLanguageOptionWidget *widget);
 } GdmLanguageOptionWidgetClass;
 
 GType                  gdm_language_option_widget_get_type               (void);
--- gdm-2.27.4/gui/simple-greeter/gdm-layout-option-widget.c.orig	2009-09-06 11:45:00.201483649 +0900
+++ gdm-2.27.4/gui/simple-greeter/gdm-layout-option-widget.c	2009-09-06 20:36:45.416342832 +0900
@@ -50,6 +50,7 @@ struct GdmLayoutOptionWidgetPrivate
 
 enum {
         LAYOUT_ACTIVATED,
+        LAYOUT_HIDE_DIALOG,
         NUMBER_OF_SIGNALS
 };
 
@@ -97,6 +98,7 @@ gdm_layout_option_widget_hide_dialog (Gd
 {
         gtk_widget_destroy (widget->priv->dialog);
         widget->priv->dialog = NULL;
+        g_signal_emit (G_OBJECT (widget), signals [LAYOUT_HIDE_DIALOG], 0);
 }
 
 static void
@@ -173,6 +175,16 @@ gdm_layout_option_widget_class_init (Gdm
                                                   G_TYPE_NONE,
                                                   0);
 
+        signals[LAYOUT_HIDE_DIALOG] = g_signal_new ("layout-hide-dialog",
+                                                  G_TYPE_FROM_CLASS (object_class),
+                                                  G_SIGNAL_RUN_FIRST,
+                                                  G_STRUCT_OFFSET (GdmLayoutOptionWidgetClass, layout_hide_dialog),
+                                                  NULL,
+                                                  NULL,
+                                                  g_cclosure_marshal_VOID__VOID,
+                                                  G_TYPE_NONE,
+                                                  0);
+
         g_type_class_add_private (klass, sizeof (GdmLayoutOptionWidgetPrivate));
 }
 
--- gdm-2.27.4/gui/simple-greeter/gdm-layout-option-widget.h.orig	2009-09-06 11:49:20.453739941 +0900
+++ gdm-2.27.4/gui/simple-greeter/gdm-layout-option-widget.h	2009-09-06 11:49:54.262969756 +0900
@@ -48,6 +48,7 @@ typedef struct
         GdmRecentOptionWidgetClass    parent_class;
 
         void (* layout_activated)        (GdmLayoutOptionWidget *widget);
+        void (* layout_hide_dialog)      (GdmLayoutOptionWidget *widget);
 } GdmLayoutOptionWidgetClass;
 
 GType                  gdm_layout_option_widget_get_type               (void);
