RFR: 8216507: StyleablePropertyFactory: example in class javadoc does not compile [v2]

Karthik P K kpk at openjdk.org
Fri Dec 23 17:05:40 UTC 2022


On Fri, 23 Dec 2022 16:52:02 GMT, Andy Goryachev <angorya at openjdk.org> wrote:

>> Karthik P K has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Fix build error
>
> modules/javafx.graphics/src/main/java/javafx/css/StyleablePropertyFactory.java line 124:
> 
>> 122:  public final class MyButton extends Button {
>> 123: 
>> 124:      private static CssMetaData<JavadocFixStylableProperty, Boolean> SELECTED;
> 
> should it be
> 
> 
> private static CssMetaData<MyButton, Boolean> SELECTED;
> 
> 
> in order to compile?

Updated this change

> modules/javafx.graphics/src/main/java/javafx/css/StyleablePropertyFactory.java line 146:
> 
>> 144:      // StyleableProperty implementation reduced to one line
>> 145:      private final {@literal StyleableProperty<Boolean>} selected =
>> 146:          new SimpleStyleableBooleanProperty(SELECTED, "selected", "my-selected");
> 
> as an exercise, could you actually put MyButton into a scene graph and style it with CSS?

I will check this and update here

-------------

PR: https://git.openjdk.org/jfx/pull/983


More information about the openjfx-dev mailing list