summaryrefslogtreecommitdiff
path: root/gtk/gtklinkbutton.c
diff options
context:
space:
mode:
authorChristian Dywan <cdywan@src.gnome.org>2008-10-30 08:49:18 +0000
committerChristian Dywan <cdywan@src.gnome.org>2008-10-30 08:49:18 +0000
commit0a91e7600ed098ebe53add385b80e0bb783890cb (patch)
tree60dc5c8328406a9d2beab498424f317248a3c11f /gtk/gtklinkbutton.c
parent040865e7e83b18d757b841355593afdad47bd102 (diff)
downloadgtk+-0a91e7600ed098ebe53add385b80e0bb783890cb.tar.gz
Bug 557316 – GtkLinkButton should consider user-defined tooltip
* gtk/gtklinkbutton.c (gtk_link_button_query_tooltip_cb): Only override the tooltip if not previously set svn path=/trunk/; revision=21728
Diffstat (limited to 'gtk/gtklinkbutton.c')
-rw-r--r--gtk/gtklinkbutton.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gtk/gtklinkbutton.c b/gtk/gtklinkbutton.c
index 9a6d134e99..6db17a933b 100644
--- a/gtk/gtklinkbutton.c
+++ b/gtk/gtklinkbutton.c
@@ -620,7 +620,9 @@ gtk_link_button_query_tooltip_cb (GtkWidget *widget,
label = gtk_button_get_label (GTK_BUTTON (link_button));
uri = link_button->priv->uri;
- if (label && *label != '\0' && uri && strcmp (label, uri) != 0)
+ if (!gtk_widget_get_tooltip_text (widget)
+ && !gtk_widget_get_tooltip_markup (widget)
+ && label && *label != '\0' && uri && strcmp (label, uri) != 0)
{
gtk_tooltip_set_text (tooltip, uri);
return TRUE;