[Lazarus] Treeview bug

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[Lazarus] Treeview bug

Free Pascal - Lazarus mailing list

Hi,

When you set Multiselect = True, the treeview (Linux, GTK) sends OnChange
messages with Nil node.


procedure TCustomTreeView.OnChangeTimer(Sender: TObject);
begin
   FChangeTimer.Enabled := False;
   //debugln('TCustomTreeView.OnChangeTimer');
   FCallingChange := True;
   try
     Change(FSelectedNode); // <<-- FSelectedNode is Nil.
   finally
     FCallingChange := False;
   end;
end;

Is this by design ?

Michael.
--
_______________________________________________
lazarus mailing list
[hidden email]
https://lists.lazarus-ide.org/listinfo/lazarus
Reply | Threaded
Open this post in threaded view
|

Re: [Lazarus] Treeview bug

Free Pascal - Lazarus mailing list
On Mon, Apr 15, 2019 at 11:00 AM Michael Van Canneyt via lazarus
<[hidden email]> wrote:
> When you set Multiselect = True, the treeview (Linux, GTK) sends OnChange
> messages with Nil node.
>
> procedure TCustomTreeView.OnChangeTimer(Sender: TObject);

The name OnChangeTimer hints the handler is for a timer. Is it so?

Juha
--
_______________________________________________
lazarus mailing list
[hidden email]
https://lists.lazarus-ide.org/listinfo/lazarus