diff --git a/modules/graphics/src/main/java/javafx/application/Platform.java b/modules/graphics/src/main/java/javafx/application/Platform.java --- a/modules/graphics/src/main/java/javafx/application/Platform.java +++ b/modules/graphics/src/main/java/javafx/application/Platform.java @@ -25,6 +25,7 @@ package javafx.application; +import com.sun.javafx.tk.Toolkit; import javafx.beans.property.ReadOnlyBooleanProperty; import javafx.beans.property.ReadOnlyBooleanWrapper; import com.sun.javafx.application.PlatformImpl; @@ -168,6 +169,18 @@ return PlatformImpl.isSupported(feature); } + /** + * Forces an extraordinary pulse to happen. This can be useful to ensure in + * certain circumstances that a pulse has definitely occurred before + * proceeding (e.g. in unit tests). + * + * @since 9 + */ + public void firePulse() { + Toolkit.getToolkit().firePulse(); + } + + private static ReadOnlyBooleanWrapper accessibilityActiveProperty; public static boolean isAccessibilityActive() {