File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2146,6 +2146,7 @@ object MainForm: TMainForm
21462146 OnHeaderDraggedOut = AnyGridHeaderDraggedOut
21472147 OnInitNode = ListTablesInitNode
21482148 OnKeyPress = ListTablesKeyPress
2149+ OnMouseUp = AnyGridMouseUp
21492150 OnNewText = ListTablesNewText
21502151 end
21512152 end
Original file line number Diff line number Diff line change @@ -7467,7 +7467,7 @@ procedure TMainForm.ListTablesEditing(Sender: TBaseVirtualTree;
74677467 // Tables and views can be renamed, routines cannot
74687468 if Assigned(Node) then begin
74697469 Obj := Sender.GetNodeData(Node);
7470- Allowed := Obj.NodeType in [lntTable, lntView];
7470+ Allowed := ( Obj.NodeType in [lntTable, lntView]) and (FLastMouseButtonUpOnGrid = mbLeft) ;
74717471 end;
74727472end;
74737473
@@ -11334,6 +11334,9 @@ procedure TMainForm.AnyGridMouseUp(Sender: TObject; Button: TMouseButton;
1133411334 Grid := Sender as TVirtualStringTree;
1133511335 if not Assigned(Grid.FocusedNode) then
1133611336 Exit;
11337+ // Exit early for non-result-grids like ListTables
11338+ if Grid <> ActiveGrid then
11339+ Exit;
1133711340 Grid.GetHitTestInfoAt(X, Y, False, {%H-}Hit);
1133811341 if (Hit.HitNode = nil) or (Hit.HitColumn = NoColumn) or (Hit.HitColumn = InvalidColumn) then begin
1133911342 Results := GridResult(Grid);
You can’t perform that action at this time.
0 commit comments