From c2baedba52745c97419725d59306b02880814408 Mon Sep 17 00:00:00 2001 From: Ettore Perazzoli Date: Fri, 22 Mar 2002 20:48:05 +0000 Subject: Removed. (load_pages): Use e_get_language_list() here instead. Also, free * e-shell-settings-dialog.c (get_language_list): Removed. (load_pages): Use e_get_language_list() here instead. Also, free using e_free_language_list(). svn path=/trunk/; revision=16232 --- shell/ChangeLog | 6 ++++++ shell/e-shell-settings-dialog.c | 27 ++++----------------------- 2 files changed, 10 insertions(+), 23 deletions(-) (limited to 'shell') diff --git a/shell/ChangeLog b/shell/ChangeLog index 145111b252..670a27ac4b 100644 --- a/shell/ChangeLog +++ b/shell/ChangeLog @@ -1,3 +1,9 @@ +2002-03-22 Ettore Perazzoli + + * e-shell-settings-dialog.c (get_language_list): Removed. + (load_pages): Use e_get_language_list() here instead. Also, free + using e_free_language_list(). + 2002-03-22 Dan Winship * evolution-storage.c (evolution_storage_update_folder): Fix a diff --git a/shell/e-shell-settings-dialog.c b/shell/e-shell-settings-dialog.c index aeb51e8469..33a4613c91 100644 --- a/shell/e-shell-settings-dialog.c +++ b/shell/e-shell-settings-dialog.c @@ -29,10 +29,11 @@ #include "e-corba-config-page.h" +#include "e-util/e-lang-utils.h" + #include #include - #include #include @@ -42,26 +43,6 @@ static EMultiConfigDialogClass *parent_class = NULL; -static GSList * -get_language_list (void) -{ - const char *env; - const char *p; - - env = g_getenv ("LANGUAGE"); - if (env == NULL) { - env = g_getenv ("LANG"); - if (env == NULL) - return NULL; - } - - p = strchr (env, '='); - if (p != NULL) - return g_slist_prepend (NULL, (void *) (p + 1)); - else - return g_slist_prepend (NULL, (void *) env); -} - static void load_pages (EShellSettingsDialog *dialog) { @@ -79,7 +60,7 @@ load_pages (EShellSettingsDialog *dialog) return; } - language_list = get_language_list (); + language_list = e_get_language_list (); for (i = 0; i < control_list->_length; i ++) { CORBA_Object corba_object; @@ -121,7 +102,7 @@ load_pages (EShellSettingsDialog *dialog) CORBA_free (control_list); - g_slist_free (language_list); + e_free_language_list (language_list); CORBA_exception_free (&ev); } -- cgit v1.2.3