mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-16 12:29:29 +02:00
LCL, limit position of scrollbar in dbgrid on new records (fix gtk2 scrollbar issues on some themes)
git-svn-id: trunk@21580 -
This commit is contained in:
parent
c1afea1846
commit
1ecbf0622e
@ -38,7 +38,7 @@ unit DBGrids;
|
||||
interface
|
||||
|
||||
uses
|
||||
Classes, SysUtils, FileUtil, DB,
|
||||
Classes, SysUtils, Math, FileUtil, DB,
|
||||
LCLStrConsts, LCLIntf, LCLProc, LCLType, LMessages, LResources,
|
||||
Controls, StdCtrls, Graphics, Grids, Dialogs, Themes;
|
||||
|
||||
@ -1368,7 +1368,7 @@ begin
|
||||
{$endif}
|
||||
ScrollInfo.nMin := 0;
|
||||
ScrollInfo.nMax := aRange;
|
||||
ScrollInfo.nPos := aPos;
|
||||
ScrollInfo.nPos := Min(aPos,aRange-aPage);
|
||||
ScrollInfo.nPage := aPage;
|
||||
// the redraw argument of SetScrollInfo means under gtk
|
||||
// if the scrollbar is visible or not, in windows it
|
||||
|
Loading…
Reference in New Issue
Block a user