* Patch from Joost van der Sluis to fix compilation on fpc 2.1.1 r2020 #6655ed568d

git-svn-id: trunk@8354 -
This commit is contained in:
marc 2005-12-21 22:04:09 +00:00
parent 7ffc2d0f43
commit 6f345ed1d4
3 changed files with 18 additions and 18 deletions

View File

@ -658,7 +658,7 @@ type
published published
property Control: TControl read FControl write SetControl; property Control: TControl read FControl write SetControl;
property Side: TAnchorSideReference read FSide write SetSide property Side: TAnchorSideReference read FSide write SetSide
stored IsSideStored default TAnchorSideReference(-1); stored IsSideStored default asrTop;
end; end;

View File

@ -91,7 +91,7 @@ type
procedure SkipSetBody; procedure SkipSetBody;
function ReadIntegerContent: integer; function ReadIntegerContent: integer;
public public
constructor Create(Stream: TStream; BufSize: Integer); virtual; constructor Create(AStream: TStream; BufSize: Integer); virtual;
destructor Destroy; override; destructor Destroy; override;
function NextValue: TValueType; override; function NextValue: TValueType; override;
@ -203,7 +203,7 @@ type
LFMPositions: Boolean): integer; LFMPositions: Boolean): integer;
procedure SetPosition(const FromPos, ToPos, MappedPos: int64; procedure SetPosition(const FromPos, ToPos, MappedPos: int64;
LFMtoLRSPositions: Boolean); LFMtoLRSPositions: Boolean);
procedure Add(const LFMPos, LRSPos: Int64; Data: Pointer); procedure Add(const LFMPos, LRSPos: Int64; AData: Pointer);
public public
property LFM[Index: integer]: int64 read GetLFM write SetLFM; property LFM[Index: integer]: int64 read GetLFM write SetLFM;
property LRS[Index: integer]: int64 read GetLRS write SetLRS; property LRS[Index: integer]: int64 read GetLRS write SetLRS;
@ -2606,10 +2606,10 @@ begin
{$endif} {$endif}
end; end;
constructor TLRSObjectReader.Create(Stream: TStream; BufSize: Integer); constructor TLRSObjectReader.Create(AStream: TStream; BufSize: Integer);
begin begin
inherited Create; inherited Create;
FStream := Stream; FStream := AStream;
FBufSize := BufSize; FBufSize := BufSize;
GetMem(FBuffer, BufSize); GetMem(FBuffer, BufSize);
end; end;
@ -3474,7 +3474,7 @@ begin
PLRPositionLink(FItems[i])^.LFMPosition:=MappedPos; PLRPositionLink(FItems[i])^.LFMPosition:=MappedPos;
end; end;
procedure TLRPositionLinks.Add(const LFMPos, LRSPos: Int64; Data: Pointer); procedure TLRPositionLinks.Add(const LFMPos, LRSPos: Int64; AData: Pointer);
var var
Item: PLRPositionLink; Item: PLRPositionLink;
begin begin
@ -3482,7 +3482,7 @@ begin
Item:=PLRPositionLink(FItems[Count-1]); Item:=PLRPositionLink(FItems[Count-1]);
Item^.LFMPosition:=LFMPos; Item^.LFMPosition:=LFMPos;
Item^.LRSPosition:=LRSPos; Item^.LRSPosition:=LRSPos;
Item^.Data:=Data; Item^.Data:=AData;
end; end;
initialization initialization

View File

@ -51,7 +51,7 @@ Type
function GetStoredValues: TStoredValues; function GetStoredValues: TStoredValues;
protected protected
function GetDisplayName: string; override; function GetDisplayName: string; override;
procedure SetDisplayName(const Value: string); override; procedure SetDisplayName(const AValue: string); override;
public public
constructor Create(ACollection: TCollection); override; constructor Create(ACollection: TCollection); override;
procedure Assign(Source: TPersistent); override; procedure Assign(Source: TPersistent); override;
@ -74,11 +74,11 @@ Type
private private
FStorage: TCustomPropertyStorage; FStorage: TCustomPropertyStorage;
function GetValue(const AName: string): TStoredValue; function GetValue(const AName: string): TStoredValue;
procedure SetValue(const AName: string; StoredValue: TStoredValue); procedure SetValue(const AName: string; AStoredValue: TStoredValue);
function GetStoredValue(const AName: string): TStoredType; function GetStoredValue(const AName: string): TStoredType;
procedure SetStoredValue(const AName: string; Value: TStoredType); procedure SetStoredValue(const AName: string; Value: TStoredType);
function GetItem(Index: Integer): TStoredValue; function GetItem(Index: Integer): TStoredValue;
procedure SetItem(Index: Integer; StoredValue: TStoredValue); procedure SetItem(Index: Integer; AStoredValue: TStoredValue);
public public
constructor Create(AOwner: TPersistent); constructor Create(AOwner: TPersistent);
function IndexOf(const AName: string): Integer; function IndexOf(const AName: string): Integer;
@ -277,13 +277,13 @@ begin
Result := FName; Result := FName;
end; end;
procedure TStoredValue.SetDisplayName(const Value: string); procedure TStoredValue.SetDisplayName(const AValue: string);
begin begin
if (Value <> '') and (AnsiCompareText(Value, FName) <> 0) if (AValue <> '') and (AnsiCompareText(AValue, FName) <> 0)
and (Collection is TStoredValues) and (Collection is TStoredValues)
and (TStoredValues(Collection).IndexOf(Value) >= 0) then and (TStoredValues(Collection).IndexOf(AValue) >= 0) then
raise Exception.Create(SDuplicateString); raise Exception.Create(SDuplicateString);
FName := Value; FName := AValue;
inherited; inherited;
end; end;
@ -373,9 +373,9 @@ begin
Result := TStoredValue(inherited Items[Index]); Result := TStoredValue(inherited Items[Index]);
end; end;
procedure TStoredValues.SetItem(Index: Integer; StoredValue: TStoredValue); procedure TStoredValues.SetItem(Index: Integer; AStoredValue: TStoredValue);
begin begin
inherited SetItem(Index, TCollectionItem(StoredValue)); inherited SetItem(Index, TCollectionItem(AStoredValue));
end; end;
function TStoredValues.GetStoredValue(const AName: string): TStoredType; function TStoredValues.GetStoredValue(const AName: string): TStoredType;
@ -417,13 +417,13 @@ begin
Result := Items[I]; Result := Items[I];
end; end;
procedure TStoredValues.SetValue(const AName: string; StoredValue: TStoredValue); procedure TStoredValues.SetValue(const AName: string; AStoredValue: TStoredValue);
var var
I: Integer; I: Integer;
begin begin
I := IndexOf(AName); I := IndexOf(AName);
if I >= 0 then if I >= 0 then
Items[I].Assign(StoredValue); Items[I].Assign(AStoredValue);
end; end;
procedure TStoredValues.SaveValues; procedure TStoredValues.SaveValues;