Skip to content

Disabled JMenu not always painted disabled #260

Closed
@weisJ

Description

@weisJ

If a JMenu overwrites isEnabled to return false without calling setVisible it doesn't get painted disabled. Of course if this happens while the menu is already shown this is expected, but a menu which already reports this upon first being painted (e.g. by returning false before the popup menu is visible) should still be painted disabled.

This comes in handy if once wants to have a JMenu be disabled if it has no children. The question would be if we simply always paint JMenus disabled if they have no child items (with a flag to change this behaviour if desired).

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions