GtkEventController — Self-contained handler of series of events
GObject ╰── GtkEventController ├── GtkEventControllerKey ├── GtkEventControllerMotion ├── GtkEventControllerScroll ├── GtkGesture ╰── GtkPadController
GtkPropagationPhase gtk_event_controller_get_propagation_phase (
Gets the propagation phase at which
controller handles events.
the propagation phase
void gtk_event_controller_set_propagation_phase (
Sets the propagation phase at which a controller handles events.
GTK_PHASE_NONE, no automatic event handling will be performed, but other additional gesture maintenance will. In that phase, the events can be managed by calling
a propagation phase
gboolean gtk_event_controller_handle_event (
const GdkEvent *event);
Feeds an events into
controller , so it can be interpreted and the controller actions triggered.
TRUE if the event was potentially useful to trigger the controller action
GtkWidget * gtk_event_controller_get_widget (
Returns the GtkWidget this controller relates to.
typedef struct _GtkEventController GtkEventController;
Describes the stage at which events are fed into a GtkEventController.
Events are not delivered automatically. Those can be manually fed through
Events are delivered in the capture phase. The capture phase happens before the bubble phase, runs from the toplevel down to the event widget. This option should only be used on containers that might possibly handle events before their children do.
Events are delivered in the bubble phase. The bubble phase happens after the capture phase, and before the default handlers are run. This phase runs from the event widget, up to the toplevel.
Events are delivered in the default widget event handlers, note that widget implementations must chain up on button, motion, touch and grab broken handlers for controllers in this phase to be run.
The propagation phase at which this controller will handle events.
Flags: Read / Write
Default value: GTK_PHASE_BUBBLE
© 2005–2020 The GNOME Project
Licensed under the GNU Lesser General Public License version 2.1 or later.