RoutingDirection
Defines the routing directions for routed events in the Telerik WinControls framework.
Routed events can travel through the element tree in two different directions, allowing for sophisticated event handling patterns that enable both preview (tunneling) and bubbling behavior. This enumeration specifies which direction a particular routed event should follow.
The routing direction affects the order in which elements in the visual tree receive and process the event, enabling different event handling strategies for various UI scenarios.
Definition
Namespace:Telerik.WinControls
Assembly:Telerik.WinControls.dll
Syntax:
public enum RoutingDirection
Fields
Indicates a bubbling event that travels from the target element up through the element hierarchy.
Bubble = 1
Bubbling events start at the target element and travel upward through parent elements toward the root of the element tree. This allows parent elements to respond to events that originated in their child elements, enabling common patterns like event delegation and aggregate handling.
Indicates a tunneling event that travels from the root element down to the target element.
Tunnel = 0
Tunneling events (also known as preview events) start at the root of the element tree and travel downward through parent elements until they reach the target element. This allows parent elements to preview and potentially handle or cancel events before they reach their intended target, providing opportunities for validation, filtering, or preprocessing.