diff --git a/src/core/main.c b/src/core/main.c index 567e98892..a4e49bce2 100644 --- a/src/core/main.c +++ b/src/core/main.c @@ -484,43 +484,19 @@ meta_run (void) meta_ui_set_current_theme (meta_prefs_get_theme ()); - /* Try to find some theme that'll work if the theme preference - * doesn't exist. First try Simple (the default theme) then just - * try anything in the themes directory. + /* If the theme preference does not exists, fallback to + * Adwaita (the default theme), or abort if that doesn't + * exists. */ if (!meta_ui_have_a_theme ()) - meta_ui_set_current_theme ("Simple"); - + meta_ui_set_current_theme ("Adwaita"); + if (!meta_ui_have_a_theme ()) - { - const char *dir_entry = NULL; - GError *err = NULL; - GDir *themes_dir = NULL; - - if (!(themes_dir = g_dir_open (MUTTER_DATADIR"/themes", 0, &err))) - { - meta_fatal (_("Failed to scan themes directory: %s\n"), err->message); - g_error_free (err); - } - else - { - while (((dir_entry = g_dir_read_name (themes_dir)) != NULL) && - (!meta_ui_have_a_theme ())) - { - meta_ui_set_current_theme (dir_entry); - } - - g_dir_close (themes_dir); - } - } - - if (!meta_ui_have_a_theme ()) - meta_fatal (_("Could not find a theme! Be sure %s exists and contains the usual themes.\n"), - MUTTER_DATADIR"/themes"); + meta_fatal ("Adwaita theme missing, please install the gnome-themes-standard package"); if (!meta_display_open ()) meta_exit (META_EXIT_ERROR); - + g_main_loop_run (meta_main_loop); meta_finalize ();