[gtk/matthiasc/for-master] label: Disable unavailable actions
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/matthiasc/for-master] label: Disable unavailable actions
- Date: Sat, 8 Aug 2020 13:53:51 +0000 (UTC)
commit d3320a3782d68e2e2f6945f97d77f5124bc0afdc
Author: Matthias Clasen <mclasen redhat com>
Date: Sat Aug 8 09:51:47 2020 -0400
label: Disable unavailable actions
Fixes: #3034
gtk/gtklabel.c | 3 +++
1 file changed, 3 insertions(+)
---
diff --git a/gtk/gtklabel.c b/gtk/gtklabel.c
index 9a4f010fc9..1e9f566346 100644
--- a/gtk/gtklabel.c
+++ b/gtk/gtklabel.c
@@ -5395,9 +5395,12 @@ gtk_label_update_actions (GtkLabel *self)
link = gtk_label_get_focus_link (self, NULL);
}
+ gtk_widget_action_set_enabled (widget, "clipboard.cut", FALSE);
gtk_widget_action_set_enabled (widget, "clipboard.copy", has_selection);
+ gtk_widget_action_set_enabled (widget, "clipboard.paste", FALSE);
gtk_widget_action_set_enabled (widget, "selection.select-all",
gtk_label_get_selectable (self));
+ gtk_widget_action_set_enabled (widget, "selection.delete", FALSE);
gtk_widget_action_set_enabled (widget, "link.open", !has_selection && link);
gtk_widget_action_set_enabled (widget, "link.copy", !has_selection && link);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]