/** * Is the password quality field? * * @return Enabled? */ @Override public boolean isEnabled() { return jpfPassword.isEnabled(); }
/** * Returns the Identity password. * * @return the Identity password. **/ public char[] getIdentityPassword() { if (!identityPassField.isEnabled()) { return null; } char[] result = identityPassField.getPassword(); return result; }
/** * Returns the KeyStore password. * * @return the KeyStore password. **/ public char[] getKeyStorePassword() { if (!storePassField.isEnabled()) { return null; } char[] result = storePassField.getPassword(); return result; }
@Override public void propertyChange(PropertyChangeEvent evt) { if ("font".equals(evt.getPropertyName())) { SwingUtilities.invokeLater(new Runnable() { @Override public void run() { // remember the caret location - issue 404 int caretPos = passwordField.getCaretPosition(); passwordField.updateUI(); passwordField.setCaretPosition(caretPos); Container parent = passwordField.getParent(); if (parent != null) { parent.invalidate(); parent.validate(); } } }); } if ("enabled".equals(evt.getPropertyName())) { transitionModel.setEnabled(passwordField.isEnabled()); } } };
public void propertyChange(PropertyChangeEvent evt) { if ("font".equals(evt.getPropertyName())) { SwingUtilities.invokeLater(new Runnable() { public void run() { // remember the caret location - issue 404 int caretPos = passwordField.getCaretPosition(); passwordField.updateUI(); passwordField.setCaretPosition(caretPos); Container parent = passwordField.getParent(); if (parent != null) { parent.invalidate(); parent.validate(); } } }); } if ("enabled".equals(evt.getPropertyName())) { transitionModel.setEnabled(passwordField.isEnabled()); } } };
private void setWidgetActivation() { passwordField.setEnabled(requirePasswordCheckBox.isSelected()); final Color backGround = passwordField.isEnabled() ? portField.getBackground() : getBackground(); passwordField.setBackground(backGround); }
int dotGap = SubstanceSizeUtils.getPasswordDotGap(fontSize); (field.isEnabled() ? ComponentState.ENABLED : ComponentState.DISABLED_UNSELECTED); SubstanceColorScheme scheme = SubstanceColorSchemeUtilities
int dotGap = SubstanceSizeUtils.getPasswordDotGap(fontSize); (field.isEnabled() ? ComponentState.ENABLED : ComponentState.DISABLED_UNSELECTED); SubstanceColorScheme scheme = SubstanceColorSchemeUtilities
/** * Creates the UI delegate for the specified component (password field). * * @param c * Component. */ public SubstancePasswordFieldUI(JComponent c) { super(); this.passwordField = (JPasswordField) c; this.transitionModel = new DefaultButtonModel(); this.transitionModel.setArmed(false); this.transitionModel.setSelected(false); this.transitionModel.setPressed(false); this.transitionModel.setRollover(false); this.transitionModel.setEnabled(this.passwordField.isEnabled()); this.stateTransitionTracker = new StateTransitionTracker( this.passwordField, this.transitionModel); }
/** * Creates the UI delegate for the specified component (password field). * * @param c * Component. */ public SubstancePasswordFieldUI(JComponent c) { super(); this.passwordField = (JPasswordField) c; this.transitionModel = new DefaultButtonModel(); this.transitionModel.setArmed(false); this.transitionModel.setSelected(false); this.transitionModel.setPressed(false); this.transitionModel.setRollover(false); this.transitionModel.setEnabled(this.passwordField.isEnabled()); this.stateTransitionTracker = new StateTransitionTracker( this.passwordField, this.transitionModel); }
else if (!passwordField.isEnabled()) { setChangePasswordEnabled(true); error("<html><p width=400>Please type in your the password for your account on the Fiji/ImageJ Wiki</p></html>");