You've already forked lazarus-ccr
* Synchronize with main VTV repository up to svn rev 547
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3409 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -103,7 +103,7 @@ const
|
|||||||
|
|
||||||
VTMajorVersion = 5;
|
VTMajorVersion = 5;
|
||||||
VTMinorVersion = 2;
|
VTMinorVersion = 2;
|
||||||
VTReleaseVersion = 0;
|
VTReleaseVersion = 1;
|
||||||
VTTreeStreamVersion = 2;
|
VTTreeStreamVersion = 2;
|
||||||
VTHeaderStreamVersion = 6; // The header needs an own stream version to indicate changes only relevant to the header.
|
VTHeaderStreamVersion = 6; // The header needs an own stream version to indicate changes only relevant to the header.
|
||||||
|
|
||||||
@ -559,7 +559,7 @@ type
|
|||||||
const
|
const
|
||||||
DefaultPaintOptions = [toShowButtons, toShowDropmark, toShowTreeLines, toShowRoot, toThemeAware, toUseBlendedImages];
|
DefaultPaintOptions = [toShowButtons, toShowDropmark, toShowTreeLines, toShowRoot, toThemeAware, toUseBlendedImages];
|
||||||
DefaultAnimationOptions = [];
|
DefaultAnimationOptions = [];
|
||||||
DefaultAutoOptions = [toAutoDropExpand, toAutoTristateTracking, toAutoScrollOnExpand, toAutoDeleteMovedNodes];
|
DefaultAutoOptions = [toAutoDropExpand, toAutoTristateTracking, toAutoScrollOnExpand, toAutoDeleteMovedNodes, toAutoChangeScale, toAutoSort];
|
||||||
DefaultSelectionOptions = [];
|
DefaultSelectionOptions = [];
|
||||||
DefaultMiscOptions = [toAcceptOLEDrop, toFullRepaintOnResize, toInitOnSave, toToggleOnDblClick, toWheelPanning,
|
DefaultMiscOptions = [toAcceptOLEDrop, toFullRepaintOnResize, toInitOnSave, toToggleOnDblClick, toWheelPanning,
|
||||||
toEditOnClick];
|
toEditOnClick];
|
||||||
@ -2692,6 +2692,7 @@ type
|
|||||||
procedure DrawDottedHLine(const PaintInfo: TVTPaintInfo; Left, Right, Top: Integer); virtual;
|
procedure DrawDottedHLine(const PaintInfo: TVTPaintInfo; Left, Right, Top: Integer); virtual;
|
||||||
procedure DrawDottedVLine(const PaintInfo: TVTPaintInfo; Top, Bottom, Left: Integer); virtual;
|
procedure DrawDottedVLine(const PaintInfo: TVTPaintInfo; Top, Bottom, Left: Integer); virtual;
|
||||||
procedure EndOperation(OperationKind: TVTOperationKind);
|
procedure EndOperation(OperationKind: TVTOperationKind);
|
||||||
|
procedure EnsureNodeFocused(); virtual;
|
||||||
function FindNodeInSelection(P: PVirtualNode; var Index: Integer; LowBound, HighBound: Integer): Boolean; virtual;
|
function FindNodeInSelection(P: PVirtualNode; var Index: Integer; LowBound, HighBound: Integer): Boolean; virtual;
|
||||||
procedure FinishChunkHeader(Stream: TStream; StartPos, EndPos: Integer); virtual;
|
procedure FinishChunkHeader(Stream: TStream; StartPos, EndPos: Integer); virtual;
|
||||||
procedure FontChanged(AFont: TObject); virtual;
|
procedure FontChanged(AFont: TObject); virtual;
|
||||||
@ -5288,7 +5289,6 @@ begin
|
|||||||
if NeedToUnitialize then
|
if NeedToUnitialize then
|
||||||
OleUninitialize;
|
OleUninitialize;
|
||||||
|
|
||||||
{$ifdef VCLStyleSupport}TCustomStyleEngine.UnRegisterStyleHook(TBaseVirtualTree, TVclStyleScrollBarsHook);{$ifend}
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
//----------------- TWorkerThread --------------------------------------------------------------------------------------
|
//----------------- TWorkerThread --------------------------------------------------------------------------------------
|
||||||
@ -16783,6 +16783,8 @@ begin
|
|||||||
InvalidateNode(FCheckNode);
|
InvalidateNode(FCheckNode);
|
||||||
FCheckNode := nil;
|
FCheckNode := nil;
|
||||||
end;
|
end;
|
||||||
|
VK_TAB:
|
||||||
|
EnsureNodeFocused(); // Always select a node if the control gets the focus via TAB key, #237
|
||||||
end;
|
end;
|
||||||
{$ifdef DEBUG_VTV}Logger.ExitMethod([lcMessages],'WMKeyUp');{$endif}
|
{$ifdef DEBUG_VTV}Logger.ExitMethod([lcMessages],'WMKeyUp');{$endif}
|
||||||
end;
|
end;
|
||||||
@ -19361,10 +19363,6 @@ end;
|
|||||||
procedure TBaseVirtualTree.DoEnter();
|
procedure TBaseVirtualTree.DoEnter();
|
||||||
begin
|
begin
|
||||||
inherited;
|
inherited;
|
||||||
// Always select a node if the control gets the focus, #237
|
|
||||||
if FocusedNode = nil then begin
|
|
||||||
FocusedNode := Self.GetFirstVisible();
|
|
||||||
end;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
//----------------------------------------------------------------------------------------------------------------------
|
//----------------------------------------------------------------------------------------------------------------------
|
||||||
@ -20976,6 +20974,14 @@ end;
|
|||||||
|
|
||||||
//----------------------------------------------------------------------------------------------------------------------
|
//----------------------------------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
procedure TBaseVirtualTree.EnsureNodeFocused();
|
||||||
|
begin
|
||||||
|
if FocusedNode = nil then
|
||||||
|
FocusedNode := Self.GetFirstVisible();
|
||||||
|
end;
|
||||||
|
|
||||||
|
//----------------------------------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
function TBaseVirtualTree.FindNodeInSelection(P: PVirtualNode; var Index: Integer; LowBound,
|
function TBaseVirtualTree.FindNodeInSelection(P: PVirtualNode; var Index: Integer; LowBound,
|
||||||
HighBound: Integer): Boolean;
|
HighBound: Integer): Boolean;
|
||||||
|
|
||||||
@ -21326,6 +21332,7 @@ begin
|
|||||||
if WithCheck and (Node.CheckType <> ctNone) then
|
if WithCheck and (Node.CheckType <> ctNone) then
|
||||||
Inc(NodeLeft, CheckOffset);
|
Inc(NodeLeft, CheckOffset);
|
||||||
CurrentWidth := DoGetNodeWidth(Node, NoColumn);
|
CurrentWidth := DoGetNodeWidth(Node, NoColumn);
|
||||||
|
Inc(CurrentWidth, DoGetNodeExtraWidth(Node, NoColumn));
|
||||||
if Integer(Result) < (NodeLeft + CurrentWidth) then
|
if Integer(Result) < (NodeLeft + CurrentWidth) then
|
||||||
Result := NodeLeft + CurrentWidth;
|
Result := NodeLeft + CurrentWidth;
|
||||||
Inc(TopPosition, NodeHeight[Node]);
|
Inc(TopPosition, NodeHeight[Node]);
|
||||||
@ -31510,7 +31517,7 @@ begin
|
|||||||
if Node.ChildCount > 0 then
|
if Node.ChildCount > 0 then
|
||||||
begin
|
begin
|
||||||
UpdateRanges;
|
UpdateRanges;
|
||||||
|
UpdateScrollbars(True);
|
||||||
if [tsPainting, tsExpanding] * FStates = [] then
|
if [tsPainting, tsExpanding] * FStates = [] then
|
||||||
begin
|
begin
|
||||||
if (vsExpanded in Node.States) and ((toAutoScrollOnExpand in FOptions.FAutoOptions) or
|
if (vsExpanded in Node.States) and ((toAutoScrollOnExpand in FOptions.FAutoOptions) or
|
||||||
@ -31553,7 +31560,7 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
UpdateScrollbars(True);
|
//UpdateScrollbars(True); Moved up
|
||||||
|
|
||||||
// Check for automatically scrolled tree.
|
// Check for automatically scrolled tree.
|
||||||
if NeedFullInvalidate then
|
if NeedFullInvalidate then
|
||||||
|
Reference in New Issue
Block a user