+2001-10-03 Tor Lillqvist <tml@iki.fi>
+
+ * glib/gutils.c (Win32) (DllMain): New function (DLL entry point)
+ to tuck away actual DLL name.
+ (GLIB_LOCALE_DIR) Use actual DLL name, instead of assuming one
+ naming convention for DLLs.
+
+ * glib/glib.def: g_string_append_printf.
+
2001-10-02 Matthias Clasen <matthiasc@poet.de>
* glib/gstrfuncs.c, glib/giochannel.c: documentation update.
+2001-10-03 Tor Lillqvist <tml@iki.fi>
+
+ * glib/gutils.c (Win32) (DllMain): New function (DLL entry point)
+ to tuck away actual DLL name.
+ (GLIB_LOCALE_DIR) Use actual DLL name, instead of assuming one
+ naming convention for DLLs.
+
+ * glib/glib.def: g_string_append_printf.
+
2001-10-02 Matthias Clasen <matthiasc@poet.de>
* glib/gstrfuncs.c, glib/giochannel.c: documentation update.
+2001-10-03 Tor Lillqvist <tml@iki.fi>
+
+ * glib/gutils.c (Win32) (DllMain): New function (DLL entry point)
+ to tuck away actual DLL name.
+ (GLIB_LOCALE_DIR) Use actual DLL name, instead of assuming one
+ naming convention for DLLs.
+
+ * glib/glib.def: g_string_append_printf.
+
2001-10-02 Matthias Clasen <matthiasc@poet.de>
* glib/gstrfuncs.c, glib/giochannel.c: documentation update.
+2001-10-03 Tor Lillqvist <tml@iki.fi>
+
+ * glib/gutils.c (Win32) (DllMain): New function (DLL entry point)
+ to tuck away actual DLL name.
+ (GLIB_LOCALE_DIR) Use actual DLL name, instead of assuming one
+ naming convention for DLLs.
+
+ * glib/glib.def: g_string_append_printf.
+
2001-10-02 Matthias Clasen <matthiasc@poet.de>
* glib/gstrfuncs.c, glib/giochannel.c: documentation update.
+2001-10-03 Tor Lillqvist <tml@iki.fi>
+
+ * glib/gutils.c (Win32) (DllMain): New function (DLL entry point)
+ to tuck away actual DLL name.
+ (GLIB_LOCALE_DIR) Use actual DLL name, instead of assuming one
+ naming convention for DLLs.
+
+ * glib/glib.def: g_string_append_printf.
+
2001-10-02 Matthias Clasen <matthiasc@poet.de>
* glib/gstrfuncs.c, glib/giochannel.c: documentation update.
+2001-10-03 Tor Lillqvist <tml@iki.fi>
+
+ * glib/gutils.c (Win32) (DllMain): New function (DLL entry point)
+ to tuck away actual DLL name.
+ (GLIB_LOCALE_DIR) Use actual DLL name, instead of assuming one
+ naming convention for DLLs.
+
+ * glib/glib.def: g_string_append_printf.
+
2001-10-02 Matthias Clasen <matthiasc@poet.de>
* glib/gstrfuncs.c, glib/giochannel.c: documentation update.
+2001-10-03 Tor Lillqvist <tml@iki.fi>
+
+ * glib/gutils.c (Win32) (DllMain): New function (DLL entry point)
+ to tuck away actual DLL name.
+ (GLIB_LOCALE_DIR) Use actual DLL name, instead of assuming one
+ naming convention for DLLs.
+
+ * glib/glib.def: g_string_append_printf.
+
2001-10-02 Matthias Clasen <matthiasc@poet.de>
* glib/gstrfuncs.c, glib/giochannel.c: documentation update.
+2001-10-03 Tor Lillqvist <tml@iki.fi>
+
+ * glib/gutils.c (Win32) (DllMain): New function (DLL entry point)
+ to tuck away actual DLL name.
+ (GLIB_LOCALE_DIR) Use actual DLL name, instead of assuming one
+ naming convention for DLLs.
+
+ * glib/glib.def: g_string_append_printf.
+
2001-10-02 Matthias Clasen <matthiasc@poet.de>
* glib/gstrfuncs.c, glib/giochannel.c: documentation update.
g_string_append
g_string_append_c
g_string_append_len
+ g_string_append_printf
g_string_append_unichar
g_string_ascii_down
g_string_assign
g_string_prepend_len
g_string_prepend_unichar
g_string_printf
- g_string_printfa
g_string_sized_new
g_string_truncate
g_string_up
; and vice versa, i.e.:
; compatibility of Dia 0.87 with tml's latest Gtk+ version (2000-12-26)
g_dirname=g_path_get_dirname
- g_string_sprintfa=g_string_printfa
+ g_string_sprintfa=g_string_append_printf
g_string_sprintf=g_string_printf
#ifdef G_OS_WIN32
+/* DllMain function needed to tuck away the GLib DLL name */
+
+static char dll_name[MAX_PATH];
+
+BOOL WINAPI
+DllMain (HINSTANCE hinstDLL,
+ DWORD fdwReason,
+ LPVOID lpvReserved)
+{
+ switch (fdwReason)
+ {
+ case DLL_PROCESS_ATTACH:
+ GetModuleFileName ((HMODULE) hinstDLL, dll_name, sizeof (dll_name));
+ break;
+ }
+
+ return TRUE;
+}
+
/* On Windows we don't want any hard-coded path names */
#undef GLIB_LOCALE_DIR
-/* It's OK to leak the g_win32_get_...() and g_strdup_printf() results
- * below, as this macro is called only once. */
+/* It's OK to leak the g_win32_get_...() and g_path_get_basename() results
+ * below, as this macro is called only once.
+ * Use the actual DLL name of the GLib DLL, i.e. don't assume the
+ * GLib DLL has a certain name.
+ */
#define GLIB_LOCALE_DIR \
g_win32_get_package_installation_subdirectory \
(GETTEXT_PACKAGE, \
- g_strdup_printf ("libglib-%d.%d-%d.dll", \
- GLIB_MAJOR_VERSION, \
- GLIB_MINOR_VERSION, \
- GLIB_MICRO_VERSION - GLIB_BINARY_AGE), \
+ g_path_get_basename (dll_name), \
"share\\locale")
#endif /* !G_OS_WIN32 */
}
#endif /* ENABLE_NLS */
-
-
* returned string should be deallocated with g_free().
*
* Returns: newly-allocated locale name.
- */
+ **/
gchar *
g_win32_getlocale (void)
* The returned string should be deallocated with g_free().
*
* Returns: newly-allocated error message
- */
+ **/
gchar *
g_win32_error_message (gint error)
{
* The return value should be freed with g_free() when not needed any longer.
**/
-
gchar *
g_win32_get_package_installation_directory (gchar *package,
gchar *dll_name)
* g_win32_get_package_installation_directory() with the @package and
* @dll_name parameters. The return value should be freed with
* g_free() when no longer needed.
- */
+ **/
gchar *
g_win32_get_package_installation_subdirectory (gchar *package,