On Mon, 3 Feb 2025 23:43:47 GMT, Andy Goryachev <ango...@openjdk.org> wrote:
>> Michael Strauß has updated the pull request incrementally with one >> additional commit since the last revision: >> >> macOS bugfixes, default button behavior > > modules/javafx.graphics/src/main/java/com/sun/javafx/scene/layout/HeaderButtonBehavior.java > line 88: > >> 86: stage.setMaximized(!stage.isMaximized()); >> 87: } >> 88: }); > > I think it might be better to add a default case here, _in case this enum > evolves_. Why? This isn't some external enum that might evolve out from under this code, but is part of the same feature. If the enum evolves then the resulting compiler error is a _good_ thing as it alerts whoever added the new enum that they didn't finish implementing it. A default makes sense when the enum might evolve separately from the use of the enum. ------------- PR Review Comment: https://git.openjdk.org/jfx/pull/1605#discussion_r1940334817