<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <!-- NewPage --> <html lang="en"> <head> <!-- Generated by javadoc (1.8.0_77) on Fri Apr 22 13:46:52 UTC 2016 --> <title>ContextMenuEvent (JavaFX 8)</title> <meta name="date" content="2016-04-22"> <link rel="stylesheet" type="text/css" href="../../../stylesheet.css" title="Style"> <script type="text/javascript" src="../../../script.js"></script> </head> <body> <script type="text/javascript"><!-- try { if (location.href.indexOf('is-external=true') == -1) { parent.document.title="ContextMenuEvent (JavaFX 8)"; } } catch(err) { } //--> var methods = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":10,"i8":10,"i9":10,"i10":10,"i11":10}; var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]}; var altColor = "altColor"; var rowColor = "rowColor"; var tableTab = "tableTab"; var activeTableTab = "activeTableTab"; </script> <noscript> <div>JavaScript is disabled on your browser.</div> </noscript> <!-- ========= START OF TOP NAVBAR ======= --> <div class="topNav"><a name="navbar.top"> <!-- --> </a> <div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div> <a name="navbar.top.firstrow"> <!-- --> </a> <ul class="navList" title="Navigation"> <li><a href="../../../overview-summary.html">Overview</a></li> <li><a href="package-summary.html">Package</a></li> <li class="navBarCell1Rev">Class</li> <li><a href="class-use/ContextMenuEvent.html">Use</a></li> <li><a href="package-tree.html">Tree</a></li> <li><a href="../../../deprecated-list.html">Deprecated</a></li> <li><a href="../../../index-all.html">Index</a></li> <li><a href="../../../help-doc.html">Help</a></li> </ul> <div class="aboutLanguage">JavaFX 8</div> </div> <div class="subNav"> <ul class="navList"> <li><a href="../../../javafx/scene/input/ClipboardContent.html" title="class in javafx.scene.input"><span class="typeNameLink">Prev Class</span></a></li> <li><a href="../../../javafx/scene/input/DataFormat.html" title="class in javafx.scene.input"><span class="typeNameLink">Next Class</span></a></li> </ul> <ul class="navList"> <li><a href="../../../index.html?javafx/scene/input/ContextMenuEvent.html" target="_top">Frames</a></li> <li><a href="ContextMenuEvent.html" target="_top">No Frames</a></li> </ul> <ul class="navList" id="allclasses_navbar_top"> <li><a href="../../../allclasses-noframe.html">All Classes</a></li> </ul> <div> <script type="text/javascript"><!-- allClassesLink = document.getElementById("allclasses_navbar_top"); if(window==top) { allClassesLink.style.display = "block"; } else { allClassesLink.style.display = "none"; } //--> </script> </div> <div> <ul class="subNavList"> <li>Summary: </li> <li>Nested | </li> <li><a href="#field.summary">Field</a> | </li> <li><a href="#constructor.summary">Constr</a> | </li> <li><a href="#method.summary">Method</a></li> </ul> <ul class="subNavList"> <li>Detail: </li> <li><a href="#field.detail">Field</a> | </li> <li><a href="#constructor.detail">Constr</a> | </li> <li><a href="#method.detail">Method</a></li> </ul> </div> <a name="skip.navbar.top"> <!-- --> </a></div> <!-- ========= END OF TOP NAVBAR ========= --> <!-- ======== START OF CLASS DATA ======== --> <div class="header"> <div class="subTitle">javafx.scene.input</div> <h2 title="Class ContextMenuEvent" class="title">Class ContextMenuEvent</h2> </div> <div class="contentContainer"> <ul class="inheritance"> <li><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li> <li> <ul class="inheritance"> <li><a href="https://docs.oracle.com/javase/8/docs/api/java/util/EventObject.html?is-external=true" title="class or interface in java.util">java.util.EventObject</a></li> <li> <ul class="inheritance"> <li><a href="../../../javafx/event/Event.html" title="class in javafx.event">javafx.event.Event</a></li> <li> <ul class="inheritance"> <li><a href="../../../javafx/scene/input/InputEvent.html" title="class in javafx.scene.input">javafx.scene.input.InputEvent</a></li> <li> <ul class="inheritance"> <li>javafx.scene.input.ContextMenuEvent</li> </ul> </li> </ul> </li> </ul> </li> </ul> </li> </ul> <div class="description"> <ul class="blockList"> <li class="blockList"> <dl> <dt>All Implemented Interfaces:</dt> <dd><a href="https://docs.oracle.com/javase/8/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Cloneable.html?is-external=true" title="class or interface in java.lang">Cloneable</a></dd> </dl> <hr> <br> <pre>public class <span class="typeNameLabel">ContextMenuEvent</span> extends <a href="../../../javafx/scene/input/InputEvent.html" title="class in javafx.scene.input">InputEvent</a></pre> <div class="block">When the user requests a context menu, this event occurs. Context menus can be triggered by the mouse or the keyboard. The exact sequence of mouse or keyboard events that is used to request a menu is platform specific. For example, on Windows, Shift+F10 requests a context menu. <p> The event coordinates contain default position for the context menu. For mouse-triggered events it is the position of the mouse cursor, for keyboard-triggered events it is a point inside of bounds of current focus owner (which is the event's target).</div> <dl> <dt><span class="simpleTagLabel">Since:</span></dt> <dd>JavaFX 2.1</dd> <dt><span class="seeLabel">See Also:</span></dt> <dd><a href="../../../serialized-form.html#javafx.scene.input.ContextMenuEvent">Serialized Form</a></dd> </dl> </li> </ul> </div> <div class="summary"> <ul class="blockList"> <li class="blockList"> <!-- =========== FIELD SUMMARY =========== --> <ul class="blockList"> <li class="blockList"><a name="field.summary"> <!-- --> </a> <h3>Field Summary</h3> <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation"> <caption><span>Fields</span><span class="tabEnd"> </span></caption> <tr> <th class="colFirst" scope="col">Modifier and Type</th> <th class="colLast" scope="col">Field and Description</th> </tr> <tr class="altColor"> <td class="colFirst"><code>static <a href="../../../javafx/event/EventType.html" title="class in javafx.event">EventType</a><<a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input">ContextMenuEvent</a>></code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#ANY">ANY</a></span></code> <div class="block">Common supertype for all context menu event types.</div> </td> </tr> <tr class="rowColor"> <td class="colFirst"><code>static <a href="../../../javafx/event/EventType.html" title="class in javafx.event">EventType</a><<a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input">ContextMenuEvent</a>></code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#CONTEXT_MENU_REQUESTED">CONTEXT_MENU_REQUESTED</a></span></code> <div class="block">This event occurs when a context menu is requested.</div> </td> </tr> </table> <ul class="blockList"> <li class="blockList"><a name="fields.inherited.from.class.javafx.event.Event"> <!-- --> </a> <h3>Fields inherited from class javafx.event.<a href="../../../javafx/event/Event.html" title="class in javafx.event">Event</a></h3> <code><a href="../../../javafx/event/Event.html#consumed">consumed</a>, <a href="../../../javafx/event/Event.html#eventType">eventType</a>, <a href="../../../javafx/event/Event.html#NULL_SOURCE_TARGET">NULL_SOURCE_TARGET</a>, <a href="../../../javafx/event/Event.html#target">target</a></code></li> </ul> <ul class="blockList"> <li class="blockList"><a name="fields.inherited.from.class.java.util.EventObject"> <!-- --> </a> <h3>Fields inherited from class java.util.<a href="https://docs.oracle.com/javase/8/docs/api/java/util/EventObject.html?is-external=true" title="class or interface in java.util">EventObject</a></h3> <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/EventObject.html?is-external=true#source" title="class or interface in java.util">source</a></code></li> </ul> </li> </ul> <!-- ======== CONSTRUCTOR SUMMARY ======== --> <ul class="blockList"> <li class="blockList"><a name="constructor.summary"> <!-- --> </a> <h3>Constructor Summary</h3> <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation"> <caption><span>Constructors</span><span class="tabEnd"> </span></caption> <tr> <th class="colOne" scope="col">Constructor and Description</th> </tr> <tr class="altColor"> <td class="colOne"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#ContextMenuEvent-javafx.event.EventType-double-double-double-double-boolean-javafx.scene.input.PickResult-">ContextMenuEvent</a></span>(<a href="../../../javafx/event/EventType.html" title="class in javafx.event">EventType</a><<a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input">ContextMenuEvent</a>> eventType, double x, double y, double screenX, double screenY, boolean keyboardTrigger, <a href="../../../javafx/scene/input/PickResult.html" title="class in javafx.scene.input">PickResult</a> pickResult)</code> <div class="block">Constructs new ContextMenu event with empty source and target.</div> </td> </tr> <tr class="rowColor"> <td class="colOne"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#ContextMenuEvent-java.lang.Object-javafx.event.EventTarget-javafx.event.EventType-double-double-double-double-boolean-javafx.scene.input.PickResult-">ContextMenuEvent</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> source, <a href="../../../javafx/event/EventTarget.html" title="interface in javafx.event">EventTarget</a> target, <a href="../../../javafx/event/EventType.html" title="class in javafx.event">EventType</a><<a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input">ContextMenuEvent</a>> eventType, double x, double y, double screenX, double screenY, boolean keyboardTrigger, <a href="../../../javafx/scene/input/PickResult.html" title="class in javafx.scene.input">PickResult</a> pickResult)</code> <div class="block">Constructs new ContextMenu event.</div> </td> </tr> </table> </li> </ul> <!-- ========== METHOD SUMMARY =========== --> <ul class="blockList"> <li class="blockList"><a name="method.summary"> <!-- --> </a> <h3>Method Summary</h3> <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> <caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd"> </span></span></caption> <tr> <th class="colFirst" scope="col">Modifier and Type</th> <th class="colLast" scope="col">Method and Description</th> </tr> <tr id="i0" class="altColor"> <td class="colFirst"><code><a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input">ContextMenuEvent</a></code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#copyFor-java.lang.Object-javafx.event.EventTarget-">copyFor</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> newSource, <a href="../../../javafx/event/EventTarget.html" title="interface in javafx.event">EventTarget</a> newTarget)</code> <div class="block">Creates and returns a copy of this event with the specified event source and target.</div> </td> </tr> <tr id="i1" class="rowColor"> <td class="colFirst"><code><a href="../../../javafx/event/EventType.html" title="class in javafx.event">EventType</a><<a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input">ContextMenuEvent</a>></code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#getEventType--">getEventType</a></span>()</code> <div class="block">Gets the event type of this event.</div> </td> </tr> <tr id="i2" class="altColor"> <td class="colFirst"><code><a href="../../../javafx/scene/input/PickResult.html" title="class in javafx.scene.input">PickResult</a></code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#getPickResult--">getPickResult</a></span>()</code> <div class="block">Returns information about the pick.</div> </td> </tr> <tr id="i3" class="rowColor"> <td class="colFirst"><code>double</code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#getSceneX--">getSceneX</a></span>()</code> <div class="block">Returns horizontal position of the event relative to the origin of the <code>Scene</code> that contains the ContextMenuEvent's source.</div> </td> </tr> <tr id="i4" class="altColor"> <td class="colFirst"><code>double</code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#getSceneY--">getSceneY</a></span>()</code> <div class="block">Returns vertical position of the event relative to the origin of the <code>Scene</code> that contains the ContextMenuEvent's source.</div> </td> </tr> <tr id="i5" class="rowColor"> <td class="colFirst"><code>double</code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#getScreenX--">getScreenX</a></span>()</code> <div class="block">Returns absolute horizontal position of the event.</div> </td> </tr> <tr id="i6" class="altColor"> <td class="colFirst"><code>double</code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#getScreenY--">getScreenY</a></span>()</code> <div class="block">Returns absolute vertical position of the event.</div> </td> </tr> <tr id="i7" class="rowColor"> <td class="colFirst"><code>double</code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#getX--">getX</a></span>()</code> <div class="block">Horizontal position of the event relative to the origin of the ContextMenuEvent's source.</div> </td> </tr> <tr id="i8" class="altColor"> <td class="colFirst"><code>double</code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#getY--">getY</a></span>()</code> <div class="block">Vertical position of the event relative to the origin of the ContextMenuEvent's source.</div> </td> </tr> <tr id="i9" class="rowColor"> <td class="colFirst"><code>double</code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#getZ--">getZ</a></span>()</code> <div class="block">Depth position of the event relative to the origin of the MouseEvent's source.</div> </td> </tr> <tr id="i10" class="altColor"> <td class="colFirst"><code>boolean</code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#isKeyboardTrigger--">isKeyboardTrigger</a></span>()</code> <div class="block">Determines whether this event originated from the keyboard.</div> </td> </tr> <tr id="i11" class="rowColor"> <td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td> <td class="colLast"><code><span class="memberNameLink"><a href="../../../javafx/scene/input/ContextMenuEvent.html#toString--">toString</a></span>()</code> <div class="block">Returns a string representation of this <code>ContextMenuEvent</code> object.</div> </td> </tr> </table> <ul class="blockList"> <li class="blockList"><a name="methods.inherited.from.class.javafx.event.Event"> <!-- --> </a> <h3>Methods inherited from class javafx.event.<a href="../../../javafx/event/Event.html" title="class in javafx.event">Event</a></h3> <code><a href="../../../javafx/event/Event.html#clone--">clone</a>, <a href="../../../javafx/event/Event.html#consume--">consume</a>, <a href="../../../javafx/event/Event.html#fireEvent-javafx.event.EventTarget-javafx.event.Event-">fireEvent</a>, <a href="../../../javafx/event/Event.html#getTarget--">getTarget</a>, <a href="../../../javafx/event/Event.html#isConsumed--">isConsumed</a></code></li> </ul> <ul class="blockList"> <li class="blockList"><a name="methods.inherited.from.class.java.util.EventObject"> <!-- --> </a> <h3>Methods inherited from class java.util.<a href="https://docs.oracle.com/javase/8/docs/api/java/util/EventObject.html?is-external=true" title="class or interface in java.util">EventObject</a></h3> <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/EventObject.html?is-external=true#getSource--" title="class or interface in java.util">getSource</a></code></li> </ul> <ul class="blockList"> <li class="blockList"><a name="methods.inherited.from.class.java.lang.Object"> <!-- --> </a> <h3>Methods inherited from class java.lang.<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3> <code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#equals-java.lang.Object-" title="class or interface in java.lang">equals</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#finalize--" title="class or interface in java.lang">finalize</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#getClass--" title="class or interface in java.lang">getClass</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#hashCode--" title="class or interface in java.lang">hashCode</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#notify--" title="class or interface in java.lang">notify</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#notifyAll--" title="class or interface in java.lang">notifyAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait--" title="class or interface in java.lang">wait</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait-long-" title="class or interface in java.lang">wait</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait-long-int-" title="class or interface in java.lang">wait</a></code></li> </ul> </li> </ul> </li> </ul> </div> <div class="details"> <ul class="blockList"> <li class="blockList"> <!-- ============ FIELD DETAIL =========== --> <ul class="blockList"> <li class="blockList"><a name="field.detail"> <!-- --> </a> <h3>Field Detail</h3> <a name="CONTEXT_MENU_REQUESTED"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>CONTEXT_MENU_REQUESTED</h4> <pre>public static final <a href="../../../javafx/event/EventType.html" title="class in javafx.event">EventType</a><<a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input">ContextMenuEvent</a>> CONTEXT_MENU_REQUESTED</pre> <div class="block">This event occurs when a context menu is requested.</div> </li> </ul> <a name="ANY"> <!-- --> </a> <ul class="blockListLast"> <li class="blockList"> <h4>ANY</h4> <pre>public static final <a href="../../../javafx/event/EventType.html" title="class in javafx.event">EventType</a><<a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input">ContextMenuEvent</a>> ANY</pre> <div class="block">Common supertype for all context menu event types.</div> <dl> <dt><span class="simpleTagLabel">Since:</span></dt> <dd>JavaFX 8.0</dd> </dl> </li> </ul> </li> </ul> <!-- ========= CONSTRUCTOR DETAIL ======== --> <ul class="blockList"> <li class="blockList"><a name="constructor.detail"> <!-- --> </a> <h3>Constructor Detail</h3> <a name="ContextMenuEvent-java.lang.Object-javafx.event.EventTarget-javafx.event.EventType-double-double-double-double-boolean-javafx.scene.input.PickResult-"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>ContextMenuEvent</h4> <pre>public ContextMenuEvent(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> source, <a href="../../../javafx/event/EventTarget.html" title="interface in javafx.event">EventTarget</a> target, <a href="../../../javafx/event/EventType.html" title="class in javafx.event">EventType</a><<a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input">ContextMenuEvent</a>> eventType, double x, double y, double screenX, double screenY, boolean keyboardTrigger, <a href="../../../javafx/scene/input/PickResult.html" title="class in javafx.scene.input">PickResult</a> pickResult)</pre> <div class="block">Constructs new ContextMenu event.</div> <dl> <dt><span class="paramLabel">Parameters:</span></dt> <dd><code>source</code> - the source of the event. Can be null.</dd> <dd><code>target</code> - the target of the event. Can be null.</dd> <dd><code>eventType</code> - The type of the event.</dd> <dd><code>x</code> - The x with respect to the scene</dd> <dd><code>y</code> - The y with respect to the scene</dd> <dd><code>screenX</code> - The x coordinate relative to screen.</dd> <dd><code>screenY</code> - The y coordinate relative to screen.</dd> <dd><code>keyboardTrigger</code> - true if this event was triggered by keyboard.</dd> <dd><code>pickResult</code> - pick result. Can be null, in this case a 2D pick result without any further values is constructed based on the scene coordinates and the target</dd> <dt><span class="simpleTagLabel">Since:</span></dt> <dd>JavaFX 8.0</dd> </dl> </li> </ul> <a name="ContextMenuEvent-javafx.event.EventType-double-double-double-double-boolean-javafx.scene.input.PickResult-"> <!-- --> </a> <ul class="blockListLast"> <li class="blockList"> <h4>ContextMenuEvent</h4> <pre>public ContextMenuEvent(<a href="../../../javafx/event/EventType.html" title="class in javafx.event">EventType</a><<a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input">ContextMenuEvent</a>> eventType, double x, double y, double screenX, double screenY, boolean keyboardTrigger, <a href="../../../javafx/scene/input/PickResult.html" title="class in javafx.scene.input">PickResult</a> pickResult)</pre> <div class="block">Constructs new ContextMenu event with empty source and target.</div> <dl> <dt><span class="paramLabel">Parameters:</span></dt> <dd><code>eventType</code> - The type of the event.</dd> <dd><code>x</code> - The x with respect to the scene.</dd> <dd><code>y</code> - The y with respect to the scene.</dd> <dd><code>screenX</code> - The x coordinate relative to screen.</dd> <dd><code>screenY</code> - The y coordinate relative to screen.</dd> <dd><code>keyboardTrigger</code> - true if this event was triggered by keyboard.</dd> <dd><code>pickResult</code> - pick result. Can be null, in this case a 2D pick result without any further values is constructed based on the scene coordinates</dd> <dt><span class="simpleTagLabel">Since:</span></dt> <dd>JavaFX 8.0</dd> </dl> </li> </ul> </li> </ul> <!-- ============ METHOD DETAIL ========== --> <ul class="blockList"> <li class="blockList"><a name="method.detail"> <!-- --> </a> <h3>Method Detail</h3> <a name="copyFor-java.lang.Object-javafx.event.EventTarget-"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>copyFor</h4> <pre>public <a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input">ContextMenuEvent</a> copyFor(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> newSource, <a href="../../../javafx/event/EventTarget.html" title="interface in javafx.event">EventTarget</a> newTarget)</pre> <div class="block"><span class="descfrmTypeLabel">Description copied from class: <code><a href="../../../javafx/event/Event.html#copyFor-java.lang.Object-javafx.event.EventTarget-">Event</a></code></span></div> <div class="block">Creates and returns a copy of this event with the specified event source and target. If the source or target is set to <code>null</code>, it is replaced by the <code>NULL_SOURCE_TARGET</code> value.</div> <dl> <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> <dd><code><a href="../../../javafx/event/Event.html#copyFor-java.lang.Object-javafx.event.EventTarget-">copyFor</a></code> in class <code><a href="../../../javafx/event/Event.html" title="class in javafx.event">Event</a></code></dd> <dt><span class="paramLabel">Parameters:</span></dt> <dd><code>newSource</code> - the new source of the copied event</dd> <dd><code>newTarget</code> - the new target of the copied event</dd> <dt><span class="returnLabel">Returns:</span></dt> <dd>the event copy with the new source and target</dd> </dl> </li> </ul> <a name="getEventType--"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>getEventType</h4> <pre>public <a href="../../../javafx/event/EventType.html" title="class in javafx.event">EventType</a><<a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input">ContextMenuEvent</a>> getEventType()</pre> <div class="block"><span class="descfrmTypeLabel">Description copied from class: <code><a href="../../../javafx/event/Event.html#getEventType--">Event</a></code></span></div> <div class="block">Gets the event type of this event. Objects of the same <code>Event</code> class can have different event types. These event types further specify what kind of event occurred.</div> <dl> <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> <dd><code><a href="../../../javafx/scene/input/InputEvent.html#getEventType--">getEventType</a></code> in class <code><a href="../../../javafx/scene/input/InputEvent.html" title="class in javafx.scene.input">InputEvent</a></code></dd> <dt><span class="returnLabel">Returns:</span></dt> <dd>the event type</dd> </dl> </li> </ul> <a name="isKeyboardTrigger--"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>isKeyboardTrigger</h4> <pre>public boolean isKeyboardTrigger()</pre> <div class="block">Determines whether this event originated from the keyboard.</div> <dl> <dt><span class="returnLabel">Returns:</span></dt> <dd>true if the event was caused by the keyboard</dd> </dl> </li> </ul> <a name="getX--"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>getX</h4> <pre>public final double getX()</pre> <div class="block">Horizontal position of the event relative to the origin of the ContextMenuEvent's source. For more information about this event's coordinate semantics please see the general description of <a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input"><code>ContextMenuEvent</code></a>.</div> <dl> <dt><span class="returnLabel">Returns:</span></dt> <dd>horizontal position of the event relative to the origin of the ContextMenuEvent's source.</dd> </dl> </li> </ul> <a name="getY--"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>getY</h4> <pre>public final double getY()</pre> <div class="block">Vertical position of the event relative to the origin of the ContextMenuEvent's source. For more information about this event's coordinate semantics please see the general description of <a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input"><code>ContextMenuEvent</code></a>.</div> <dl> <dt><span class="returnLabel">Returns:</span></dt> <dd>vertical position of the event relative to the origin of the ContextMenuEvent's source.</dd> </dl> </li> </ul> <a name="getZ--"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>getZ</h4> <pre>public final double getZ()</pre> <div class="block">Depth position of the event relative to the origin of the MouseEvent's source.</div> <dl> <dt><span class="returnLabel">Returns:</span></dt> <dd>depth position of the event relative to the origin of the MouseEvent's source.</dd> <dt><span class="simpleTagLabel">Since:</span></dt> <dd>JavaFX 8.0</dd> </dl> </li> </ul> <a name="getScreenX--"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>getScreenX</h4> <pre>public final double getScreenX()</pre> <div class="block">Returns absolute horizontal position of the event. For more information about this event's coordinate semantics please see the general description of <a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input"><code>ContextMenuEvent</code></a>.</div> <dl> <dt><span class="returnLabel">Returns:</span></dt> <dd>absolute horizontal position of the event</dd> </dl> </li> </ul> <a name="getScreenY--"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>getScreenY</h4> <pre>public final double getScreenY()</pre> <div class="block">Returns absolute vertical position of the event. For more information about this event's coordinate semantics please see the general description of <a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input"><code>ContextMenuEvent</code></a>.</div> <dl> <dt><span class="returnLabel">Returns:</span></dt> <dd>absolute vertical position of the event</dd> </dl> </li> </ul> <a name="getSceneX--"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>getSceneX</h4> <pre>public final double getSceneX()</pre> <div class="block">Returns horizontal position of the event relative to the origin of the <code>Scene</code> that contains the ContextMenuEvent's source. If the node is not in a <code>Scene</code>, then the value is relative to the boundsInParent of the root-most parent of the ContextMenuEvent's node. For more information about this event's coordinate semantics please see the general description of <a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input"><code>ContextMenuEvent</code></a>. Note that in 3D scene, this represents the flat coordinates after applying the projection transformations.</div> <dl> <dt><span class="returnLabel">Returns:</span></dt> <dd>horizontal position of the event relative to the origin of the <code>Scene</code> that contains the ContextMenuEvent's source</dd> </dl> </li> </ul> <a name="getSceneY--"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>getSceneY</h4> <pre>public final double getSceneY()</pre> <div class="block">Returns vertical position of the event relative to the origin of the <code>Scene</code> that contains the ContextMenuEvent's source. If the node is not in a <code>Scene</code>, then the value is relative to the boundsInParent of the root-most parent of the ContextMenuEvent's node. For more information about this event's coordinate semantics please see the general description of <a href="../../../javafx/scene/input/ContextMenuEvent.html" title="class in javafx.scene.input"><code>ContextMenuEvent</code></a>. Note that in 3D scene, this represents the flat coordinates after applying the projection transformations.</div> <dl> <dt><span class="returnLabel">Returns:</span></dt> <dd>vertical position of the event relative to the origin of the <code>Scene</code> that contains the ContextMenuEvent's source</dd> </dl> </li> </ul> <a name="getPickResult--"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>getPickResult</h4> <pre>public final <a href="../../../javafx/scene/input/PickResult.html" title="class in javafx.scene.input">PickResult</a> getPickResult()</pre> <div class="block">Returns information about the pick.</div> <dl> <dt><span class="returnLabel">Returns:</span></dt> <dd>new PickResult object that contains information about the pick</dd> <dt><span class="simpleTagLabel">Since:</span></dt> <dd>JavaFX 8.0</dd> </dl> </li> </ul> <a name="toString--"> <!-- --> </a> <ul class="blockListLast"> <li class="blockList"> <h4>toString</h4> <pre>public <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> toString()</pre> <div class="block">Returns a string representation of this <code>ContextMenuEvent</code> object.</div> <dl> <dt><span class="overrideSpecifyLabel">Overrides:</span></dt> <dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/EventObject.html?is-external=true#toString--" title="class or interface in java.util">toString</a></code> in class <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/EventObject.html?is-external=true" title="class or interface in java.util">EventObject</a></code></dd> <dt><span class="returnLabel">Returns:</span></dt> <dd>a string representation of this <code>ContextMenuEvent</code> object.</dd> </dl> </li> </ul> </li> </ul> </li> </ul> </div> </div> <!-- ========= END OF CLASS DATA ========= --> <!-- ======= START OF BOTTOM NAVBAR ====== --> <div class="bottomNav"><a name="navbar.bottom"> <!-- --> </a> <div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div> <a name="navbar.bottom.firstrow"> <!-- --> </a> <ul class="navList" title="Navigation"> <li><a href="../../../overview-summary.html">Overview</a></li> <li><a href="package-summary.html">Package</a></li> <li class="navBarCell1Rev">Class</li> <li><a href="class-use/ContextMenuEvent.html">Use</a></li> <li><a href="package-tree.html">Tree</a></li> <li><a href="../../../deprecated-list.html">Deprecated</a></li> <li><a href="../../../index-all.html">Index</a></li> <li><a href="../../../help-doc.html">Help</a></li> </ul> <div class="aboutLanguage">JavaFX 8</div> </div> <div class="subNav"> <ul class="navList"> <li><a href="../../../javafx/scene/input/ClipboardContent.html" title="class in javafx.scene.input"><span class="typeNameLink">Prev Class</span></a></li> <li><a href="../../../javafx/scene/input/DataFormat.html" title="class in javafx.scene.input"><span class="typeNameLink">Next Class</span></a></li> </ul> <ul class="navList"> <li><a href="../../../index.html?javafx/scene/input/ContextMenuEvent.html" target="_top">Frames</a></li> <li><a href="ContextMenuEvent.html" target="_top">No Frames</a></li> </ul> <ul class="navList" id="allclasses_navbar_bottom"> <li><a href="../../../allclasses-noframe.html">All Classes</a></li> </ul> <div> <script type="text/javascript"><!-- allClassesLink = document.getElementById("allclasses_navbar_bottom"); if(window==top) { allClassesLink.style.display = "block"; } else { allClassesLink.style.display = "none"; } //--> </script> </div> <div> <ul class="subNavList"> <li>Summary: </li> <li>Nested | </li> <li><a href="#field.summary">Field</a> | </li> <li><a href="#constructor.summary">Constr</a> | </li> <li><a href="#method.summary">Method</a></li> </ul> <ul class="subNavList"> <li>Detail: </li> <li><a href="#field.detail">Field</a> | </li> <li><a href="#constructor.detail">Constr</a> | </li> <li><a href="#method.detail">Method</a></li> </ul> </div> <a name="skip.navbar.bottom"> <!-- --> </a></div> <!-- ======== END OF BOTTOM NAVBAR ======= --> <p class="legalCopy"><small><small><a href="https://docs.oracle.com/javase/8/docs/legal/cpyr.html">Copyright</a> (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved.</small></small></p> </body> </html>