mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-24 09:19:14 +02:00
fixed 1.0.x compilation, removed double constants
git-svn-id: trunk@5294 -
This commit is contained in:
parent
51ee7853e0
commit
2f8ac652e3
@ -41,7 +41,13 @@ interface
|
|||||||
{$endif}
|
{$endif}
|
||||||
|
|
||||||
uses
|
uses
|
||||||
Classes, SysUtils, StdCtrls;
|
Classes, SysUtils,
|
||||||
|
{$ifdef VER1_0}
|
||||||
|
// fpc 1.0.x needs unit in which redefined unit originally is defined
|
||||||
|
// otherwise IE 55665566 occurs.
|
||||||
|
Controls,
|
||||||
|
{$endif}
|
||||||
|
StdCtrls;
|
||||||
|
|
||||||
Type
|
Type
|
||||||
|
|
||||||
@ -71,7 +77,7 @@ Type
|
|||||||
procedure UpdateFileList; virtual;
|
procedure UpdateFileList; virtual;
|
||||||
procedure Click; override;
|
procedure Click; override;
|
||||||
procedure Loaded; override;
|
procedure Loaded; override;
|
||||||
function IndexOfFile(const Filename: string): integer;
|
function IndexOfFile(const AFilename: string): integer;
|
||||||
public
|
public
|
||||||
constructor Create(AOwner: TComponent); override;
|
constructor Create(AOwner: TComponent); override;
|
||||||
destructor Destroy; override;
|
destructor Destroy; override;
|
||||||
@ -194,13 +200,6 @@ uses
|
|||||||
{$IFDEF Ver1_0}Linux{$ELSE}Unix,BaseUnix{$ENDIF};
|
{$IFDEF Ver1_0}Linux{$ELSE}Unix,BaseUnix{$ENDIF};
|
||||||
{$ENDIF}
|
{$ENDIF}
|
||||||
|
|
||||||
const
|
|
||||||
{$IFDEF Win32}
|
|
||||||
FindMask = '*.*';
|
|
||||||
{$ELSE}
|
|
||||||
FindMask = '*';
|
|
||||||
{$ENDIF}
|
|
||||||
|
|
||||||
var
|
var
|
||||||
UpChars: array[char] of char;
|
UpChars: array[char] of char;
|
||||||
|
|
||||||
@ -262,7 +261,7 @@ begin
|
|||||||
UpdateFileList;
|
UpdateFileList;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TCustomFileListBox.IndexOfFile(const Filename: string): integer;
|
function TCustomFileListBox.IndexOfFile(const AFilename: string): integer;
|
||||||
begin
|
begin
|
||||||
Result:=0;
|
Result:=0;
|
||||||
while (Result<Items.Count)
|
while (Result<Items.Count)
|
||||||
@ -287,7 +286,7 @@ end;
|
|||||||
|
|
||||||
function TCustomFileListBox.MaskIsStored: boolean;
|
function TCustomFileListBox.MaskIsStored: boolean;
|
||||||
begin
|
begin
|
||||||
Result:=(FMask<>FindMask);
|
Result:=(FMask<>GetAllFilesMask);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomFileListBox.SetDrive(const AValue: Char);
|
procedure TCustomFileListBox.SetDrive(const AValue: Char);
|
||||||
@ -330,7 +329,7 @@ var
|
|||||||
begin
|
begin
|
||||||
inherited Create(AOwner);
|
inherited Create(AOwner);
|
||||||
//Initializes DirectorySeparator and the Mask property.
|
//Initializes DirectorySeparator and the Mask property.
|
||||||
FMask := FindMask;
|
FMask := GetAllFilesMask;
|
||||||
//Initializes the FileType property.
|
//Initializes the FileType property.
|
||||||
FFileType := [ftNormal];
|
FFileType := [ftNormal];
|
||||||
//Initializes the Directory and Drive properties to the current directory.
|
//Initializes the Directory and Drive properties to the current directory.
|
||||||
@ -367,6 +366,9 @@ end.
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
|
Revision 1.23 2004/03/12 11:54:57 vincents
|
||||||
|
fixed 1.0.x compilation, removed double constants
|
||||||
|
|
||||||
Revision 1.22 2004/03/11 00:07:26 mattias
|
Revision 1.22 2004/03/11 00:07:26 mattias
|
||||||
added TFileListBox from Luis
|
added TFileListBox from Luis
|
||||||
|
|
||||||
|
@ -731,7 +731,7 @@ var
|
|||||||
begin
|
begin
|
||||||
Result:=false;
|
Result:=false;
|
||||||
CurSrcDir:=CleanAndExpandDirectory(DirectoryName);
|
CurSrcDir:=CleanAndExpandDirectory(DirectoryName);
|
||||||
if SysUtils.FindFirst(CurSrcDir+FindMask,faAnyFile,FileInfo)=0 then begin
|
if SysUtils.FindFirst(CurSrcDir+GetAllFilesMask,faAnyFile,FileInfo)=0 then begin
|
||||||
repeat
|
repeat
|
||||||
// check if special file
|
// check if special file
|
||||||
if (FileInfo.Name='.') or (FileInfo.Name='..') then continue;
|
if (FileInfo.Name='.') or (FileInfo.Name='..') then continue;
|
||||||
@ -927,6 +927,9 @@ end;
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
|
Revision 1.43 2004/03/12 11:54:57 vincents
|
||||||
|
fixed 1.0.x compilation, removed double constants
|
||||||
|
|
||||||
Revision 1.42 2004/03/11 00:07:26 mattias
|
Revision 1.42 2004/03/11 00:07:26 mattias
|
||||||
added TFileListBox from Luis
|
added TFileListBox from Luis
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user