View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0001684 | JEDI VCL | 00 JVCL Components | public | 2004-04-22 17:18 | 2004-04-22 23:48 |
Reporter | nestor | Assigned To | user72 | ||
Priority | normal | Severity | minor | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Product Version | |||||
Target Version | Fixed in Version | ||||
Summary | 0001684: TJvValidateEdit OnValueChanged does not notify | ||||
Description | TJvValidateEdit does not notify changed value TJvCustomValidateEdit.OnValueChanged does not notify the new value of the component Suggestion: In TJvCustomValidateEdit (JvValidateEdit unit) Remove all EnterText assignment from code Remove all DoValueChanged call from code Change DoValueChanged procedure to procedure TJvCustomValidateEdit.DoValueChanged; begin if Assigned(FOnValueChanged) and (EnterText <> FEditText) then FOnValueChanged(Self); EnterText := FEditText; end; Add “DoValueChanged†At the end of “SetEditText“ before or after DisplayText; Remove ChangeText(FEditText) from “SetEditTextâ€, DisplayText call this procedure. Other suggestions: In "KeyDown" procedure, the instruction (if Key = VK_DELETE then EditText:= MakeValid(inherited Text);) produce an unexpected behavior at run time. I suggest you removing it and adding the management of the Escape key to restore last validate value: procedure TJvCustomValidateEdit.KeyDown(var Key: Word; Shift: TShiftState); begin // if Key = VK_DELETE then EditText := MakeValid(inherited Text); if Key = VK_Escape then begin Key := 0; EditText := EnterText; SelStart := 0; SelLength := length(FEditText); end; inherited KeyDown(Key, Shift); end; Regards | ||||
Additional Information | I project to define my own inherited TjvValidateEdit component. For that I need "IsValidChar" and "MakeValid" to be declared virtual and to be moved towards the protected section. Is it possible? | ||||
Tags | No tags attached. | ||||
2004-04-22 17:19
|
JvValidateEditUpd.pas (34,022 bytes) |
|
Updated in CVS verbatim. Thanks for the fixes! |
Date Modified | Username | Field | Change |
---|---|---|---|
2004-04-22 17:18 | nestor | New Issue | |
2004-04-22 17:19 | nestor | File Added: JvValidateEditUpd.pas | |
2004-04-22 23:48 |
|
Status | new => resolved |
2004-04-22 23:48 |
|
Resolution | open => fixed |
2004-04-22 23:48 |
|
Assigned To | => user72 |
2004-04-22 23:48 |
|
Note Added: 0004022 |