From f4ecaaed31db0aa5d71c05dd3f04dc2833ad29fe Mon Sep 17 00:00:00 2001 From: John Mark Bell Date: Sat, 16 Jul 2005 14:35:25 +0000 Subject: [project @ 2005-07-16 14:35:20 by jmb] - Convert Messages files to UTF-8 encoding. - Replace local_encoding_name() with platform specific utf8_[to,from]_local_encoding() functions - this allows mapping of 8bit characters 0x80->0x9f (inclusive). - All text that is rendered by the RISC OS Wimp is now converted to the system local encoding prior to display. - Lose the horrendous hack that was messages_get_key() - Menu text is now translated to system local encoding on the fly (if necessary) rather than at menu creation time. This allows the system alphabet to change under us and our menus remain usable. - The Languages menu now lists all languages that are present in the LangNames file. In the case of selecting the UI language, those languages which are not available are shaded. svn path=/import/netsurf/; revision=1796 --- desktop/browser.c | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) (limited to 'desktop/browser.c') diff --git a/desktop/browser.c b/desktop/browser.c index d048e7ca5..335dd9954 100644 --- a/desktop/browser.c +++ b/desktop/browser.c @@ -480,30 +480,14 @@ void browser_window_stop_throbber(struct browser_window *bw) void browser_window_update(struct browser_window *bw, bool scroll_to_top) { - char *title_local_enc; struct box *pos; int x, y; - utf8_convert_ret err; if (!bw->current_content) return; if (bw->current_content->title != NULL) { - err = utf8_to_enc(bw->current_content->title, - local_encoding_name(), 0, &title_local_enc); - if (err != UTF8_CONVERT_OK) { - /* A bad encoding should never happen, - * so assert this */ - assert(err != UTF8_CONVERT_BADENC); - LOG(("utf8_to_enc failed")); - /* use utf-8 encoded title instead */ - gui_window_set_title(bw->window, - bw->current_content->title); - } - else { - gui_window_set_title(bw->window, title_local_enc); - free(title_local_enc); - } + gui_window_set_title(bw->window, bw->current_content->title); } else gui_window_set_title(bw->window, bw->current_content->url); -- cgit v1.2.3