Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 9 Mar 2013 10:59:44 +0000 (UTC)
From:      Olivier Duchateau <olivierd@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r313702 - in head/x11-wm/xfce4-desktop: . files
Message-ID:  <201303091059.r29AxiET020263@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: olivierd
Date: Sat Mar  9 10:59:44 2013
New Revision: 313702
URL: http://svnweb.freebsd.org/changeset/ports/313702

Log:
  - Fix,  when no image is selected
  - Add patch for new GLib 2.32 API
  
  Submitted by:	Andrey Simonenko (by email)
  Approved by:	rene, miwi (mentors, implicit)
  Obtained from:	Xfce git repository

Added:
  head/x11-wm/xfce4-desktop/files/
  head/x11-wm/xfce4-desktop/files/patch-src__main.c   (contents, props changed)
  head/x11-wm/xfce4-desktop/files/patch-src__xfce-backdrop.c   (contents, props changed)
Modified:
  head/x11-wm/xfce4-desktop/Makefile

Modified: head/x11-wm/xfce4-desktop/Makefile
==============================================================================
--- head/x11-wm/xfce4-desktop/Makefile	Sat Mar  9 10:50:10 2013	(r313701)
+++ head/x11-wm/xfce4-desktop/Makefile	Sat Mar  9 10:59:44 2013	(r313702)
@@ -4,6 +4,7 @@
 
 PORTNAME=	xfce4-desktop
 PORTVERSION=	4.10.1
+PORTREVISION=	1
 CATEGORIES=	x11-wm xfce
 MASTER_SITES=	${MASTER_SITE_XFCE}
 MASTER_SITE_SUBDIR=	src/xfce/xfdesktop/${PORTVERSION:R}

Added: head/x11-wm/xfce4-desktop/files/patch-src__main.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/x11-wm/xfce4-desktop/files/patch-src__main.c	Sat Mar  9 10:59:44 2013	(r313702)
@@ -0,0 +1,13 @@
+--- ./src/main.c.orig	2013-03-02 16:37:34.000000000 +0000
++++ ./src/main.c	2013-03-09 11:32:10.000000000 +0000
+@@ -255,8 +255,10 @@
+     xfce_textdomain(GETTEXT_PACKAGE, LOCALEDIR, "UTF-8");
+     
+ #if defined(ENABLE_FILE_ICONS) || defined(USE_DESKTOP_MENU)
++#if !GLIB_CHECK_VERSION (2, 32, 0)
+     g_thread_init(NULL);
+ #endif
++#endif
+ #ifdef ENABLE_FILE_ICONS
+     dbus_g_thread_init();
+ #endif

Added: head/x11-wm/xfce4-desktop/files/patch-src__xfce-backdrop.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/x11-wm/xfce4-desktop/files/patch-src__xfce-backdrop.c	Sat Mar  9 10:59:44 2013	(r313702)
@@ -0,0 +1,37 @@
+--- ./src/xfce-backdrop.c.orig	2013-03-02 16:42:00.000000000 +0000
++++ ./src/xfce-backdrop.c	2013-03-07 19:23:41.000000000 +0000
+@@ -924,6 +924,8 @@
+ xfce_backdrop_get_pixbuf(XfceBackdrop *backdrop)
+ {
+     GdkPixbuf *final_image, *image = NULL, *tmp;
++    GdkPixbufFormat *format = NULL;
++    gboolean apply_backdrop_image = FALSE;
+     gint i, j;
+     gint w, h, iw = 0, ih = 0;
+     XfceBackdropImageStyle istyle;
+@@ -933,8 +935,12 @@
+     
+     g_return_val_if_fail(XFCE_IS_BACKDROP(backdrop), NULL);
+     
+-    if(backdrop->priv->show_image && backdrop->priv->image_path)
+-        gdk_pixbuf_get_file_info(backdrop->priv->image_path, &iw, &ih);
++    if(backdrop->priv->show_image && backdrop->priv->image_path) {
++        format = gdk_pixbuf_get_file_info(backdrop->priv->image_path, &iw, &ih);
++        /* make sure we have a usable backdrop image */
++        if(format != NULL)
++            apply_backdrop_image = TRUE;
++    }
+ 
+     if(backdrop->priv->width == 0 || backdrop->priv->height == 0) {
+         w = iw;
+@@ -956,9 +962,7 @@
+             final_image = create_solid(&backdrop->priv->color1, w, h, FALSE, 0xff);
+     }
+     
+-    /*check if the file exists,
+-     *and if it doesn't then make the background the single colour*/
+-    if(!g_file_test(backdrop->priv->image_path, G_FILE_TEST_EXISTS)) {
++    if(!apply_backdrop_image) {
+         if(backdrop->priv->brightness != 0)
+             final_image = adjust_brightness(final_image, backdrop->priv->brightness);
+         



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201303091059.r29AxiET020263>