View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0002524 | JEDI VCL | 00 JVCL Components | public | 2005-01-17 15:12 | 2005-01-22 06:02 |
Reporter | Simes | Assigned To | AHUser | ||
Priority | normal | Severity | minor | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Product Version | 3.00 BETA 2 | ||||
Target Version | Fixed in Version | 3.00 | |||
Summary | 0002524: TJvEditor doesn't invoke OnChange when Lines.Text changed or Lines assigned | ||||
Description | Setting the value of Lines.Text, or assigning Lines doesn't invoke the OnChange event. Run the code below. Click button 1 or 2, OnChange event doesn't happen. (Similar problem to already fixed 2216) | ||||
Additional Information | unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls, JvExControls, JvComponent, JvEditorCommon, JvEditor; type TForm1 = class(TForm) JvEditor1: TJvEditor; Button1: TButton; Button2: TButton; procedure Button1Click(Sender: TObject); procedure JvEditor1Change(Sender: TObject); procedure Button2Click(Sender: TObject); private public end; var Form1: TForm1; implementation {$R *.dfm} procedure TForm1.Button1Click(Sender: TObject); begin JvEditor1.Lines.Text := 'Some text'; end; procedure TForm1.Button2Click(Sender: TObject); var sl: TStringList; begin sl := TStringList.Create; try sl.Add('Some strings'); sl.Add('Some more strings'); JvEditor1.Lines.Assign(sl); finally sl.Free; end; end; procedure TForm1.JvEditor1Change(Sender: TObject); begin Caption := 'Changed'; // never happens end; end. | ||||
Tags | No tags attached. | ||||
|
Suggest TJvCustomEditor.DoLinesChange calls TJvCustomEditorBase.Changed instead of setting Modified property directly. |
|
Fixed in CVS. - Moved DoLineChanged to JvEditorCommon - Changed DoLineChanged to call "Changed;" - Added assignment code of DoLineChanged to JvUnicodeEditor |