java.lang.Object
com.iamsoft.util.ui.javafx.WindowUtil
-
Property Summary
PropertiesTypePropertyDescriptionstatic javafx.beans.property.ReadOnlyBooleanProperty
Creates a read-only property, which can be used to determine whether Alt key is down.static javafx.beans.property.ReadOnlyBooleanProperty
Creates a read-only property, which can be used to determine whether Shift key is down. -
Method Summary
Modifier and TypeMethodDescriptionstatic javafx.beans.property.ReadOnlyBooleanProperty
Creates a read-only property, which can be used to determine whether Alt key is down.static javafx.beans.property.ReadOnlyProperty
<javafx.stage.Window> createCurrentWindowProperty
(javafx.scene.Node pNode) Creates a read-only property providing the current window of the specified node.static javafx.beans.property.ReadOnlyBooleanProperty
createKeyStateProperty
(Predicate<javafx.scene.input.KeyEvent> pPredicate) static javafx.collections.ObservableList
<javafx.beans.property.ReadOnlyProperty<javafx.scene.Parent>> createParentPathObservableList
(javafx.scene.Node pNode) static javafx.beans.property.ReadOnlyBooleanProperty
Creates a read-only property, which can be used to determine whether Shift key is down.static javafx.beans.property.ReadOnlyProperty
<Boolean> createVisibleOnSceneNodeProperty
(javafx.beans.value.ObservableValue<? extends javafx.scene.Node> pNode) static javafx.beans.property.ReadOnlyProperty
<Boolean> createVisibleOnSceneNodeProperty
(javafx.scene.Node pNode) Creates a property which determines whether the specified node is visible on the scene.static javafx.beans.property.ReadOnlyProperty
<Boolean> createWindowShowingProperty
(javafx.scene.Node pNode) Creates a read-only property providing the 'showing' state of the current window of the specified node.static void
Runs the specified runnable on the JavaFX thread after the specified time in milliseconds is elapsed.static void
fixDialogSizingBug
(javafx.scene.control.Dialog<?> pDialog) A workaround for a Linux specific sizing bug, which occurs when a dialog instance is reused for showing a dialog more than once - the dialog pane height is shrunk to zero.static javafx.stage.Window
getWindow
(javafx.event.ActionEvent pActionEvent) static <T> Optional
<T> showAndWait
(javafx.scene.control.Dialog<T> pDialog, javafx.scene.control.MenuBar pMenuBar) Used to prevent access to system menu on Mac OS when modal dialog is shown.static void
showTooltip
(javafx.scene.control.Control pControl, int pDelay, int pShowingDuration) Shows the tooltip of the specified component for the specified duration, after the specified delay.static void
showTooltip
(javafx.scene.control.Control pControl, int pDelay, int pShowingDuration, javafx.geometry.Pos pPosition) Shows the tooltip of the specified component for the specified duration, after the specified delay.
-
Property Details
-
createShiftDown
public static javafx.beans.property.ReadOnlyBooleanProperty createShiftDownPropertyCreates a read-only property, which can be used to determine whether Shift key is down.- See Also:
-
createAltDown
public static javafx.beans.property.ReadOnlyBooleanProperty createAltDownPropertyCreates a read-only property, which can be used to determine whether Alt key is down.- See Also:
-
-
Method Details
-
getWindow
public static javafx.stage.Window getWindow(javafx.event.ActionEvent pActionEvent) -
fixDialogSizingBug
public static void fixDialogSizingBug(javafx.scene.control.Dialog<?> pDialog) A workaround for a Linux specific sizing bug, which occurs when a dialog instance is reused for showing a dialog more than once - the dialog pane height is shrunk to zero. See bugs 517 and 518. -
createCurrentWindowProperty
public static javafx.beans.property.ReadOnlyProperty<javafx.stage.Window> createCurrentWindowProperty(javafx.scene.Node pNode) Creates a read-only property providing the current window of the specified node. -
createWindowShowingProperty
public static javafx.beans.property.ReadOnlyProperty<Boolean> createWindowShowingProperty(javafx.scene.Node pNode) Creates a read-only property providing the 'showing' state of the current window of the specified node. -
createVisibleOnSceneNodeProperty
public static javafx.beans.property.ReadOnlyProperty<Boolean> createVisibleOnSceneNodeProperty(javafx.beans.value.ObservableValue<? extends javafx.scene.Node> pNode) -
createVisibleOnSceneNodeProperty
public static javafx.beans.property.ReadOnlyProperty<Boolean> createVisibleOnSceneNodeProperty(javafx.scene.Node pNode) Creates a property which determines whether the specified node is visible on the scene. A node is considered to be visible on the scene if the node and all parents are visible and the scene is non-null. -
createParentPathObservableList
public static javafx.collections.ObservableList<javafx.beans.property.ReadOnlyProperty<javafx.scene.Parent>> createParentPathObservableList(javafx.scene.Node pNode) -
showAndWait
public static <T> Optional<T> showAndWait(javafx.scene.control.Dialog<T> pDialog, javafx.scene.control.MenuBar pMenuBar) Used to prevent access to system menu on Mac OS when modal dialog is shown. -
showTooltip
public static void showTooltip(javafx.scene.control.Control pControl, int pDelay, int pShowingDuration) Shows the tooltip of the specified component for the specified duration, after the specified delay. If the tooltip of the specified component is changed before it is shown, nothing happens.- Parameters:
pDelay
- Delay in milliseconds before showing the tooltip.pShowingDuration
- Duration in milliseconds for which the tooltip will be visible.
-
showTooltip
public static void showTooltip(javafx.scene.control.Control pControl, int pDelay, int pShowingDuration, javafx.geometry.Pos pPosition) Shows the tooltip of the specified component for the specified duration, after the specified delay. If the tooltip of the specified component is changed before it is shown, nothing happens.- Parameters:
pDelay
- Delay in milliseconds before showing the tooltip.pShowingDuration
- Duration in milliseconds for which the tooltip will be visible.
-
delay
Runs the specified runnable on the JavaFX thread after the specified time in milliseconds is elapsed. -
createShiftDownProperty
public static javafx.beans.property.ReadOnlyBooleanProperty createShiftDownProperty()Creates a read-only property, which can be used to determine whether Shift key is down.- Returns:
- the
createShiftDown
property
-
createAltDownProperty
public static javafx.beans.property.ReadOnlyBooleanProperty createAltDownProperty()Creates a read-only property, which can be used to determine whether Alt key is down.- Returns:
- the
createAltDown
property
-
createKeyStateProperty
public static javafx.beans.property.ReadOnlyBooleanProperty createKeyStateProperty(Predicate<javafx.scene.input.KeyEvent> pPredicate)
-