[Xfce4-commits] [apps/xfdashboard] 01/01: Do not mistakenly "convert" dynamically added application button for non-favourites to favourites when reordering favourites

noreply at xfce.org noreply at xfce.org
Wed Sep 2 20:47:42 CEST 2015


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

nomad pushed a commit to branch master
in repository apps/xfdashboard.

commit ab6859fc8af85ecb54adad713bd83f0fdebdec48
Author: Stephan Haller <nomad at froevel.de>
Date:   Wed Sep 2 20:46:56 2015 +0200

    Do not mistakenly "convert" dynamically added application button for non-favourites to favourites when reordering favourites
---
 xfdashboard/quicklaunch.c |   16 +++++++---------
 1 file changed, 7 insertions(+), 9 deletions(-)

diff --git a/xfdashboard/quicklaunch.c b/xfdashboard/quicklaunch.c
index a1baf6c..213f4bc 100644
--- a/xfdashboard/quicklaunch.c
+++ b/xfdashboard/quicklaunch.c
@@ -843,7 +843,6 @@ static void _xfdashboard_quicklaunch_update_property_from_icons(XfdashboardQuick
 	XfdashboardQuicklaunchPrivate	*priv;
 	ClutterActor					*child;
 	ClutterActorIter				iter;
-	XfdashboardApplicationButton	*button;
 	GAppInfo						*desktopAppInfo;
 	gchar							*desktopFile;
 	GValue							*desktopValue;
@@ -869,19 +868,18 @@ static void _xfdashboard_quicklaunch_update_property_from_icons(XfdashboardQuick
 	{
 		desktopFile=NULL;
 
-		/* Only add desktop file if it is an application button and
-		 * provides a desktop ID or desktop file name
+		/* Only add desktop file if it is an application button for
+		 * a favourite and provides a desktop ID or desktop file name
 		 */
  		if(!XFDASHBOARD_IS_APPLICATION_BUTTON(child)) continue;
+		if(!xfdashboard_stylable_has_class(XFDASHBOARD_STYLABLE(child), "is-favourite-app")) continue;
 
-		button=XFDASHBOARD_APPLICATION_BUTTON(child);
-		desktopAppInfo=xfdashboard_application_button_get_app_info(button);
-		if(desktopAppInfo)
+		desktopAppInfo=xfdashboard_application_button_get_app_info(XFDASHBOARD_APPLICATION_BUTTON(child));
+		if(desktopAppInfo &&
+			XFDASHBOARD_IS_DESKTOP_APP_INFO(desktopAppInfo))
 		{
 			desktopFile=g_strdup(g_app_info_get_id(desktopAppInfo));
-			if(!desktopFile &&
-				XFDASHBOARD_IS_DESKTOP_APP_INFO(desktopAppInfo) &&
-				xfdashboard_stylable_has_class(XFDASHBOARD_STYLABLE(button), "is-favourite-app"))
+			if(!desktopFile)
 			{
 				GFile				*file;
 

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


More information about the Xfce4-commits mailing list