label: Fix assumptions regaring link
authorTimm Bäder <mail@baedert.org>
Thu, 2 Jan 2020 13:05:30 +0000 (14:05 +0100)
committerTimm Bäder <mail@baedert.org>
Tue, 7 Jan 2020 16:27:18 +0000 (17:27 +0100)
gtk/gtklabel.c

index 671f73d1551fd0e788cbab96e2ec51df71705671..b8d8d1cf6fa018682a0b234c8913442e1c8cf062 100644 (file)
@@ -6032,14 +6032,15 @@ gtk_label_update_actions (GtkLabel *label)
   GtkLabelLink *link;
 
   if (priv->select_info)
-    has_selection = priv->select_info->selection_anchor != priv->select_info->selection_end;
-  else
-    has_selection = FALSE;
-
-  if (priv->select_info->link_clicked)
-    link = priv->select_info->active_link;
+    {
+      has_selection = priv->select_info->selection_anchor != priv->select_info->selection_end;
+      link = priv->select_info->active_link;
+    }
   else
-    link = gtk_label_get_focus_link (label);
+    {
+      has_selection = FALSE;
+      link = gtk_label_get_focus_link (label);
+    }
 
   gtk_widget_action_set_enabled (widget, "clipboard.copy", has_selection);
   gtk_widget_action_set_enabled (widget, "selection.select-all",