public class FXDeleteSelectedOnTypePolicy extends AbstractFXOnTypePolicy
FXDeleteSelectedOnTypePolicy is an AbstractFXOnTypePolicy
that performs content deletion upon the press of a key.| Constructor and Description |
|---|
FXDeleteSelectedOnTypePolicy() |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
isDelete(javafx.scene.input.KeyEvent event)
Returns
true if the given KeyEvent is a "delete"
event, i.e. the KeyEvent.getCode() is KeyCode.DELETE and
no drag policy is currently running. |
void |
pressed(javafx.scene.input.KeyEvent event)
This callback method is invoked when the user presses a key while the
host has keyboard focus. |
void |
released(javafx.scene.input.KeyEvent event)
This callback method is invoked when the user releases a key while the
host has keyboard focus. |
commit, disableRefreshVisuals, enableRefreshVisuals, getAdaptable, getHost, init, setAdaptableprotected boolean isDelete(javafx.scene.input.KeyEvent event)
true if the given KeyEvent is a "delete"
event, i.e. the KeyEvent.getCode() is KeyCode.DELETE and
no drag policy is currently running. Otherwise returns false
.event - The KeyEvent in question.true if the given KeyEvent should trigger
content deletion, otherwise false.public void pressed(javafx.scene.input.KeyEvent event)
AbstractFXOnTypePolicyhost has keyboard focus.pressed in class AbstractFXOnTypePolicyevent - The original KeyEvent.public void released(javafx.scene.input.KeyEvent event)
AbstractFXOnTypePolicyhost has keyboard focus.released in class AbstractFXOnTypePolicyevent - The original KeyEvent.Copyright (c) 2014 itemis AG and others. All rights reserved.