[gdm/wip/release: 2/4] daemon: get rid of greeter language selection
- From: Ray Strode <halfline src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gdm/wip/release: 2/4] daemon: get rid of greeter language selection
- Date: Mon, 16 Dec 2013 17:53:20 +0000 (UTC)
commit 0b2d22f63b3e6b3185d4e9a93bb192a21a695f9e
Author: Ray Strode <rstrode redhat com>
Date: Mon Dec 16 10:55:53 2013 -0500
daemon: get rid of greeter language selection
These days the greeter doesn't let you pick a language at log in time.
This commit drops the interface, since it's unused, and we don't have
any API guarantees in libgdm.
daemon/gdm-session.c | 62 +-----------------------------------------------
daemon/gdm-session.h | 2 -
daemon/gdm-session.xml | 3 --
data/Xsession.in | 7 -----
4 files changed, 1 insertions(+), 73 deletions(-)
---
diff --git a/daemon/gdm-session.c b/daemon/gdm-session.c
index 508446a..e8e8f29 100644
--- a/daemon/gdm-session.c
+++ b/daemon/gdm-session.c
@@ -84,7 +84,6 @@ struct _GdmSessionPrivate
char *selected_program;
char *selected_session;
char *saved_session;
- char *selected_language;
char *saved_language;
char *selected_user;
char *user_x11_authority_file;
@@ -1240,20 +1239,6 @@ gdm_session_handle_client_select_session (GdmDBusGreeter *greeter_interf
}
static gboolean
-gdm_session_handle_client_select_language (GdmDBusGreeter *greeter_interface,
- GDBusMethodInvocation *invocation,
- const char *language,
- GdmSession *self)
-{
- if (self->priv->greeter_interface != NULL) {
- gdm_dbus_greeter_complete_select_language (greeter_interface,
- invocation);
- }
- gdm_session_select_language (self, language);
- return TRUE;
-}
-
-static gboolean
gdm_session_handle_client_select_user (GdmDBusGreeter *greeter_interface,
GDBusMethodInvocation *invocation,
const char *username,
@@ -1353,10 +1338,6 @@ export_greeter_interface (GdmSession *self,
G_CALLBACK (gdm_session_handle_client_select_session),
self);
g_signal_connect (greeter_interface,
- "handle-select-language",
- G_CALLBACK (gdm_session_handle_client_select_language),
- self);
- g_signal_connect (greeter_interface,
"handle-select-user",
G_CALLBACK (gdm_session_handle_client_select_user),
self);
@@ -2215,16 +2196,6 @@ gdm_session_send_environment (GdmSession *self,
}
static const char *
-get_language_name (GdmSession *self)
-{
- if (self->priv->selected_language != NULL) {
- return self->priv->selected_language;
- }
-
- return get_default_language_name (self);
-}
-
-static const char *
get_session_name (GdmSession *self)
{
/* FIXME: test the session names before we use them? */
@@ -2280,7 +2251,7 @@ setup_session_environment (GdmSession *self)
"DESKTOP_SESSION",
get_session_name (self));
- locale = get_language_name (self);
+ locale = get_default_language_name (self);
if (locale != NULL && locale[0] != '\0') {
gdm_session_set_environment_variable (self,
@@ -2496,9 +2467,6 @@ do_reset (GdmSession *self)
g_free (self->priv->saved_session);
self->priv->saved_session = NULL;
- g_free (self->priv->selected_language);
- self->priv->selected_language = NULL;
-
g_free (self->priv->saved_language);
self->priv->saved_language = NULL;
@@ -2755,33 +2723,6 @@ gdm_session_select_session (GdmSession *self,
}
}
-void
-gdm_session_select_language (GdmSession *self,
- const char *text)
-{
- GHashTableIter iter;
- gpointer key, value;
-
- g_free (self->priv->selected_language);
-
- if (strcmp (text, "__previous") == 0) {
- self->priv->selected_language = NULL;
- } else {
- self->priv->selected_language = g_strdup (text);
- }
-
- g_hash_table_iter_init (&iter, self->priv->conversations);
- while (g_hash_table_iter_next (&iter, &key, &value)) {
- GdmSessionConversation *conversation;
-
- conversation = (GdmSessionConversation *) value;
-
- gdm_dbus_worker_call_set_language_name (conversation->worker_proxy,
- get_language_name (self),
- NULL, NULL, NULL);
- }
-}
-
/* At some point we may want to read these right from
* the slave but for now I don't want the dependency */
static void
@@ -3018,7 +2959,6 @@ gdm_session_finalize (GObject *object)
g_free (self->priv->selected_user);
g_free (self->priv->selected_session);
g_free (self->priv->saved_session);
- g_free (self->priv->selected_language);
g_free (self->priv->saved_language);
g_free (self->priv->fallback_session_name);
diff --git a/daemon/gdm-session.h b/daemon/gdm-session.h
index 2511eca..8e6e4e3 100644
--- a/daemon/gdm-session.h
+++ b/daemon/gdm-session.h
@@ -151,8 +151,6 @@ void gdm_session_select_session_type (GdmSession *session,
const char *session_type);
void gdm_session_select_session (GdmSession *session,
const char *session_name);
-void gdm_session_select_language (GdmSession *session,
- const char *language);
void gdm_session_select_user (GdmSession *session,
const char *username);
void gdm_session_cancel (GdmSession *session);
diff --git a/daemon/gdm-session.xml b/daemon/gdm-session.xml
index cf3103a..97216c3 100644
--- a/daemon/gdm-session.xml
+++ b/daemon/gdm-session.xml
@@ -79,9 +79,6 @@
<method name="SelectSession">
<arg name="session" direction="in" type="s"/>
</method>
- <method name="SelectLanguage">
- <arg name="language" direction="in" type="s"/>
- </method>
<method name="SelectUser">
<arg name="username" direction="in" type="s"/>
</method>
diff --git a/data/Xsession.in b/data/Xsession.in
index 118518c..f253375 100755
--- a/data/Xsession.in
+++ b/data/Xsession.in
@@ -146,13 +146,6 @@ fi
unset XKB_IN_USE
-# Overwrite $LANG from /etc/profile (and friends) with the one picked in the
-# greeter
-if [ -n "$GDM_LANG" ]; then
- LANG="$GDM_LANG"
- export LANG
-fi
-
xhost +si:localuser:`id -un` || :
# run all system xinitrc shell scripts.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]