diff options
author | Gerald Combs <gerald@wireshark.org> | 2006-03-08 20:55:32 +0000 |
---|---|---|
committer | Gerald Combs <gerald@wireshark.org> | 2006-03-08 20:55:32 +0000 |
commit | 9406c5db24b03444140ab81fdb13f6a186e1e8a5 (patch) | |
tree | b35df42ea208c1120a98c32020fae4c9b2e751be /gtk/webbrowser.c | |
parent | def11f9418610a95bccc68e5a31a32bb335099be (diff) |
Use Unicode for all native Win32 calls. Unicode Windows applications
use UTF-16 internally and GTK+ 2.x uses UTF-8, which means we have to
do a lots of conversions.
Add utf_8to16() and utf_16to8 convenience functions to strutil.c.
svn path=/trunk/; revision=17534
Diffstat (limited to 'gtk/webbrowser.c')
-rw-r--r-- | gtk/webbrowser.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/gtk/webbrowser.c b/gtk/webbrowser.c index 5632ca87ea..e0be890eb3 100644 --- a/gtk/webbrowser.c +++ b/gtk/webbrowser.c @@ -50,6 +50,9 @@ #if defined(G_OS_WIN32) /* Win32 - use Windows shell services to start a browser */ #include <windows.h> +/* We're using Unicode */ +#include <tchar.h> +#include <epan/strutil.h> /* if WIN32_LEAN_AND_MEAN is defined, shellapi.h is needed too */ #include <shellapi.h> #elif defined (HAVE_OS_X_FRAMEWORKS) @@ -95,7 +98,7 @@ browser_open_url (const gchar *url) { #if defined(G_OS_WIN32) - return ((gint) ShellExecute (HWND_DESKTOP, "open", url, NULL, NULL, SW_SHOWNORMAL) > 32); + return ((gint) ShellExecute (HWND_DESKTOP, _T("open"), utf_8to16(url), NULL, NULL, SW_SHOWNORMAL) > 32); #elif defined(HAVE_OS_X_FRAMEWORKS) |