diff --git a/component/src/main/java/org/pushingpixels/radiance/component/api/common/JCommandButton.java b/component/src/main/java/org/pushingpixels/radiance/component/api/common/JCommandButton.java index 1ab0c758e..58102958a 100644 --- a/component/src/main/java/org/pushingpixels/radiance/component/api/common/JCommandButton.java +++ b/component/src/main/java/org/pushingpixels/radiance/component/api/common/JCommandButton.java @@ -344,7 +344,7 @@ public JCommandButton(BaseCommandButtonProjection, } if (!commandPresentation.isToDismissPopupsOnActivation()) { - this.putClientProperty(BasicCommandButtonUI.DONT_DISPOSE_POPUPS, Boolean.TRUE); + this.putClientProperty(BasicCommandButtonUI.DO_NOT_DISPOSE_POPUPS, Boolean.TRUE); } this.setPresentationState(commandPresentation.getPresentationState()); @@ -377,7 +377,8 @@ public JCommandButton(BaseCommandButtonProjection, } if (hasAction && hasPopup) { - this.setCommandButtonKind(commandPresentation.getTextClick() == BaseCommandButtonPresentationModel.TextClick.ACTION + this.setCommandButtonKind((commandPresentation.getTextClick() == + BaseCommandButtonPresentationModel.TextClick.ACTION) ? JCommandButton.CommandButtonKind.ACTION_AND_POPUP_MAIN_ACTION : JCommandButton.CommandButtonKind.ACTION_AND_POPUP_MAIN_POPUP); } else if (hasPopup) { diff --git a/component/src/main/java/org/pushingpixels/radiance/component/internal/ui/common/BasicCommandButtonUI.java b/component/src/main/java/org/pushingpixels/radiance/component/internal/ui/common/BasicCommandButtonUI.java index 3184f2bb4..d9358ec7c 100644 --- a/component/src/main/java/org/pushingpixels/radiance/component/internal/ui/common/BasicCommandButtonUI.java +++ b/component/src/main/java/org/pushingpixels/radiance/component/internal/ui/common/BasicCommandButtonUI.java @@ -107,15 +107,15 @@ public abstract class BasicCommandButtonUI extends CommandButtonUI { * * @see #disposePopupsActionListener */ - public static final String DONT_DISPOSE_POPUPS = - "radiance.component.internal.commandButton.ui.dontDisposePopups"; + public static final String DO_NOT_DISPOSE_POPUPS = + "radiance.component.internal.commandButton.ui.doNotDisposePopups"; /** * This listener disposes all popup panels when button's action is activated. An example of * scenario would be a command button in the popup panel of an in-ribbon gallery. When this * command button is activated, the associated popup panel is dismissed. * - * @see #DONT_DISPOSE_POPUPS + * @see #DO_NOT_DISPOSE_POPUPS */ private CommandAction disposePopupsActionListener; @@ -400,7 +400,7 @@ protected void installListeners() { this.disposePopupsActionListener = commandActionEvent -> { boolean toDismiss = !Boolean.TRUE - .equals(commandButton.getClientProperty(DONT_DISPOSE_POPUPS)); + .equals(commandButton.getClientProperty(DO_NOT_DISPOSE_POPUPS)); if (toDismiss) { JCommandPopupMenuPanel menuPanel = (JCommandPopupMenuPanel) SwingUtilities .getAncestorOfClass(JCommandPopupMenuPanel.class, commandButton);