⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 calcdelphi.pas

📁 vVC显示图片 VC显示图片 VC显示图片 VC显示图片 VC显示图片
💻 PAS
字号:
unit CalcDelphi;

interface

uses
  Windows, Messages, SysUtils, Classes, Graphics,
  Calculate;

type
  TCalcDelphi = class(TCalculate)
  private

  public
    constructor Create; 
    destructor Destroy; override;

    function GetFileList(List: TStrings): boolean; override;
  end;

implementation

constructor TCalcDelphi.Create;
begin
  inherited Create;
end;

destructor TCalcDelphi.Destroy;
begin
  inherited Destroy;
end;

function TCalcDelphi.GetFileList(List: TStrings): boolean;
var
  Lines: TStrings;
  i, j: integer;
  LineStr, FileName: string;
  Path: string;
begin
  Result := true;
  Path := ExtractFilePath(FPrjFilename);
  List.Clear;
  List.Add(FPrjFileName);
  Lines := TStringList.Create;
  try
    Lines.LoadFromFile(FPrjFileName);
    for i := 0 to Lines.Count - 1 do
    begin
      LineStr := UpperCase(Lines[i]);
      j := Pos(' IN ''', LineStr);
      if j > 0 then
      begin
        FileName := '';
        j := j + 5;
        if j <= Length(LineStr) then
        begin
          FileName := Path;
          while LineStr[j] <> '''' do
          begin
            FileName := FileName + Lines[i][j];
            Inc(j);
            if j > Length(LineStr) then break;
          end;
        end;
        if FileName <> '' then
          List.Add(FileName);
      end;
    end;
  except
    Result := false;
  end;
  Lines.Free;
end;

end.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -