You've already forked lazarus-ccr
* Skip unecessary call to AdjustAutoSize in Loaded
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@636 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -17454,8 +17454,9 @@ begin
|
|||||||
|
|
||||||
// Because of the special recursion and update stopper when creating the window (or resizing it)
|
// Because of the special recursion and update stopper when creating the window (or resizing it)
|
||||||
// we have to manually trigger the auto size calculation here.
|
// we have to manually trigger the auto size calculation here.
|
||||||
|
//lcl: Call with Force argument to true since AdjustAutoSize is not called in Loaded
|
||||||
if hoAutoResize in FHeader.FOptions then
|
if hoAutoResize in FHeader.FOptions then
|
||||||
FHeader.FColumns.AdjustAutoSize(InvalidColumn);
|
FHeader.FColumns.AdjustAutoSize(InvalidColumn, True);
|
||||||
|
|
||||||
// Initialize flat scroll bar library if required.
|
// Initialize flat scroll bar library if required.
|
||||||
{$ifdef UseFlatScrollbars}
|
{$ifdef UseFlatScrollbars}
|
||||||
@ -21756,10 +21757,13 @@ begin
|
|||||||
FHeader.UpdateMainColumn;
|
FHeader.UpdateMainColumn;
|
||||||
FHeader.FColumns.FixPositions;
|
FHeader.FColumns.FixPositions;
|
||||||
if toAutoBidiColumnOrdering in FOptions.FAutoOptions then
|
if toAutoBidiColumnOrdering in FOptions.FAutoOptions then
|
||||||
FHeader.FColumns.ReorderColumns(UseRightToLeftAlignment);
|
FHeader.FColumns.ReorderColumns(UseRightToLeftAlignment);
|
||||||
FHeader.RecalculateHeader;
|
FHeader.RecalculateHeader;
|
||||||
if hoAutoResize in FHeader.FOptions then
|
//lclheader
|
||||||
FHeader.FColumns.AdjustAutoSize(InvalidColumn, True);
|
//AdjustAutoSize is called inside CreateWnd. Don't call here
|
||||||
|
//Keep the commented code until we get sure of not being necessary
|
||||||
|
//if hoAutoResize in FHeader.FOptions then
|
||||||
|
// FHeader.FColumns.AdjustAutoSize(InvalidColumn, True);
|
||||||
finally
|
finally
|
||||||
Updated;
|
Updated;
|
||||||
end;
|
end;
|
||||||
|
Reference in New Issue
Block a user