private void refreshPWLabel() { if (passwordMatch == null || passwordMatch.isDisposed()) return; byte[] password = COConfigurationManager.getByteParameter("Password", "".getBytes()); COConfigurationManager.setParameter("Password enabled", false); if (password.length == 0) { passwordMatch.setText(MessageText.getString(LBLKEY_PREFIX + "passwordmatchnone")); } else { byte[] confirm = COConfigurationManager.getByteParameter("Password Confirm", "".getBytes()); if (confirm.length == 0) { passwordMatch.setText(MessageText.getString(LBLKEY_PREFIX + "passwordmatchno")); } else { boolean same = true; for (int i = 0; i < password.length; i++) { if (password[i] != confirm[i]) same = false; } if (same) { passwordMatch.setText(MessageText.getString(LBLKEY_PREFIX + "passwordmatchyes")); COConfigurationManager.setParameter("Password enabled", true); } else { passwordMatch.setText(MessageText.getString(LBLKEY_PREFIX + "passwordmatchno")); } } } }