Revert "app: append insensitive reason to GimpAction proxy tooltip."
This reverts commit bf9a292723
.
I messed up copying the commit to cherry pick.
This commit is contained in:
@ -368,30 +368,12 @@ static void
|
|||||||
gimp_action_set_proxy_tooltip (GimpAction *action,
|
gimp_action_set_proxy_tooltip (GimpAction *action,
|
||||||
GtkWidget *proxy)
|
GtkWidget *proxy)
|
||||||
{
|
{
|
||||||
const gchar *tooltip;
|
const gchar *tooltip = gimp_action_get_tooltip (action);
|
||||||
const gchar *reason = NULL;
|
|
||||||
gchar *escaped_reason = NULL;
|
|
||||||
gchar *markup;
|
|
||||||
|
|
||||||
tooltip = gimp_action_get_tooltip (action);
|
if (tooltip)
|
||||||
|
gimp_help_set_help_data (proxy, tooltip,
|
||||||
gimp_action_get_sensitive (action, &reason);
|
|
||||||
if (reason)
|
|
||||||
escaped_reason = g_markup_escape_text (reason, -1);
|
|
||||||
|
|
||||||
markup = g_strdup_printf ("%s%s" /* Action tooltip */
|
|
||||||
"<i><span weight='light'>%s</span></i>", /* Inactive reason */
|
|
||||||
tooltip,
|
|
||||||
escaped_reason && tooltip ? "\n" : "",
|
|
||||||
escaped_reason);
|
|
||||||
|
|
||||||
if (tooltip || escaped_reason)
|
|
||||||
gimp_help_set_help_data_with_markup (proxy, markup,
|
|
||||||
g_object_get_qdata (G_OBJECT (proxy),
|
g_object_get_qdata (G_OBJECT (proxy),
|
||||||
GIMP_HELP_ID));
|
GIMP_HELP_ID));
|
||||||
|
|
||||||
g_free (escaped_reason);
|
|
||||||
g_free (markup);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
Reference in New Issue
Block a user