mirror of
https://github.com/HeidiSQL/HeidiSQL.git
synced 2025-08-26 11:17:57 +08:00
Load all rows when user clicks the "Go to last row" button, so it is really the last row, not the 1000th one. Fixes issue #1750.
This commit is contained in:
@ -3231,12 +3231,12 @@ procedure TMainForm.actDataLastExecute(Sender: TObject);
|
|||||||
var
|
var
|
||||||
Node: PVirtualNode;
|
Node: PVirtualNode;
|
||||||
begin
|
begin
|
||||||
|
// Be sure to have all rows
|
||||||
|
if DatagridWantedRowCount < prefGridRowcountMax then
|
||||||
|
actDataShowAll.Execute;
|
||||||
Node := DataGrid.GetLast;
|
Node := DataGrid.GetLast;
|
||||||
if Assigned(Node) then begin
|
if Assigned(Node) then
|
||||||
DataGrid.ClearSelection;
|
SelectNode(DataGrid, Node);
|
||||||
DataGrid.FocusedNode := Node;
|
|
||||||
DataGrid.Selected[Node] := True;
|
|
||||||
end;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TMainForm.actDataPostChangesExecute(Sender: TObject);
|
procedure TMainForm.actDataPostChangesExecute(Sender: TObject);
|
||||||
@ -3369,7 +3369,7 @@ begin
|
|||||||
Inc(DatagridWantedRowCount, prefGridRowcountStep);
|
Inc(DatagridWantedRowCount, prefGridRowcountStep);
|
||||||
DataGridWantedRowCount := Min(DataGridWantedRowCount, prefGridRowcountMax);
|
DataGridWantedRowCount := Min(DataGridWantedRowCount, prefGridRowcountMax);
|
||||||
DataGrid.Tag := VTREE_NOTLOADED;
|
DataGrid.Tag := VTREE_NOTLOADED;
|
||||||
DataGrid.Invalidate;
|
DataGrid.Repaint;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
@ -3378,7 +3378,7 @@ begin
|
|||||||
// Remove LIMIT clause
|
// Remove LIMIT clause
|
||||||
DatagridWantedRowCount := prefGridRowcountMax;
|
DatagridWantedRowCount := prefGridRowcountMax;
|
||||||
DataGrid.Tag := VTREE_NOTLOADED;
|
DataGrid.Tag := VTREE_NOTLOADED;
|
||||||
DataGrid.Invalidate;
|
DataGrid.Repaint;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user