Login
Log in using an SSO provider:
Fedora Account System
Red Hat Associate
Red Hat Customer
Login using a Red Hat Bugzilla account
Forgot Password
Create an Account
Red Hat Bugzilla – Attachment 320840 Details for
Bug 466675
keyboard layout not correctly detected
Home
New
Search
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh92 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
[?]
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
another iteration
layout.patch (text/plain), 2.56 KB, created by
Matthias Clasen
on 2008-10-20 04:49:11 UTC
(
hide
)
Description:
another iteration
Filename:
MIME Type:
Creator:
Matthias Clasen
Created:
2008-10-20 04:49:11 UTC
Size:
2.56 KB
patch
obsolete
>--- gdm-2.24.0/daemon/gdm-session-direct.c 2008-08-21 00:31:47.000000000 -0400 >+++ hacked/daemon/gdm-session-direct.c 2008-10-20 00:20:05.000000000 -0400 >@@ -595,14 +595,41 @@ > return setlocale (LC_MESSAGES, NULL); > } > >+static char * >+get_system_default_layout (void) >+{ >+ gchar *text, *p, *q; >+ gsize *length; >+ char *result; >+ >+ result = NULL; >+ if (g_file_get_contents ("/etc/sysconfig/keyboard", &text, &length, NULL)) { >+ p = strstr (text, "KEYTABLE=\""); >+ if (p) { >+ p += strlen ("KEYTABLE=\""); >+ q = strchr (p, '"'); >+ if (q) { >+ result = g_strndup (p, q - p); >+ } >+ } >+ g_free (text); >+ } >+ >+ if (!result) { >+ result = g_strdup ("us"); >+ } >+ >+ return result; >+} >+ > static const char * > get_default_layout_name (GdmSessionDirect *session) > { >- if (session->priv->saved_layout != NULL) { >- return session->priv->saved_layout; >+ if (!session->priv->saved_layout) { >+ session->priv->saved_layout = get_system_default_layout (); > } > >- return "us"; >+ return session->priv->saved_layout; > } > > static char * >@@ -1971,9 +1998,10 @@ > "GDM_LANG", > get_language_name (session)); > >- gdm_session_direct_set_environment_variable (session, >- "GDM_KEYBOARD_LAYOUT", >- get_layout_name (session)); >+ if (g_strcmp0 (get_layout_name (session), get_system_default_layout ()) != 0) >+ gdm_session_direct_set_environment_variable (session, >+ "GDM_KEYBOARD_LAYOUT", >+ get_layout_name (session)); > > gdm_session_direct_set_environment_variable (session, > "DISPLAY", >--- gdm-2.24.0/daemon/gdm-session-settings.c 2008-07-10 11:07:42.000000000 -0400 >+++ hacked/daemon/gdm-session-settings.c 2008-10-19 23:55:02.000000000 -0400 >@@ -149,8 +149,7 @@ > { > g_return_if_fail (GDM_IS_SESSION_SETTINGS (settings)); > >- if (settings->priv->layout_name == NULL || >- strcmp (settings->priv->layout_name, layout_name) != 0) { >+ if (g_strcmp0 (settings->priv->layout_name, layout_name) != 0) { > settings->priv->layout_name = g_strdup (layout_name); > g_object_notify (G_OBJECT (settings), "layout-name"); > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 466675
:
320160
|
320161
|
320162
|
320737
| 320840