--- src/include/dlgUser.h.orig Thu Mar 17 02:40:00 2005
+++ src/include/dlgUser.h Thu Mar 17 02:40:26 2005
@@ -47,6 +47,7 @@
void OnVarSelChange(wxListEvent &ev);
void OnVarnameSelChange(wxCommandEvent &ev);
+ void OnChangePasswd(wxCommandEvent &ev);
wxArrayString groupsIn;
--- src/ui/common/dlgUser.xrc.orig Thu Mar 17 01:16:46 2005
+++ src/ui/common/dlgUser.xrc Thu Mar 17 01:17:35 2005
@@ -29,32 +29,42 @@
+
+
--- src/ui/dlgUser.cpp.orig Thu Mar 17 02:32:23 2005
+++ src/ui/dlgUser.cpp Thu Mar 17 02:38:56 2005
@@ -26,6 +26,7 @@
// pointer to controls
#define txtID CTRL_TEXT("txtID")
#define txtPasswd CTRL_TEXT("txtPasswd")
+#define txtRePasswd CTRL_TEXT("txtRePasswd")
#define datValidUntil CTRL_CALENDAR("datValidUntil")
#define timValidUntil CTRL_TIME("timValidUntil")
#define chkCreateDB CTRL_CHECKBOX("chkCreateDB")
@@ -50,7 +51,8 @@
EVT_LISTBOX_DCLICK(XRCID("lbGroupsNotIn"), dlgUser::OnGroupAdd)
EVT_LISTBOX_DCLICK(XRCID("lbGroupsIn"), dlgUser::OnGroupRemove)
- EVT_TEXT(XRCID("txtPasswd"), dlgUser::OnChange)
+ EVT_TEXT(XRCID("txtPasswd"), dlgUser::OnChangePasswd)
+ EVT_TEXT(XRCID("txtRePasswd"), dlgUser::OnChangePasswd)
EVT_CHECKBOX(XRCID("chkCreateDB"), dlgUser::OnChange)
EVT_CHECKBOX(XRCID("chkCreateUser"), dlgUser::OnChangeSuperuser)
@@ -131,6 +133,7 @@
datValidUntil->Disable();
timValidUntil->Disable();
txtPasswd->Disable();
+ txtRePasswd->Disable();
btnAddGroup->Disable();
btnDelGroup->Disable();
cbVarname->Disable();
@@ -209,6 +212,17 @@
CheckChange();
}
+void dlgUser::OnChangePasswd(wxCommandEvent &ev)
+{
+ wxString passwd=txtPasswd->GetValue();
+ wxString repasswd=txtRePasswd->GetValue();
+ if ((!repasswd.IsEmpty())||(!repasswd.IsEmpty()))
+ {
+ bool enable=true;
+ CheckValid(enable, !passwd.compare(repasswd), _("The passwords entered do not match!"));
+ EnableOK(enable);
+ }
+}
void dlgUser::CheckChange()
{