本文整理了Java中javafx.scene.input.MouseEvent.isStillSincePress()
方法的一些代码示例,展示了MouseEvent.isStillSincePress()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。MouseEvent.isStillSincePress()
方法的具体详情如下:
包路径:javafx.scene.input.MouseEvent
类名称:MouseEvent
方法名:isStillSincePress
暂无
代码示例来源:origin: jfoenixadmin/JFoenix
if (primaryStage.isFullScreen() || mouseEvent.isStillSincePress() || primaryStage.isMaximized() || maximized) {
return;
代码示例来源:origin: jfoenixadmin/JFoenix
if (tab.isDisable() || !event.isStillSincePress()) {
return;
代码示例来源:origin: us.ihmc/ihmc-path-planning-visualizers
@Override
public void handle(MouseEvent event)
{
if (event.getButton() != MouseButton.PRIMARY)
return;
if (event.isStillSincePress() && event.getEventType() == MouseEvent.MOUSE_CLICKED)
positionValidated.set(true);
}
};
代码示例来源:origin: at.bestsolution.efxclipse.rt/org.eclipse.fx.ui.controls
public TextHoverEvent(MouseEvent source, List<HoverTarget> hoverTargets) {
super(HOVER, source.getSceneX(), source.getSceneY(), source.getScreenX(), source.getScreenY(), source.getButton(), source.getClickCount(), source.isShiftDown(), source.isControlDown(), source.isAltDown(), source.isMetaDown(), source.isPrimaryButtonDown(), source.isMiddleButtonDown(),
source.isSecondaryButtonDown(), source.isSynthesized(), source.isPopupTrigger(), source.isStillSincePress(), source.getPickResult());
this.hoverTargets = Collections.unmodifiableList(hoverTargets);
Optional<Range<Integer>> range = this.hoverTargets.stream().map(t->t.textRange).findFirst();
// TODO remove me
this.tokenText = null;
this.offsetTokenStart = range.isPresent() ? range.get().lowerEndpoint() : 0;;
this.offsetTokenEnd = range.isPresent() ? range.get().upperEndpoint() : 0;;
this.offset = range.isPresent() ? range.get().lowerEndpoint() : 0;
}
代码示例来源:origin: us.ihmc/ihmc-javafx-toolkit
@Override
public void handle(MouseEvent event)
{
if (event.getButton() != MouseButton.PRIMARY)
return;
if (condition.test(event) && event.isStillSincePress() && event.getEventType() == MouseEvent.MOUSE_CLICKED)
{
PickResult pickResult = event.getPickResult();
Node intersectedNode = pickResult.getIntersectedNode();
if (intersectedNode == null || intersectedNode instanceof SubScene)
return;
javafx.geometry.Point3D localPoint = pickResult.getIntersectedPoint();
javafx.geometry.Point3D scenePoint = intersectedNode.getLocalToSceneTransform().transform(localPoint);
focusPointTranslation.setX(scenePoint.getX());
focusPointTranslation.setY(scenePoint.getY());
focusPointTranslation.setZ(scenePoint.getZ());
}
}
};
代码示例来源:origin: us.ihmc/IHMCJavaFXToolkit
@Override
public void handle(MouseEvent event)
{
if (event.getButton() != MouseButton.PRIMARY)
return;
if (condition.test(event) && event.isStillSincePress() && event.getEventType() == MouseEvent.MOUSE_CLICKED)
{
PickResult pickResult = event.getPickResult();
Node intersectedNode = pickResult.getIntersectedNode();
if (intersectedNode == null || intersectedNode instanceof SubScene)
return;
Point3D localPoint = pickResult.getIntersectedPoint();
Point3D scenePoint = intersectedNode.getLocalToSceneTransform().transform(localPoint);
focusPointTranslation.setX(scenePoint.getX());
focusPointTranslation.setY(scenePoint.getY());
focusPointTranslation.setZ(scenePoint.getZ());
}
}
};
代码示例来源:origin: com.jfoenix/jfoenix
if (primaryStage.isFullScreen() || mouseEvent.isStillSincePress() || primaryStage.isMaximized() || maximized) {
return;
代码示例来源:origin: us.ihmc/ihmc-footstep-planning-visualizers
public StartGoalOrientationEditor(Messager messager, SubScene subScene)
{
this.messager = messager;
this.subScene = subScene;
startEditModeEnabled = messager.createInput(FootstepPlannerMessagerAPI.StartOrientationEditModeEnabledTopic, false);
goalEditModeEnabled = messager.createInput(FootstepPlannerMessagerAPI.GoalOrientationEditModeEnabledTopic, false);
startPositionReference = messager.createInput(FootstepPlannerMessagerAPI.StartPositionTopic);
goalPositionReference = messager.createInput(FootstepPlannerMessagerAPI.GoalPositionTopic);
rayCastInterceptor = (event) ->
{
PickResult pickResult = event.getPickResult();
Node intersectedNode = pickResult.getIntersectedNode();
if (intersectedNode == null || intersectedNode instanceof SubScene)
return;
javafx.geometry.Point3D localPoint = pickResult.getIntersectedPoint();
javafx.geometry.Point3D scenePoint = intersectedNode.getLocalToSceneTransform().transform(localPoint);
Point3D interception = new Point3D();
interception.setX(scenePoint.getX());
interception.setY(scenePoint.getY());
interception.setZ(scenePoint.getZ());
latestInterception.set(interception);
};
leftClickInterceptor = (event) ->
{
if (event.getButton() != MouseButton.PRIMARY)
return;
if (event.isStillSincePress() && event.getEventType() == MouseEvent.MOUSE_CLICKED)
orientationValidated.set(true);
};
}
代码示例来源:origin: at.bestsolution.efxclipse.rt/org.eclipse.fx.ui.controls
/**
* Create a new text position event
*
* @param event
* the source mouse event
* @param offset
* the offset in the text (might be -1 to indicate no valid
* region was found)
*/
public TextPositionEvent(MouseEvent event, int offset) {
super(convert(event.getEventType()), event.getSceneX(), event.getSceneY(), event.getScreenX(), event.getScreenY(), event.getButton(), event.getClickCount(), event.isShiftDown(), event.isControlDown(), event.isAltDown(), event.isMetaDown(), event.isPrimaryButtonDown(), event.isMiddleButtonDown(),
event.isSecondaryButtonDown(), event.isSynthesized(), event.isPopupTrigger(), event.isStillSincePress(), event.getPickResult());
this.offset = offset;
}
代码示例来源:origin: at.bestsolution.efxclipse.rt/org.eclipse.fx.ui.controls
/**
* Create a new hover event from the original mouse event
*
* @param event
* the event
* @param offsetTokenStart
* the start offset from the token hovering (might be -1 to
* indicate no valid region was found)
* @param offsetTokenEnd
* the end offset from the token hovering (might be -1 to
* indicate no valid region was found)
* @param offset
* the offset in the text (might be -1 to indicate no valid
* region was found)
* @param tokenText
* the token text
*/
public TextHoverEvent(MouseEvent event, int offsetTokenStart, int offsetTokenEnd, int offset, String tokenText) {
super(HOVER, event.getSceneX(), event.getSceneY(), event.getScreenX(), event.getScreenY(), event.getButton(), event.getClickCount(), event.isShiftDown(), event.isControlDown(), event.isAltDown(), event.isMetaDown(), event.isPrimaryButtonDown(), event.isMiddleButtonDown(),
event.isSecondaryButtonDown(), event.isSynthesized(), event.isPopupTrigger(), event.isStillSincePress(), event.getPickResult());
this.offsetTokenStart = offsetTokenStart;
this.offsetTokenEnd = offsetTokenEnd;
this.tokenText = tokenText;
this.offset = offset;
this.hoverTargets = null;
}
代码示例来源:origin: us.ihmc/ihmc-javafx-toolkit
if (event.isStillSincePress())
return;
代码示例来源:origin: us.ihmc/IHMCJavaFXToolkit
if (event.isStillSincePress())
return;
代码示例来源:origin: com.nexitia.emaginplatform/emagin-jfxcore-engine
if (mouseEvent.isStillSincePress()) {
return;
代码示例来源:origin: com.nexitia.emaginplatform/emagin-jfxcore-engine
if (mouseEvent.isStillSincePress()) {
return;
代码示例来源:origin: com.jfoenix/jfoenix
if (tab.isDisable() || !event.isStillSincePress()) {
return;
内容来源于网络,如有侵权,请联系作者删除!