colorbutton: Don't add a customize menu

The color swatch in the button does not need a
context menu. Turn it off.
This commit is contained in:
Matthias Clasen 2020-04-03 17:42:22 -04:00
parent 8991275fbd
commit 22211f29fb

View File

@ -266,6 +266,7 @@ gtk_color_button_init (GtkColorButton *button)
priv->swatch = gtk_color_swatch_new ();
gtk_widget_set_can_focus (priv->swatch, FALSE);
g_object_set (priv->swatch, "has-menu", FALSE, NULL);
layout = gtk_widget_create_pango_layout (GTK_WIDGET (button), "Black");
pango_layout_get_pixel_extents (layout, NULL, &rect);
g_object_unref (layout);