diff options
author | Jesús González <jgonzalez@gdr-sistemas.com> | 2015-06-01 23:14:07 +0200 |
---|---|---|
committer | Jesús González <jgonzalez@gdr-sistemas.com> | 2015-06-01 23:14:07 +0200 |
commit | b7778d2853d781998a4c6e8733c9cf76b7b6588e (patch) | |
tree | bec777cb0e55e436a3a62ab88564895f6494acce /src | |
parent | 1afa5d0f606763524225dea9c5d0a953f808adf7 (diff) | |
parent | 89c9af9a315de9d88cac40e15f08899ad78b9bf7 (diff) | |
download | lightdm-b7778d2853d781998a4c6e8733c9cf76b7b6588e.tar.gz |
Merged parent branch
Diffstat (limited to 'src')
-rw-r--r-- | src/lightdm.c | 11 | ||||
-rw-r--r-- | src/seat-unity.c | 8 |
2 files changed, 10 insertions, 9 deletions
diff --git a/src/lightdm.c b/src/lightdm.c index 61ae3f2c..f2c300f2 100644 --- a/src/lightdm.c +++ b/src/lightdm.c @@ -153,13 +153,14 @@ get_config_sections (const gchar *seat_name) gchar **groups, **i; GList *config_sections = NULL; - /* Keep this so it won't break existing config files using old [SeatDefaults] */ + /* Load seat defaults first and support old method of [SeatDefaults] */ + config_sections = g_list_append (config_sections, g_strdup ("Seat:*")); config_sections = g_list_append (config_sections, g_strdup ("SeatDefaults")); groups = config_get_groups (config_get_instance ()); for (i = groups; *i; i++) { - if (g_str_has_prefix (*i, "Seat:")) + if (g_str_has_prefix (*i, "Seat:") && strcmp (*i, "Seat:*") != 0) { const gchar *seat_name_glob = *i + strlen ("Seat:"); if (g_pattern_match_simple (seat_name_glob, seat_name ? seat_name : "")) @@ -184,10 +185,6 @@ set_seat_properties (Seat *seat, const gchar *seat_name) const gchar *section = link->data; keys = config_get_keys (config_get_instance (), section); - /* Keep this until [SeatDefaults] support is definitely removed */ - if (strcmp (section, "SeatDefaults") == 0 && keys) - l_warning (seat, "[SeatDefaults] is deprecated and won't be supported in the future. Use [Seat:*] instead!"); - l_debug (seat, "Loading properties from config section %s", section); for (i = 0; keys && keys[i]; i++) { @@ -1382,6 +1379,8 @@ main (int argc, char **argv) config_set_string (config_get_instance (), "Seat:*", "pam-greeter-service", "lightdm-greeter"); if (!config_has_key (config_get_instance (), "Seat:*", "xserver-command")) config_set_string (config_get_instance (), "Seat:*", "xserver-command", "X"); + if (!config_has_key (config_get_instance (), "Seat:*", "xmir-command")) + config_set_string (config_get_instance (), "Seat:*", "xmir-command", "Xmir"); if (!config_has_key (config_get_instance (), "Seat:*", "xserver-share")) config_set_boolean (config_get_instance (), "Seat:*", "xserver-share", TRUE); if (!config_has_key (config_get_instance (), "Seat:*", "unity-compositor-command")) diff --git a/src/seat-unity.c b/src/seat-unity.c index 32d30b23..642be0aa 100644 --- a/src/seat-unity.c +++ b/src/seat-unity.c @@ -203,9 +203,11 @@ create_x_server (Seat *seat) x_server = x_server_local_new (); - command = seat_get_string_property (seat, "xserver-command"); - if (command) - x_server_local_set_command (x_server, command); + command = seat_get_string_property (seat, "xmir-command"); + /* Fall back to using X if Xmir is not available as this was the previous way XMir worked */ + if (strcmp (command, "Xmir") == 0 && !g_find_program_in_path ("Xmir")) + command = seat_get_string_property (seat, "xserver-command"); + x_server_local_set_command (x_server, command); id = g_strdup_printf ("x-%d", SEAT_UNITY (seat)->priv->next_x_server_id); SEAT_UNITY (seat)->priv->next_x_server_id++; |