modules/graphics/src/test/java/javafx/css/Node_cssStateTransition_Test.java
Print this page
rev 9240 : 8076423: JEP 253: Prepare JavaFX UI Controls & CSS APIs for Modularization
@@ -21,19 +21,16 @@
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
-package com.sun.javafx.css;
+package javafx.css;
-import com.sun.javafx.css.parser.CSSParser;
+import com.sun.javafx.css.StyleManager;
import java.io.IOException;
-import javafx.css.CssMetaData;
-import javafx.css.PseudoClass;
-import javafx.css.StyleableProperty;
import javafx.scene.Group;
import javafx.scene.Scene;
import javafx.scene.paint.Color;
import javafx.scene.paint.Paint;
import javafx.scene.shape.Rectangle;
@@ -76,11 +73,11 @@
Stylesheet stylesheet = null;
try {
// Note: setDefaultUserAgentStylesheet in StyleManager won't replace the UA stylesheet unless it has a name,
// and that name needs to be different from the current one, if any. This matters when running
// these tests from the same VM since StyleManager is a singleton.
- stylesheet = CSSParser.getInstance().parse(
+ stylesheet = new CssParser().parse(
"testPropertiesResetOnStyleclassChange",
".rect { -fx-fill: red; -fx-stroke: yellow; -fx-stroke-width: 3px; }" +
".rect.green { -fx-fill: green; }" +
".green { -fx-stroke: green; }"
@@ -143,11 +140,11 @@
Stylesheet stylesheet = null;
try {
// Note: setDefaultUserAgentStylesheet in StyleManager won't replace the UA stylesheet unless it has a name,
// and that name needs to be different from the current one, if any. This matters when running
// these tests from the same VM since StyleManager is a singleton.
- stylesheet = CSSParser.getInstance().parse(
+ stylesheet = new CssParser().parse(
"testPropertiesResetOnPsedudoClassStateChange",
".rect:hover { -fx-fill: red; -fx-stroke: yellow; -fx-stroke-width: 3px; }" +
".rect:hover:focused { -fx-fill: green; }" +
".rect:focused { -fx-stroke: green; }"