[Xfce4-commits] [apps/xfdashboard] 01/03: Do not rely on clutter_x11_has_composite_extension() to check for Composite extension at X server

noreply at xfce.org noreply at xfce.org
Fri Jun 2 08:39:37 CEST 2017


This is an automated email from the git hooks/post-receive script.

n   o   m   a   d       p   u   s   h   e   d       a       c   o   m   m   i   t       t   o       b   r   a   n   c   h       m   a   s   t   e   r   
   in repository apps/xfdashboard.

commit 6456f050fac55657b43a583e5615fa6374405a27
Author: Stephan Haller <nomad at froevel.de>
Date:   Thu May 18 09:38:58 2017 +0200

    Do not rely on clutter_x11_has_composite_extension() to check for Composite extension at X server
---
 libxfdashboard/x11/window-content-x11.c | 14 ++++++++++----
 1 file changed, 10 insertions(+), 4 deletions(-)

diff --git a/libxfdashboard/x11/window-content-x11.c b/libxfdashboard/x11/window-content-x11.c
index 65e7bc4..23c8315 100644
--- a/libxfdashboard/x11/window-content-x11.c
+++ b/libxfdashboard/x11/window-content-x11.c
@@ -621,6 +621,8 @@ static void _xfdashboard_window_content_x11_check_extension(void)
 	int			damageError=0;
 #endif
 #ifdef HAVE_XCOMPOSITE
+	int			compositeEventBase=0;
+	int			compositeError=0;
 	int			compositeMajor, compositeMinor;
 #endif
 
@@ -636,7 +638,7 @@ static void _xfdashboard_window_content_x11_check_extension(void)
 	/* Check for composite extenstion */
 	_xfdashboard_window_content_x11_have_composite_extension=FALSE;
 #ifdef HAVE_XCOMPOSITE
-	if(clutter_x11_has_composite_extension())
+	if(XCompositeQueryExtension(display, &compositeEventBase, &compositeError))
 	{
 		compositeMajor=compositeMinor=0;
 		if(XCompositeQueryVersion(display, &compositeMajor, &compositeMinor))
@@ -661,11 +663,15 @@ static void _xfdashboard_window_content_x11_check_extension(void)
 	_xfdashboard_window_content_x11_damage_event_base=0;
 
 #ifdef HAVE_XDAMAGE
-	if(!XDamageQueryExtension(display, &_xfdashboard_window_content_x11_damage_event_base, &damageError))
+	if(XDamageQueryExtension(display, &_xfdashboard_window_content_x11_damage_event_base, &damageError))
 	{
-		g_warning(_("Query for X damage extension resulted in error code %d - using only still images of windows"), damageError);
+		_xfdashboard_window_content_x11_have_damage_extension=TRUE;
 	}
-		else _xfdashboard_window_content_x11_have_damage_extension=TRUE;
+		else
+		{
+			g_warning(_("Query for X damage extension resulted in error code %d - using only still images of windows"),
+						damageError);
+		}
 #endif
 }
 

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Xfce4-commits mailing list