[Lazarus] componentlist patch

Sandro Cumerlato sandro.cumerlato at gmail.com
Tue Mar 10 22:38:35 CET 2015


Componentlist TTreeView controls are not controlled by keyboard arrow keys.

Please review attached patch.

Sandro Cumerlato
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20150310/6a7c20f3/attachment-0002.html>
-------------- next part --------------
Index: ide/componentlist.lfm
===================================================================
--- ide/componentlist.lfm	(revisione 48251)
+++ ide/componentlist.lfm	(copia locale)
@@ -59,7 +59,7 @@
           ShowLines = False
           ShowRoot = False
           TabOrder = 0
-          OnClick = ComponentsClick
+          OnChange = ComponentsChange
           OnDblClick = ComponentsDblClick
           OnKeyPress = TreeKeyPress
           Options = [tvoHideSelection, tvoKeepCollapsedNodes, tvoReadOnly, tvoRowSelect, tvoToolTips]
@@ -95,7 +95,7 @@
           RowSelect = True
           ShowLines = False
           TabOrder = 0
-          OnClick = ComponentsClick
+          OnChange = ComponentsChange
           OnDblClick = ComponentsDblClick
           OnKeyPress = TreeKeyPress
           Options = [tvoHideSelection, tvoKeepCollapsedNodes, tvoReadOnly, tvoRightClickSelect, tvoRowSelect, tvoShowButtons, tvoShowRoot, tvoToolTips]
@@ -131,7 +131,7 @@
           RightClickSelect = True
           RowSelect = True
           TabOrder = 0
-          OnClick = ComponentsClick
+          OnChange = ComponentsChange
           OnDblClick = ComponentsDblClick
           OnKeyPress = TreeKeyPress
           Options = [tvoHideSelection, tvoKeepCollapsedNodes, tvoReadOnly, tvoRightClickSelect, tvoRowSelect, tvoShowButtons, tvoShowLines, tvoShowRoot, tvoToolTips]
Index: ide/componentlist.pas
===================================================================
--- ide/componentlist.pas	(revisione 48251)
+++ ide/componentlist.pas	(copia locale)
@@ -71,7 +71,7 @@
     procedure miExpandClick(Sender: TObject);
     procedure OKButtonClick(Sender: TObject);
     procedure ComponentsDblClick(Sender: TObject);
-    procedure ComponentsClick(Sender: TObject);
+    procedure ComponentsChange(Sender: TObject; Node: TTreeNode);
     procedure FormClose(Sender: TObject; var CloseAction: TCloseAction);
     procedure pmCollapseExpandPopup(Sender: TObject);
     procedure TreeFilterEdAfterFilter(Sender: TObject);
@@ -347,7 +347,7 @@
   OKButtonClick(nil);       // Select and close this form
 end;
 
-procedure TComponentListForm.ComponentsClick(Sender: TObject);
+procedure TComponentListForm.ComponentsChange(Sender: TObject; Node: TTreeNode);
 // This is used for all 3 treeviews
 var
   AComponent: TRegisteredComponent;


More information about the Lazarus mailing list