Treat the file name as utf8 when finding the file name for the window

title.


git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@13645 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
David Hampton
2006-03-16 03:43:06 +00:00
parent 7e1d372f74
commit b5506a00c8
2 changed files with 5 additions and 2 deletions

View File

@@ -1,5 +1,8 @@
2006-03-15 David Hampton <hampton@employees.org>
* src/gnome-utils/gnc-main-window.c: Treat the file name as utf8
when finding the file name for the window title.
* src/gnome-utils/gnc-main-window.c: Don't create a new window for
a page if there's already an open blank window. Fixes 334672.

View File

@@ -1128,9 +1128,9 @@ gnc_main_window_generate_title (GncMainWindow *window)
filename = _("<no file>");
else {
/* The Gnome HIG 2.0 recommends only the file name (no path) be used. (p15) */
ptr = strrchr(filename, '/');
ptr = g_utf8_strrchr(filename, -1, G_DIR_SEPARATOR);
if (ptr != NULL)
filename = ptr+1;
filename = g_utf8_next_char(ptr);
}
priv = GNC_MAIN_WINDOW_GET_PRIVATE(window);