[evince] On Windows, determine the data directory on runtime.
- From: Fridrich Strba <strba src gnome org>
- To: svn-commits-list gnome org
- Subject: [evince] On Windows, determine the data directory on runtime.
- Date: Tue, 23 Jun 2009 03:40:15 -0400 (EDT)
commit f575f06bfcb2e335f6b2089b3dba570e1da77198
Author: Fridrich Strba <fridrich strba bluewin ch>
Date: Tue Jun 23 09:13:56 2009 +0200
On Windows, determine the data directory on runtime.
thumbnailer/evince-thumbnailer.c | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/thumbnailer/evince-thumbnailer.c b/thumbnailer/evince-thumbnailer.c
index 9cc572f..3598fdf 100644
--- a/thumbnailer/evince-thumbnailer.c
+++ b/thumbnailer/evince-thumbnailer.c
@@ -88,7 +88,13 @@ evince_thumbnail_pngenc_get (EvDocument *document, const char *thumbnail, int si
if (overlaid_icon_name) {
GdkPixbuf *overlaid_pixbuf;
+#ifdef G_OS_WIN32
+ gchar *dir = g_win32_get_package_installation_directory_of_module (NULL);
+ gchar *overlaid_icon_path = g_build_filename (dir, "share", "evince", overlaid_icon_name, NULL);
+ g_free (dir);
+#else
gchar *overlaid_icon_path = g_strdup_printf ("%s/%s", DATADIR, overlaid_icon_name);
+#endif
overlaid_pixbuf = gdk_pixbuf_new_from_file (overlaid_icon_path, NULL);
g_free (overlaid_icon_path);
if (overlaid_pixbuf != NULL) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]