This function returns whether a GdkEventButton should trigger a context menu, according to platform conventions. The right mouse button always triggers context menus. Additionally, if Keymap.getModifierMask returns a non-0 mask for GDK_MODIFIER_INTENT_CONTEXT_MENU, then the left mouse button will also trigger a context menu if this modifier is pressed.

This function should always be used instead of simply checking for event->button == GDK_BUTTON_SECONDARY.

class Event

Return Value

Type: bool

TRUE if the event should trigger a context menu.