Class CapsLockPasswordBorderWidget


  • public class CapsLockPasswordBorderWidget
    extends RadianceThemingWidget<javax.swing.JPasswordField>
    Adds visual indication when caps-lock key is on in focused password fields.
    • Field Detail

      • propertyChangeListener

        private java.beans.PropertyChangeListener propertyChangeListener
        Listens on all properties to decide whether a caps lock border should be shown / hidden.
      • keyAdapter

        private java.awt.event.KeyAdapter keyAdapter
      • isUninstalling

        private boolean isUninstalling
        true if this widget is uninstalling.
      • ORIGINAL_BORDER

        private static final java.lang.String ORIGINAL_BORDER
        Name for client property that stores the original border.
        See Also:
        Constant Field Values
    • Constructor Detail

      • CapsLockPasswordBorderWidget

        public CapsLockPasswordBorderWidget()
    • Method Detail

      • installCapsLockBorder

        private void installCapsLockBorder()
        Installs the lock border on the associated component.
      • restoreOriginalBorder

        private void restoreOriginalBorder()
        Restores the original border on the associated component.
      • hasCapsLockIcon

        private static boolean hasCapsLockIcon​(java.awt.Component comp)
        Checks whether the specified component should show a lock icon. Is used in the CapsLockPasswordBorderWidget widget.
        Parameters:
        comp - Component.
        Returns:
        true if the specified component should show a lock icon, false otherwise.