widget: Drop the ::popup-menu signal

This is now done in widgets which have context
menus.
This commit is contained in:
Matthias Clasen 2020-03-19 00:56:46 -04:00
parent 53f29ba427
commit c8fd6407a8

View File

@ -520,7 +520,6 @@ enum {
MNEMONIC_ACTIVATE,
MOVE_FOCUS,
KEYNAV_FAILED,
POPUP_MENU,
ACCEL_CLOSURES_CHANGED,
CAN_ACTIVATE_ACCEL,
QUERY_TOOLTIP,
@ -1675,32 +1674,6 @@ gtk_widget_class_init (GtkWidgetClass *klass)
G_TYPE_FROM_CLASS (klass),
_gtk_marshal_BOOLEAN__INT_INT_BOOLEAN_OBJECTv);
/**
* GtkWidget::popup-menu:
* @widget: the object which received the signal
*
* This signal gets emitted whenever a widget should pop up a context
* menu. This usually happens through the standard key binding mechanism;
* by pressing a certain key while a widget is focused, the user can cause
* the widget to pop up a menu. For example, the #GtkEntry widget creates
* a menu with clipboard commands. See the
* [Popup Menu Migration Checklist][checklist-popup-menu]
* for an example of how to use this signal.
*
* Returns: %TRUE if a menu was activated
*/
widget_signals[POPUP_MENU] =
g_signal_new (I_("popup-menu"),
G_TYPE_FROM_CLASS (klass),
G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION,
G_STRUCT_OFFSET (GtkWidgetClass, popup_menu),
_gtk_boolean_handled_accumulator, NULL,
_gtk_marshal_BOOLEAN__VOID,
G_TYPE_BOOLEAN, 0);
g_signal_set_va_marshaller (widget_signals[POPUP_MENU],
G_TYPE_FROM_CLASS (klass),
_gtk_marshal_BOOLEAN__VOIDv);
/**
* GtkWidget::accel-closures-changed:
* @widget: the object which received the signal.
@ -1742,15 +1715,6 @@ gtk_widget_class_init (GtkWidgetClass *klass)
G_TYPE_FROM_CLASS (klass),
_gtk_marshal_BOOLEAN__UINTv);
gtk_widget_class_add_binding_signal (klass,
GDK_KEY_F10, GDK_SHIFT_MASK,
"popup-menu",
NULL);
gtk_widget_class_add_binding_signal (klass,
GDK_KEY_Menu, 0,
"popup-menu",
NULL);
gtk_widget_class_set_accessible_type (klass, GTK_TYPE_WIDGET_ACCESSIBLE);
gtk_widget_class_set_css_name (klass, I_("widget"));
}