# Uses of Class
javafx.scene.input.ContextMenuEvent

Packages that use ContextMenuEvent
Package
Description
javafx.scene
Provides the core set of base classes for the JavaFX Scene Graph API.
javafx.scene.input
Provides the set of classes for mouse and keyboard input event handling.

- ## Uses of ContextMenuEvent in javafx.scene

  Methods in javafx.scene that return types with arguments of type ContextMenuEvent
  Modifier and Type
  Method
  Description
  `final EventHandler<? super ContextMenuEvent>`
  Node.`getOnContextMenuRequested()`
  Gets the value of the `onContextMenuRequested` property.
  `final EventHandler<? super ContextMenuEvent>`
  Scene.`getOnContextMenuRequested()`
  Gets the value of the `onContextMenuRequested` property.
  `final ObjectProperty<EventHandler<? super ContextMenuEvent>>`
  Node.`onContextMenuRequestedProperty()`
  Defines a function to be called when a context menu has been requested on this `Node`.
  `final ObjectProperty<EventHandler<? super ContextMenuEvent>>`
  Scene.`onContextMenuRequestedProperty()`
  Defines a function to be called when a mouse button has been clicked (pressed and released) on this `Scene`.
  Method parameters in javafx.scene with type arguments of type ContextMenuEvent
  Modifier and Type
  Method
  Description
  `final void`
  Node.`setOnContextMenuRequested(EventHandler<? super ContextMenuEvent> value)`
  Sets the value of the `onContextMenuRequested` property.
  `final void`
  Scene.`setOnContextMenuRequested(EventHandler<? super ContextMenuEvent> value)`
  Sets the value of the `onContextMenuRequested` property.

- ## Uses of ContextMenuEvent in javafx.scene.input

  Fields in javafx.scene.input with type parameters of type ContextMenuEvent
  Modifier and Type
  Field
  Description
  `static final EventType<ContextMenuEvent>`
  ContextMenuEvent.`ANY`
  Common supertype for all context menu event types.
  `static final EventType<ContextMenuEvent>`
  ContextMenuEvent.`CONTEXT_MENU_REQUESTED`
  This event occurs when a context menu is requested.
  Methods in javafx.scene.input that return ContextMenuEvent
  Modifier and Type
  Method
  Description
  `ContextMenuEvent`
  ContextMenuEvent.`copyFor(Object newSource, EventTarget newTarget)`
  Methods in javafx.scene.input that return types with arguments of type ContextMenuEvent
  Modifier and Type
  Method
  Description
  `EventType<ContextMenuEvent>`
  ContextMenuEvent.`getEventType()`
  Constructor parameters in javafx.scene.input with type arguments of type ContextMenuEvent
  Modifier
  Constructor
  Description
  ``
  `ContextMenuEvent(Object source, EventTarget target, EventType<ContextMenuEvent> eventType, double x, double y, double screenX, double screenY, boolean keyboardTrigger, PickResult pickResult)`
  Constructs new ContextMenu event.
  ``
  `ContextMenuEvent(EventType<ContextMenuEvent> eventType, double x, double y, double screenX, double screenY, boolean keyboardTrigger, PickResult pickResult)`
  Constructs new ContextMenu event with empty source and target.