Version: Unity 6.2 Alpha (6000.2)
LanguageEnglish
  • C#

EventBase.StopImmediatePropagation

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Declaration

public void StopImmediatePropagation();

Description

Stops the propagation of the event to other targets, and prevents other subscribers to the event on this target to receive the event.

The event is not sent to other elements along the propagation path. If the propagation is in the PropagationPhase.TrickleDown phase, this prevents event handlers from executing on children of the EventBase.currentTarget, including on the event's EventBase.target itself, and prevents all event handlers using the TrickleDown.NoTrickleDown option from executing (see CallbackEventHandler.RegisterCallback). If the propagation is in the PropagationPhase.BubbleUp phase, this prevents event handlers from executing on parents of the EventBase.currentTarget.

This method has the same effect as EventBase.StopPropagation except on execution of other event handlers on the EventBase.currentTarget.

Calling this method does not prevent some internal actions to be processed, such as an element getting focused as a result of a PointerDownEvent.

Refer to the Dispatch events manual page for more information and examples.

Additional resources: EventBase.StopPropagation

Copyright © 2023 Unity Technologies
优美缔软件(上海)有限公司 版权所有
"Unity"、Unity 徽标及其他 Unity 商标是 Unity Technologies 或其附属机构在美国及其他地区的商标或注册商标。其他名称或品牌是其各自所有者的商标。
公安部备案号:
31010902002961