# HG changeset patch # User Herman Bloggs # Date 1053023038 0 # Node ID fb0a5b872e6a4191a5ed38745c20df03fabe4fb6 # Parent a93c925721062e1f5b1ca9a1024ab558c45839f7 [gaim-migrate @ 5753] Third time lucky.. with localization.. thanx phroggie committer: Tailor Script diff -r a93c92572106 -r fb0a5b872e6a src/win32/systray.c --- a/src/win32/systray.c Thu May 15 15:36:32 2003 +0000 +++ b/src/win32/systray.c Thu May 15 18:23:58 2003 +0000 @@ -57,8 +57,6 @@ static SYSTRAY_STATE st_state=SYSTRAY_STATE_OFFLINE; static HMENU systray_menu=0; static HMENU systray_away_menu=0; -/* UTF-8 to locale conversion */ -gchar *locenc=NULL; /* * GLOBALS @@ -89,6 +87,7 @@ int item_count = SYSTRAY_CMND_SET_AWY; struct away_message *a = NULL; GSList *awy = away_messages; + char* locenc=NULL; /* Delete previous away submenu */ if(systray_away_menu) { @@ -112,6 +111,7 @@ } static void systray_show_menu(int x, int y, BOOL connected) { + char* locenc=NULL; /* need to call this so that the menu disappears if clicking outside of the menu scope */ SetForegroundWindow(systray_hwnd); @@ -303,6 +303,8 @@ } static void systray_create_menu(void) { + char* locenc=NULL; + /* create popup menu */ if((systray_menu = CreatePopupMenu())) { if(!AppendMenu(systray_menu, MF_STRING, SYSTRAY_CMND_PREFS, @@ -324,6 +326,8 @@ } static void systray_init_icon(HWND hWnd, HICON icon) { + char* locenc=NULL; + ZeroMemory(&wgaim_nid,sizeof(wgaim_nid)); wgaim_nid.cbSize=sizeof(NOTIFYICONDATA); wgaim_nid.hWnd=hWnd; @@ -338,6 +342,7 @@ } static void systray_change_icon(HICON icon, char* text) { + char *locenc=NULL; wgaim_nid.hIcon = icon; locenc = g_locale_from_utf8(text, -1, NULL, NULL, NULL); lstrcpy(wgaim_nid.szTip, locenc);