Exemplo n.º 1
0
gboolean
garcon_menu_element_equal (GarconMenuElement *a,
                           GarconMenuElement *b)
{
  g_return_val_if_fail (GARCON_IS_MENU_ELEMENT (a), FALSE);
  g_return_val_if_fail (GARCON_IS_MENU_ELEMENT (b), FALSE);

  if (G_TYPE_FROM_INSTANCE (a) != G_TYPE_FROM_INSTANCE (b))
    return FALSE;

  return (*GARCON_MENU_ELEMENT_GET_IFACE (a)->equal) (a, b);
}
static gint _xfdashboard_applications_menu_model_resort_section_callback(ClutterModel *inModel,
																				const GValue *inLeft,
																				const GValue *inRight,
																				gpointer inUserData)
{
	GObject					*leftValue=g_value_get_object(inLeft);
	GObject					*rightValue=g_value_get_object(inLeft);
	const gchar				*leftName=NULL;
	const gchar				*rightName=NULL;

	if(leftValue &&
		GARCON_IS_MENU_ELEMENT(leftValue))
	{
		leftName=garcon_menu_element_get_name(GARCON_MENU_ELEMENT(leftValue));
	}

	if(rightValue &&
		GARCON_IS_MENU_ELEMENT(rightValue))
	{
		rightName=garcon_menu_element_get_name(GARCON_MENU_ELEMENT(rightValue));
	}

	return(g_strcmp0(leftName, rightName));
}
Exemplo n.º 3
0
gboolean
garcon_menu_element_get_visible (GarconMenuElement *element)
{
  g_return_val_if_fail (GARCON_IS_MENU_ELEMENT (element), FALSE);
  return (*GARCON_MENU_ELEMENT_GET_IFACE (element)->get_visible) (element);
}
Exemplo n.º 4
0
const gchar*
garcon_menu_element_get_icon_name (GarconMenuElement *element)
{
  g_return_val_if_fail (GARCON_IS_MENU_ELEMENT (element), NULL);
  return (*GARCON_MENU_ELEMENT_GET_IFACE (element)->get_icon_name) (element);
}
Exemplo n.º 5
0
gboolean
garcon_menu_element_get_show_in_environment (GarconMenuElement *element)
{
  g_return_val_if_fail (GARCON_IS_MENU_ELEMENT (element), FALSE);
  return (*GARCON_MENU_ELEMENT_GET_IFACE (element)->get_show_in_environment) (element);
}