mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-11 05:07:56 +02:00
IDE: clean up old external tools
git-svn-id: trunk@45943 -
This commit is contained in:
parent
abaf3fb59c
commit
d95954ac0b
2
.gitattributes
vendored
2
.gitattributes
vendored
@ -5427,8 +5427,6 @@ ide/include/unix/lazbaseconf.inc svneol=native#text/pascal
|
||||
ide/include/win/lazbaseconf.inc svneol=native#text/plain
|
||||
ide/include/win32/lazconf.inc svneol=native#text/pascal
|
||||
ide/include/win64/lazconf.inc svneol=native#text/plain
|
||||
ide/infobuild.lfm svneol=native#text/plain
|
||||
ide/infobuild.pp svneol=native#text/plain
|
||||
ide/initialsetupdlgs.lfm svneol=native#text/plain
|
||||
ide/initialsetupdlgs.pas svneol=native#text/pascal
|
||||
ide/initialsetupproc.pas svneol=native#text/plain
|
||||
|
@ -34,9 +34,6 @@ uses
|
||||
Classes, SysUtils, FileUtil, Laz2_XMLCfg, LazLogger, LazFileUtils, LazUTF8,
|
||||
LResources, Forms, Controls, Graphics, Dialogs, ExtCtrls, Buttons, StdCtrls,
|
||||
ComCtrls, Contnrs, ButtonPanel, DefineTemplates, IDEImagesIntf,
|
||||
{$IFDEF EnableOldExtTools}
|
||||
IDEMsgIntf,
|
||||
{$ENDIF}
|
||||
IDEHelpIntf, IDEDialogs, LazarusIDEStrConsts, LazConf, InterfaceBase,
|
||||
IDEProcs, TransferMacros, CompilerOptions, EnvironmentOpts;
|
||||
|
||||
|
@ -301,11 +301,7 @@ var
|
||||
TestDir: String;
|
||||
BogusFilename: String;
|
||||
CmdLineParams: String;
|
||||
{$IFNDEF EnableOldExtTools}
|
||||
CompileTool: TAbstractExternalTool;
|
||||
{$ELSE}
|
||||
CompileTool: TExternalToolOptions;
|
||||
{$ENDIF}
|
||||
begin
|
||||
// compile bogus file
|
||||
FTest:=cotCompileBogusFiles;
|
||||
@ -334,7 +330,6 @@ begin
|
||||
CmdLineParams:=Options.MakeOptionsString(BogusFilename,
|
||||
[ccloAddVerboseAll,ccloDoNotAppendOutFileOption,ccloAbsolutePaths])
|
||||
+' '+BogusFilename;
|
||||
{$IFNDEF EnableOldExtTools}
|
||||
CompileTool:=ExternalToolList.Add(dlgCCOTestToolCompilingEmptyFile);
|
||||
CompileTool.Reference(Self,ClassName);
|
||||
try
|
||||
@ -348,18 +343,6 @@ begin
|
||||
finally
|
||||
CompileTool.Release(Self);
|
||||
end;
|
||||
{$ELSE}
|
||||
CompileTool:=TExternalToolOptions.Create;
|
||||
CompileTool.Title:=dlgCCOTestToolCompilingEmptyFile;
|
||||
CompileTool.ScanOutputForFPCMessages:=true;
|
||||
CompileTool.ScanOutputForMakeMessages:=true;
|
||||
CompileTool.WorkingDirectory:=TestDir;
|
||||
CompileTool.Filename:=CompilerFilename;
|
||||
CompileTool.CmdLineParams:=CmdLineParams;
|
||||
TestMemo.Lines.Text:=CompileTool.Filename+' '+CompileTool.CmdLineParams;
|
||||
Result:=EnvironmentOptions.ExternalTools.Run(CompileTool,MacroList,false);
|
||||
FreeThenNil(CompileTool);
|
||||
{$ENDIF}
|
||||
finally
|
||||
DeleteFileUTF8(BogusFilename);
|
||||
end;
|
||||
@ -853,11 +836,7 @@ end;
|
||||
function TCheckCompilerOptsDlg.DoTestAll: TModalResult;
|
||||
var
|
||||
CompilerFilename: String;
|
||||
{$IFNDEF EnableOldExtTools}
|
||||
CompileTool: TAbstractExternalTool;
|
||||
{$ELSE}
|
||||
CompileTool: TExternalToolOptions;
|
||||
{$ENDIF}
|
||||
CompilerFiles: TStrings;
|
||||
FPCCfgUnitPath: string;
|
||||
TargetUnitPath: String;
|
||||
|
@ -49,8 +49,6 @@ unit etQuickFixes;
|
||||
|
||||
{$mode objfpc}{$H+}
|
||||
|
||||
{$IFDEF EnableOldExtTools}{$Error Wrong}{$ENDIF}
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
|
@ -27,8 +27,6 @@ unit ExtTools;
|
||||
|
||||
{$mode objfpc}{$H+}
|
||||
|
||||
{$IFDEF EnableOldExtTools}{$Error Wrong}{$ENDIF}
|
||||
|
||||
{off $DEFINE VerboseExtToolErrors}
|
||||
{off $DEFINE VerboseExtToolAddOutputLines}
|
||||
{off $DEFINE VerboseExtToolThread}
|
||||
|
@ -1,441 +0,0 @@
|
||||
object CompileInfoDlg: TCompileInfoDlg
|
||||
Left = 445
|
||||
Height = 199
|
||||
Top = 464
|
||||
Width = 386
|
||||
ActiveControl = PnlTitle
|
||||
AutoSize = True
|
||||
BorderIcons = []
|
||||
BorderStyle = bsDialog
|
||||
Caption = 'Compile project'
|
||||
ChildSizing.LeftRightSpacing = 6
|
||||
ChildSizing.TopBottomSpacing = 6
|
||||
ChildSizing.HorizontalSpacing = 6
|
||||
ChildSizing.VerticalSpacing = 6
|
||||
ClientHeight = 199
|
||||
ClientWidth = 386
|
||||
FormStyle = fsStayOnTop
|
||||
KeyPreview = True
|
||||
OnClose = FormClose
|
||||
OnCreate = FormCreate
|
||||
OnKeyDown = FormKeyDown
|
||||
Position = poScreenCenter
|
||||
LCLVersion = '0.9.31'
|
||||
object PnlTitle: TPanel
|
||||
AnchorSideLeft.Control = Owner
|
||||
AnchorSideTop.Control = Owner
|
||||
Left = 6
|
||||
Height = 26
|
||||
Top = 6
|
||||
Width = 372
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
ClientHeight = 26
|
||||
ClientWidth = 372
|
||||
ParentFont = False
|
||||
TabOrder = 0
|
||||
object lbInfo: TLabel
|
||||
AnchorSideLeft.Control = PnlTitle
|
||||
AnchorSideTop.Control = PnlTitle
|
||||
AnchorSideRight.Control = PnlTitle
|
||||
AnchorSideRight.Side = asrBottom
|
||||
AnchorSideBottom.Control = PnlTitle
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 82
|
||||
Height = 18
|
||||
Top = 4
|
||||
Width = 284
|
||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||
AutoSize = False
|
||||
BorderSpacing.Left = 80
|
||||
BorderSpacing.Top = 2
|
||||
BorderSpacing.Right = 4
|
||||
BorderSpacing.Bottom = 2
|
||||
Layout = tlCenter
|
||||
ParentColor = False
|
||||
end
|
||||
object lbProject: TLabel
|
||||
AnchorSideLeft.Control = PnlTitle
|
||||
AnchorSideTop.Control = PnlTitle
|
||||
AnchorSideBottom.Control = PnlTitle
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 6
|
||||
Height = 18
|
||||
Top = 4
|
||||
Width = 54
|
||||
Anchors = [akTop, akLeft, akBottom]
|
||||
BorderSpacing.Left = 4
|
||||
BorderSpacing.Top = 2
|
||||
BorderSpacing.Bottom = 2
|
||||
Caption = 'Project:'
|
||||
Layout = tlCenter
|
||||
ParentColor = False
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
AnchorSideLeft.Control = Owner
|
||||
AnchorSideTop.Control = PnlTitle
|
||||
AnchorSideTop.Side = asrBottom
|
||||
AnchorSideRight.Control = PnlTitle
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 6
|
||||
Height = 26
|
||||
Top = 38
|
||||
Width = 372
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
ClientHeight = 26
|
||||
ClientWidth = 372
|
||||
ParentColor = False
|
||||
TabOrder = 1
|
||||
object PCurrentStatus: TLabel
|
||||
AnchorSideLeft.Control = Panel1
|
||||
AnchorSideTop.Control = Panel1
|
||||
AnchorSideRight.Control = Panel1
|
||||
AnchorSideRight.Side = asrBottom
|
||||
AnchorSideBottom.Control = Panel1
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 82
|
||||
Height = 18
|
||||
Top = 4
|
||||
Width = 284
|
||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||
AutoSize = False
|
||||
BorderSpacing.Left = 80
|
||||
BorderSpacing.Top = 2
|
||||
BorderSpacing.Right = 4
|
||||
BorderSpacing.Bottom = 2
|
||||
Color = clBtnFace
|
||||
Layout = tlCenter
|
||||
ParentColor = False
|
||||
Transparent = False
|
||||
end
|
||||
object lbCompiling: TLabel
|
||||
AnchorSideLeft.Control = Panel1
|
||||
AnchorSideTop.Control = Panel1
|
||||
AnchorSideBottom.Control = Panel1
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 6
|
||||
Height = 18
|
||||
Top = 4
|
||||
Width = 74
|
||||
Anchors = [akTop, akLeft, akBottom]
|
||||
BorderSpacing.Left = 4
|
||||
BorderSpacing.Top = 2
|
||||
BorderSpacing.Bottom = 2
|
||||
Caption = 'Compiling:'
|
||||
Layout = tlCenter
|
||||
ParentColor = False
|
||||
end
|
||||
end
|
||||
object pnlButton: TPanel
|
||||
AnchorSideLeft.Control = Owner
|
||||
AnchorSideTop.Control = cbAutoCloseOnSuccess
|
||||
AnchorSideTop.Side = asrBottom
|
||||
AnchorSideRight.Control = PnlTitle
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 6
|
||||
Height = 29
|
||||
Top = 150
|
||||
Width = 372
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
AutoSize = True
|
||||
BorderSpacing.Top = 6
|
||||
BorderSpacing.Bottom = 6
|
||||
BevelOuter = bvNone
|
||||
ClientHeight = 29
|
||||
ClientWidth = 372
|
||||
TabOrder = 2
|
||||
object BClose: TBitBtn
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 149
|
||||
Height = 29
|
||||
Top = 0
|
||||
Width = 75
|
||||
Anchors = [akTop]
|
||||
AutoSize = True
|
||||
Cancel = True
|
||||
Caption = '&OK'
|
||||
Constraints.MinHeight = 25
|
||||
Constraints.MinWidth = 75
|
||||
Default = True
|
||||
Kind = bkOK
|
||||
ModalResult = 1
|
||||
NumGlyphs = 0
|
||||
OnClick = BCloseClick
|
||||
TabOrder = 0
|
||||
end
|
||||
end
|
||||
object pnlInfo: TPanel
|
||||
AnchorSideLeft.Control = Owner
|
||||
AnchorSideTop.Control = Panel1
|
||||
AnchorSideTop.Side = asrBottom
|
||||
AnchorSideRight.Control = PnlTitle
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 6
|
||||
Height = 44
|
||||
Top = 70
|
||||
Width = 372
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
AutoSize = True
|
||||
BevelOuter = bvNone
|
||||
ChildSizing.EnlargeHorizontal = crsHomogenousChildResize
|
||||
ChildSizing.EnlargeVertical = crsHomogenousChildResize
|
||||
ChildSizing.Layout = cclLeftToRightThenTopToBottom
|
||||
ChildSizing.ControlsPerLine = 3
|
||||
ClientHeight = 44
|
||||
ClientWidth = 372
|
||||
TabOrder = 3
|
||||
object pnlLines: TPanel
|
||||
Left = 0
|
||||
Height = 44
|
||||
Top = 0
|
||||
Width = 107
|
||||
AutoSize = True
|
||||
BorderSpacing.Right = 4
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
ChildSizing.EnlargeHorizontal = crsHomogenousChildResize
|
||||
ChildSizing.EnlargeVertical = crsHomogenousChildResize
|
||||
ClientHeight = 44
|
||||
ClientWidth = 107
|
||||
TabOrder = 0
|
||||
object LNLines: TLabel
|
||||
Left = 46
|
||||
Height = 40
|
||||
Top = 2
|
||||
Width = 55
|
||||
Align = alClient
|
||||
Alignment = taRightJustify
|
||||
AutoSize = False
|
||||
BorderSpacing.Right = 4
|
||||
Caption = '0'
|
||||
Layout = tlCenter
|
||||
ParentColor = False
|
||||
end
|
||||
object LInfoLines: TLabel
|
||||
Left = 6
|
||||
Height = 40
|
||||
Top = 2
|
||||
Width = 40
|
||||
Align = alLeft
|
||||
BorderSpacing.Left = 4
|
||||
Caption = 'Lines:'
|
||||
Layout = tlCenter
|
||||
ParentColor = False
|
||||
end
|
||||
end
|
||||
object Panel3: TPanel
|
||||
Left = 111
|
||||
Height = 44
|
||||
Top = 0
|
||||
Width = 140
|
||||
AutoSize = True
|
||||
BorderSpacing.Left = 4
|
||||
BorderSpacing.Right = 4
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
ChildSizing.EnlargeHorizontal = crsHomogenousChildResize
|
||||
ChildSizing.EnlargeVertical = crsHomogenousChildResize
|
||||
ChildSizing.Layout = cclLeftToRightThenTopToBottom
|
||||
ChildSizing.ControlsPerLine = 1
|
||||
ClientHeight = 44
|
||||
ClientWidth = 140
|
||||
TabOrder = 1
|
||||
object pnlHints: TPanel
|
||||
Left = 2
|
||||
Height = 19
|
||||
Top = 4
|
||||
Width = 136
|
||||
AutoSize = True
|
||||
BorderSpacing.Left = 2
|
||||
BorderSpacing.Top = 4
|
||||
BorderSpacing.Right = 2
|
||||
BevelOuter = bvNone
|
||||
ClientHeight = 19
|
||||
ClientWidth = 136
|
||||
TabOrder = 0
|
||||
object LNHint: TLabel
|
||||
Left = 46
|
||||
Height = 19
|
||||
Top = 0
|
||||
Width = 86
|
||||
Align = alClient
|
||||
Alignment = taRightJustify
|
||||
AutoSize = False
|
||||
BorderSpacing.Left = 2
|
||||
BorderSpacing.Right = 4
|
||||
Caption = '0'
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
end
|
||||
object LInfoHint: TLabel
|
||||
Left = 4
|
||||
Height = 19
|
||||
Top = 0
|
||||
Width = 40
|
||||
Align = alLeft
|
||||
BorderSpacing.Left = 4
|
||||
Caption = 'Hints:'
|
||||
ParentColor = False
|
||||
end
|
||||
end
|
||||
object pnlWarnings: TPanel
|
||||
Left = 2
|
||||
Height = 19
|
||||
Top = 23
|
||||
Width = 136
|
||||
BorderSpacing.Left = 2
|
||||
BorderSpacing.Top = 2
|
||||
BorderSpacing.Right = 2
|
||||
BorderSpacing.Bottom = 2
|
||||
BevelOuter = bvNone
|
||||
ClientHeight = 19
|
||||
ClientWidth = 136
|
||||
TabOrder = 1
|
||||
object LInfoWarning: TLabel
|
||||
Left = 4
|
||||
Height = 19
|
||||
Top = 0
|
||||
Width = 69
|
||||
Align = alLeft
|
||||
BorderSpacing.Left = 4
|
||||
Caption = 'Warnings:'
|
||||
ParentColor = False
|
||||
end
|
||||
object LNWarning: TLabel
|
||||
Left = 75
|
||||
Height = 19
|
||||
Top = 0
|
||||
Width = 57
|
||||
Align = alClient
|
||||
Alignment = taRightJustify
|
||||
AutoSize = False
|
||||
BorderSpacing.Left = 2
|
||||
BorderSpacing.Right = 4
|
||||
Caption = '0'
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
end
|
||||
end
|
||||
end
|
||||
object pnlNotesErrors: TPanel
|
||||
Left = 255
|
||||
Height = 44
|
||||
Top = 0
|
||||
Width = 117
|
||||
AutoSize = True
|
||||
BorderSpacing.Left = 4
|
||||
BevelInner = bvRaised
|
||||
BevelOuter = bvLowered
|
||||
ChildSizing.EnlargeHorizontal = crsHomogenousChildResize
|
||||
ChildSizing.EnlargeVertical = crsHomogenousChildResize
|
||||
ChildSizing.Layout = cclTopToBottomThenLeftToRight
|
||||
ChildSizing.ControlsPerLine = 2
|
||||
ClientHeight = 44
|
||||
ClientWidth = 117
|
||||
TabOrder = 2
|
||||
object pnlNotes: TPanel
|
||||
Left = 2
|
||||
Height = 19
|
||||
Top = 4
|
||||
Width = 113
|
||||
AutoSize = True
|
||||
BorderSpacing.Left = 2
|
||||
BorderSpacing.Top = 4
|
||||
BorderSpacing.Right = 2
|
||||
BevelOuter = bvNone
|
||||
ClientHeight = 19
|
||||
ClientWidth = 113
|
||||
TabOrder = 0
|
||||
object LInfoNote: TLabel
|
||||
Left = 4
|
||||
Height = 19
|
||||
Top = 0
|
||||
Width = 46
|
||||
Align = alLeft
|
||||
BorderSpacing.Left = 4
|
||||
Caption = 'Notes:'
|
||||
ParentColor = False
|
||||
end
|
||||
object LNNote: TLabel
|
||||
Left = 52
|
||||
Height = 19
|
||||
Top = 0
|
||||
Width = 57
|
||||
Align = alClient
|
||||
Alignment = taRightJustify
|
||||
AutoSize = False
|
||||
BorderSpacing.Left = 2
|
||||
BorderSpacing.Right = 4
|
||||
Caption = '0'
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
end
|
||||
end
|
||||
object pnlErrors: TPanel
|
||||
Left = 2
|
||||
Height = 19
|
||||
Top = 23
|
||||
Width = 113
|
||||
AutoSize = True
|
||||
BorderSpacing.Left = 2
|
||||
BorderSpacing.Top = 2
|
||||
BorderSpacing.Right = 2
|
||||
BorderSpacing.Bottom = 2
|
||||
BevelOuter = bvNone
|
||||
ClientHeight = 19
|
||||
ClientWidth = 113
|
||||
TabOrder = 1
|
||||
object LInfoError: TLabel
|
||||
Left = 4
|
||||
Height = 19
|
||||
Top = 0
|
||||
Width = 47
|
||||
Align = alLeft
|
||||
BorderSpacing.Left = 4
|
||||
Caption = 'Errors:'
|
||||
ParentColor = False
|
||||
end
|
||||
object LNError: TLabel
|
||||
Left = 53
|
||||
Height = 19
|
||||
Top = 0
|
||||
Width = 56
|
||||
Align = alClient
|
||||
Alignment = taRightJustify
|
||||
AutoSize = False
|
||||
BorderSpacing.Left = 2
|
||||
BorderSpacing.Right = 4
|
||||
Caption = '0'
|
||||
ParentColor = False
|
||||
ParentFont = False
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
object cbAutoCloseOnSuccess: TCheckBox
|
||||
AnchorSideLeft.Control = Owner
|
||||
AnchorSideTop.Control = pnlInfo
|
||||
AnchorSideTop.Side = asrBottom
|
||||
AnchorSideRight.Control = PnlTitle
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 6
|
||||
Height = 24
|
||||
Top = 120
|
||||
Width = 372
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Top = 6
|
||||
BorderSpacing.Bottom = 6
|
||||
Caption = 'cbAutoCloseOnSuccess'
|
||||
TabOrder = 4
|
||||
end
|
||||
object tmrCloseForm: TTimer
|
||||
Enabled = False
|
||||
Interval = 2000
|
||||
OnTimer = tmrCloseFormTimer
|
||||
left = 275
|
||||
top = 150
|
||||
end
|
||||
end
|
329
ide/infobuild.pp
329
ide/infobuild.pp
@ -1,329 +0,0 @@
|
||||
{
|
||||
***************************************************************************
|
||||
* *
|
||||
* This source is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This code is distributed in the hope that it will be useful, but *
|
||||
* WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
|
||||
* General Public License for more details. *
|
||||
* *
|
||||
* A copy of the GNU General Public License is available on the World *
|
||||
* Wide Web at <http://www.gnu.org/copyleft/gpl.html>. You can also *
|
||||
* obtain it by writing to the Free Software Foundation, *
|
||||
* Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
* *
|
||||
***************************************************************************
|
||||
Dialog box used during compile or build
|
||||
|
||||
$Author$ Guadagnini David
|
||||
$Date$ Feb-28-2008
|
||||
$Revision$ 2.1
|
||||
}
|
||||
unit InfoBuild;
|
||||
|
||||
{$mode objfpc}{$H+}
|
||||
|
||||
{$IFNDEF EnableOldExtTools}{$ERROR Obsolete}{$ENDIF}
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Classes, SysUtils, Forms, Controls, Graphics, Dialogs, Buttons, LCLType,
|
||||
LCLProc, ExtCtrls, StdCtrls, LazIDEIntf, LazarusIDEStrConsts, FileCtrl,
|
||||
EnvironmentOpts;
|
||||
|
||||
type
|
||||
|
||||
{ TCompileInfoDlg }
|
||||
|
||||
TCompileInfoDlg = class (TForm)
|
||||
BClose: TBitBtn;
|
||||
cbAutoCloseOnSuccess: TCheckBox;
|
||||
lbProject: TLabel;
|
||||
lbInfo: TLabel;
|
||||
lbCompiling: TLabel;
|
||||
LInfoError: TLabel;
|
||||
LInfoHint: TLabel;
|
||||
LInfoLines: TLabel;
|
||||
LInfoNote: TLabel;
|
||||
LInfoWarning: TLabel;
|
||||
LNError: TLabel;
|
||||
LNHint: TLabel;
|
||||
LNLines: TLabel;
|
||||
LNNote: TLabel;
|
||||
LNWarning: TLabel;
|
||||
pnlLines: TPanel;
|
||||
Panel3: TPanel;
|
||||
pnlNotesErrors: TPanel;
|
||||
pnlHints: TPanel;
|
||||
pnlWarnings: TPanel;
|
||||
pnlNotes: TPanel;
|
||||
pnlErrors: TPanel;
|
||||
pnlInfo: TPanel;
|
||||
pnlButton: TPanel;
|
||||
PCurrentStatus : TLabel;
|
||||
Panel1 : TPanel;
|
||||
PnlTitle : TPanel;
|
||||
tmrCloseForm: TTimer;
|
||||
procedure BCloseClick(Sender: TObject);
|
||||
procedure FormClose(Sender: TObject; var {%H-}CloseAction: TCloseAction);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure FormKeyDown(Sender: TObject; var Key: Word; {%H-}Shift: TShiftState);
|
||||
procedure tmrCloseFormTimer(Sender: TObject);
|
||||
private
|
||||
NHints : Integer;
|
||||
NWarnings : Integer;
|
||||
NErrors : Integer;
|
||||
NNotes : Integer;
|
||||
NLines : Integer;
|
||||
ToAbort : Boolean;
|
||||
public
|
||||
procedure SetProjectName(const Sname: String);
|
||||
procedure SetStatus(const SStatus: String);
|
||||
procedure SetCanClose;
|
||||
procedure MakeBold;
|
||||
end;
|
||||
|
||||
{ TCompileProgress }
|
||||
|
||||
TCompileProgress = class
|
||||
class procedure CreateDialog(AOwner: TComponent; const AProject, AStatus: String);
|
||||
class procedure Close;
|
||||
class procedure Show;
|
||||
class procedure Hide;
|
||||
class procedure SetEnabled(AValue: Boolean);
|
||||
class procedure SetStatus(const AStatus: String);
|
||||
class procedure SetProject(const AProject: String);
|
||||
class procedure Ready(const AMessage: String = '');
|
||||
class procedure Ready(const AMessage: String; const AParams: array of const);
|
||||
end;
|
||||
TCompileProgressClass = class of TCompileProgress;
|
||||
|
||||
var
|
||||
CompileProgress: TCompileProgressClass = TCompileProgress;
|
||||
|
||||
implementation
|
||||
|
||||
{$R *.lfm}
|
||||
|
||||
var
|
||||
MCompileInfoDlg: TCompileInfoDlg;
|
||||
MCompileDialogEnabled: Boolean = False;
|
||||
|
||||
{ TCompileInfoDlg }
|
||||
|
||||
procedure TCompileInfoDlg.BCloseClick(Sender: TObject);
|
||||
begin
|
||||
if ToAbort then
|
||||
begin
|
||||
LazarusIDE.AbortBuild;
|
||||
SetStatus('Aborted...!');
|
||||
MakeBold;
|
||||
SetCanClose;
|
||||
end
|
||||
else
|
||||
Close;
|
||||
end;
|
||||
|
||||
procedure TCompileInfoDlg.FormClose(Sender: TObject; var CloseAction: TCloseAction);
|
||||
begin
|
||||
tmrCloseForm.Enabled := False;
|
||||
if EnvironmentOptions.AutoCloseCompileDialog <> cbAutoCloseOnSuccess.Checked then
|
||||
begin
|
||||
EnvironmentOptions.AutoCloseCompileDialog := cbAutoCloseOnSuccess.Checked;
|
||||
EnvironmentOptions.Save(False);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TCompileInfoDlg.FormCreate (Sender: TObject);
|
||||
begin
|
||||
NHints := 0;
|
||||
NWarnings := 0;
|
||||
NErrors := 0;
|
||||
NNotes := 0;
|
||||
NLines := 0;
|
||||
|
||||
lbProject.Caption := lisInfoBuildProject;
|
||||
lbCompiling.Caption := listInfoBuildCompiling;
|
||||
LInfoLines.Caption := lisInfoBuildLines;
|
||||
LInfoError.Caption := lisInfoBuildErrors;
|
||||
LInfoHint.Caption := lisInfoBuildHint;
|
||||
LInfoWarning.Caption := lisInfoBuildWarning;
|
||||
LInfoNote.Caption := lisInfoBuildNote;
|
||||
BClose.Kind := bkNoToAll;
|
||||
BClose.Caption := lisInfoBuildMakeAbort;
|
||||
Caption := lisInfoBuildCaption;
|
||||
cbAutoCloseOnSuccess.Caption := listInfoBuildAutoCloseOnSuccess;
|
||||
cbAutoCloseOnSuccess.Checked := EnvironmentOptions.AutoCloseCompileDialog;
|
||||
|
||||
ToAbort := True;
|
||||
BClose.LoadGlyphFromResourceName(hInstance, 'btn_ok');
|
||||
|
||||
SetProjectName('');
|
||||
SetStatus('');
|
||||
end;
|
||||
|
||||
procedure TCompileInfoDlg.FormKeyDown(Sender: TObject; var Key: Word;
|
||||
Shift: TShiftState);
|
||||
begin
|
||||
if Key = VK_ESCAPE then
|
||||
BCloseClick(Sender);
|
||||
end;
|
||||
|
||||
procedure TCompileInfoDlg.tmrCloseFormTimer(Sender: TObject);
|
||||
begin
|
||||
tmrCloseForm.Enabled := False;
|
||||
if Showing then Close;
|
||||
end;
|
||||
|
||||
procedure TCompileInfoDlg.SetProjectName(const Sname : String);
|
||||
begin
|
||||
lbInfo.Caption := MiniMizeName(Sname, lbInfo.Canvas, lbInfo.Width);
|
||||
end;
|
||||
|
||||
procedure TCompileInfoDlg.SetStatus(const SStatus : String);
|
||||
Var
|
||||
S : String;
|
||||
Ok : Boolean;
|
||||
NL : Integer;
|
||||
iLoc:Integer;
|
||||
begin
|
||||
|
||||
S := LowerCase(SStatus);
|
||||
|
||||
if (pos('warning(s)', s) > 0) or
|
||||
(pos('hint(s)', s) > 0) or
|
||||
(pos('note(s)', s) > 0) then exit;
|
||||
|
||||
Ok := True;
|
||||
|
||||
if (Pos('hint:', s) > 0) then
|
||||
begin
|
||||
Inc(NHints);
|
||||
LNHint.Caption := IntToStr(NHints);
|
||||
Ok := False;
|
||||
end;
|
||||
|
||||
If Pos('warning:', s) > 0 then
|
||||
begin
|
||||
Inc(NWarnings);
|
||||
LNWarning.Caption := IntToStr(NWarnings);
|
||||
Ok := False;
|
||||
end;
|
||||
|
||||
If (Pos('fatal:', s) > 0) Or (Pos('error:', s) > 0) then
|
||||
begin
|
||||
Inc(NErrors);
|
||||
LNError.Caption := IntToStr(NErrors);
|
||||
Ok := False;
|
||||
end;
|
||||
|
||||
If (Pos('note:', s) > 0) then
|
||||
begin
|
||||
Inc(NNotes);
|
||||
LNNote.Caption := IntToStr(NNotes);
|
||||
Ok := False;
|
||||
end;
|
||||
iLoc:=Pos('lines compiled', s);
|
||||
If (iLoc> 0) then begin
|
||||
s := copy(s, 1, iLoc-1);
|
||||
while copy(s, 1, 1) = ' ' do delete(s, 1, 1);
|
||||
while copy(s, length(s), 1) = ' ' do delete(s, length(s), 1);
|
||||
|
||||
NL := StrTointDef(S,0);
|
||||
NLines := NLines + NL;
|
||||
LNLines.Caption := AnsiToUTF8(FormatFloat('#,##0',NLines));
|
||||
Ok := false;
|
||||
end;
|
||||
If Ok then PCurrentStatus.Caption := SStatus;
|
||||
pnlInfo.Refresh;
|
||||
end;
|
||||
|
||||
procedure TCompileInfoDlg.SetCanClose;
|
||||
begin
|
||||
ToAbort := False;
|
||||
BClose.Kind := bkOk;
|
||||
BClose.Caption := lisClose;
|
||||
if cbAutoCloseOnSuccess.Checked and (NErrors = 0) then
|
||||
tmrCloseForm.Enabled := True;
|
||||
end;
|
||||
|
||||
procedure TCompileInfoDlg.MakeBold;
|
||||
begin
|
||||
PCurrentStatus.Font.Style:= PCurrentStatus.Font.Style + [fsBold];
|
||||
end;
|
||||
|
||||
|
||||
{ TCompileProgress }
|
||||
|
||||
class procedure TCompileProgress.Close;
|
||||
begin
|
||||
FreeAndNil(MCompileInfoDlg);
|
||||
end;
|
||||
|
||||
class procedure TCompileProgress.CreateDialog(AOwner: TComponent; const AProject, AStatus: String);
|
||||
begin
|
||||
Close;
|
||||
if MCompileDialogEnabled then
|
||||
begin
|
||||
MCompileInfoDlg := TCompileInfoDlg.Create(AOwner);
|
||||
MCompileInfoDlg.SetProjectName(AProject);
|
||||
MCompileInfoDlg.SetStatus(AStatus);
|
||||
// delay show til actual compile
|
||||
//MCompileInfoDlg.Show;
|
||||
end;
|
||||
end;
|
||||
|
||||
class procedure TCompileProgress.Hide;
|
||||
begin
|
||||
if MCompileInfoDlg = nil then Exit;
|
||||
MCompileInfoDlg.Hide;
|
||||
end;
|
||||
|
||||
class procedure TCompileProgress.SetEnabled(AValue: Boolean);
|
||||
begin
|
||||
MCompileDialogEnabled := AValue;
|
||||
end;
|
||||
|
||||
class procedure TCompileProgress.SetProject(const AProject: String);
|
||||
begin
|
||||
if MCompileInfoDlg = nil then Exit;
|
||||
MCompileInfoDlg.SetProjectName(AProject);
|
||||
end;
|
||||
|
||||
class procedure TCompileProgress.Ready(const AMessage: String);
|
||||
begin
|
||||
if MCompileInfoDlg = nil then Exit;
|
||||
if AMessage <> ''
|
||||
then begin
|
||||
MCompileInfoDlg.SetStatus(AMessage);
|
||||
MCompileInfoDlg.MakeBold;
|
||||
end;
|
||||
MCompileInfoDlg.SetCanClose;
|
||||
end;
|
||||
|
||||
class procedure TCompileProgress.Ready(const AMessage: String; const AParams: array of const);
|
||||
begin
|
||||
if MCompileInfoDlg = nil then Exit;
|
||||
Ready(Format(AMessage, AParams));
|
||||
end;
|
||||
|
||||
class procedure TCompileProgress.SetStatus(const AStatus: String);
|
||||
begin
|
||||
if MCompileInfoDlg = nil then Exit;
|
||||
MCompileInfoDlg.SetStatus(AStatus);
|
||||
end;
|
||||
|
||||
class procedure TCompileProgress.Show;
|
||||
begin
|
||||
if MCompileInfoDlg = nil then Exit;
|
||||
MCompileInfoDlg.Show;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
|
@ -38,13 +38,7 @@ uses
|
||||
MacroIntf, PackageIntf, IDEDialogs, ProjectIntf, IDEExternToolIntf,
|
||||
CompOptsIntf, LazIDEIntf,
|
||||
// IDE
|
||||
IDEProcs, InitialSetupProc,
|
||||
{$IFNDEF EnableOldExtTools}
|
||||
ExtTools,
|
||||
{$ELSE}
|
||||
OutputFilter,
|
||||
{$endif}
|
||||
CompilerOptions, ApplicationBundle,
|
||||
IDEProcs, InitialSetupProc, ExtTools, CompilerOptions, ApplicationBundle,
|
||||
TransferMacros, EnvironmentOpts, IDETranslations, LazarusIDEStrConsts,
|
||||
IDECmdLine, ExtToolDialog, MiscOptions, Project, LazConf, PackageDefs,
|
||||
PackageLinks, PackageSystem, BuildLazDialog, BuildProfileManager,
|
||||
@ -73,13 +67,6 @@ type
|
||||
fInitialized: boolean;
|
||||
fInitResult: boolean;
|
||||
fWidgetsetOverride: String;
|
||||
// external tools
|
||||
{$IFDEF EnableOldExtTools}
|
||||
procedure OnExtToolFreeOutputFilter({%H-}OutputFilter: TOutputFilter;
|
||||
ErrorOccurred: boolean);
|
||||
procedure OnExtToolNeedsOutputFilter(var OutputFilter: TOutputFilter;
|
||||
var {%H-}Abort: boolean);
|
||||
{$ENDIF}
|
||||
|
||||
// codetools
|
||||
procedure OnCodeBufferDecodeLoaded({%H-}Code: TCodeBuffer;
|
||||
@ -141,9 +128,6 @@ type
|
||||
function Init: boolean;
|
||||
procedure LoadEnvironmentOptions;
|
||||
procedure LoadMiscellaneousOptions;
|
||||
{$IFDEF EnableOldExtTools}
|
||||
procedure SetupOutputFilter;
|
||||
{$ENDIF}
|
||||
procedure SetupMacros;
|
||||
procedure SetupCodetools;
|
||||
procedure SetupPackageSystem;
|
||||
@ -161,9 +145,6 @@ type
|
||||
function ParseParameters: boolean;
|
||||
procedure WriteUsage;
|
||||
procedure Error(ErrorCode: Byte; const ErrorMsg: string);
|
||||
{$IFDEF EnableOldExtTools}
|
||||
function OnRunExternalTool(Tool: TIDEExternalToolOptions): TModalResult;
|
||||
{$ENDIF}
|
||||
|
||||
property AddPackage: boolean read FAddPackage write FAddPackage; // add package to installed pacakge in IDE (UserIDE)
|
||||
property BuildAll: boolean read FBuildAll write FBuildAll;// build all files of project/package
|
||||
@ -272,20 +253,6 @@ end;
|
||||
|
||||
{ TLazBuildApplication }
|
||||
|
||||
{$IFDEF EnableOldExtTools}
|
||||
procedure TLazBuildApplication.OnExtToolFreeOutputFilter(
|
||||
OutputFilter: TOutputFilter; ErrorOccurred: boolean);
|
||||
begin
|
||||
if ErrorOccurred then Error(ErrorBuildFailed,'tool reported error');
|
||||
end;
|
||||
|
||||
procedure TLazBuildApplication.OnExtToolNeedsOutputFilter(
|
||||
var OutputFilter: TOutputFilter; var Abort: boolean);
|
||||
begin
|
||||
OutputFilter:=TheOutputFilter;
|
||||
end;
|
||||
{$ENDIF}
|
||||
|
||||
procedure TLazBuildApplication.OnCodeBufferEncodeSaving(Code: TCodeBuffer;
|
||||
const Filename: string; var Source: string);
|
||||
begin
|
||||
@ -595,9 +562,6 @@ begin
|
||||
Builder:=TLazarusBuilder.Create;
|
||||
try
|
||||
Builder.ProfileChanged:=false;
|
||||
{$IFDEF EnableOldExtTools}
|
||||
Builder.ExternalTools:=EnvironmentOptions.ExternalTools;
|
||||
{$ENDIF}
|
||||
|
||||
if BuildLazProfiles.Current.IdeBuildMode=bmCleanAllBuild then begin
|
||||
Builder.PackageOptions:='';
|
||||
@ -1122,12 +1086,8 @@ begin
|
||||
SetupCodetools;
|
||||
SetupCompilerFilename;
|
||||
SetupPackageSystem;
|
||||
{$IFNDEF EnableOldExtTools}
|
||||
MainBuildBoss.SetupExternalTools;
|
||||
ExtToolConsole:=TLazExtToolConsole.Create(nil);
|
||||
{$ELSE}
|
||||
SetupOutputFilter;
|
||||
{$ENDIF}
|
||||
MainBuildBoss.SetupCompilerInterface;
|
||||
|
||||
StoreBaseSettings;
|
||||
@ -1159,10 +1119,6 @@ begin
|
||||
end;
|
||||
TranslateResourceStrings(EnvironmentOptions.GetParsedLazarusDirectory,
|
||||
EnvironmentOptions.LanguageID);
|
||||
{$IFDEF EnableOldExtTools}
|
||||
TExternalToolList(ExternalTools).OnNeedsOutputFilter:=@OnExtToolNeedsOutputFilter;
|
||||
TExternalToolList(ExternalTools).OnFreeOutputFilter:=@OnExtToolFreeOutputFilter;
|
||||
{$ENDIF}
|
||||
if CompilerOverride<>'' then
|
||||
CompilerFilename:=CompilerOverride;
|
||||
//debugln(['TLazBuildApplication.LoadEnvironmentOptions LazarusDirectory="',LazarusDirectory,'"']);
|
||||
@ -1186,14 +1142,6 @@ begin
|
||||
MiscellaneousOptions.Load;
|
||||
end;
|
||||
|
||||
{$IFDEF EnableOldExtTools}
|
||||
procedure TLazBuildApplication.SetupOutputFilter;
|
||||
begin
|
||||
TheOutputFilter:=TOutputFilter.Create;
|
||||
TheOutputFilter.OnGetIncludePath:=@CodeToolBoss.GetIncludePathForDirectory;
|
||||
end;
|
||||
{$ENDIF}
|
||||
|
||||
procedure TLazBuildApplication.SetupMacros;
|
||||
begin
|
||||
MainBuildBoss.SetupTransferMacros;
|
||||
@ -1403,10 +1351,6 @@ begin
|
||||
inherited Create(TheOwner);
|
||||
SetupDialogs;
|
||||
Files:=TStringList.Create;
|
||||
{$IFDEF EnableOldExtTools}
|
||||
TOutputFilterProcess:=TProcessUTF8;
|
||||
RunExternalTool := @OnRunExternalTool;
|
||||
{$ENDIF}
|
||||
end;
|
||||
|
||||
destructor TLazBuildApplication.Destroy;
|
||||
@ -1421,11 +1365,7 @@ begin
|
||||
|
||||
FreeThenNil(PkgLinks);
|
||||
FreeThenNil(TheCompiler);
|
||||
{$IFNDEF EnableOldExtTools}
|
||||
FreeAndNil(ExtToolConsole);
|
||||
{$ELSE}
|
||||
FreeThenNil(TheOutputFilter);
|
||||
{$ENDIF}
|
||||
FreeThenNil(GlobalMacroList);
|
||||
FreeThenNil(IDEMacros);
|
||||
FreeThenNil(MiscellaneousOptions);
|
||||
@ -1708,14 +1648,6 @@ begin
|
||||
Halt(ErrorCode);
|
||||
end;
|
||||
|
||||
{$IFDEF EnableOldExtTools}
|
||||
function TLazBuildApplication.OnRunExternalTool(Tool: TIDEExternalToolOptions
|
||||
): TModalResult;
|
||||
begin
|
||||
Result:=EnvironmentOptions.ExternalTools.Run(Tool,GlobalMacroList,false);
|
||||
end;
|
||||
{$ENDIF}
|
||||
|
||||
begin
|
||||
// When quick rebuilding lazbuild, FPC rebuilds only the lazbuild.lpr, so any
|
||||
// flag that should work with quick build must be set here.
|
||||
|
@ -46,11 +46,7 @@ uses
|
||||
InputHistory, CheckLFMDlg, LCLMemManager, CodeToolManager, CodeToolsStructs,
|
||||
ConvCodeTool, CodeCache, CodeTree, FindDeclarationTool, BasicCodeTools,
|
||||
SynEdit, UnitResources, IDEExternToolIntf, ExtToolDialog, PublishModule,
|
||||
{$IFNDEF EnableOldExtTools}
|
||||
etMessagesWnd;
|
||||
{$ELSE}
|
||||
MsgView;
|
||||
{$ENDIF}
|
||||
|
||||
type
|
||||
|
||||
@ -110,9 +106,6 @@ type
|
||||
FListForm: TGenericCheckListForm;
|
||||
FCheckingFilesOnDisk: boolean;
|
||||
FCheckFilesOnDiskNeeded: boolean;
|
||||
{$IFDEF EnableOldExtTools}
|
||||
function ExternalTools: TExternalToolList;
|
||||
{$ENDIF}
|
||||
procedure AskToSaveEditors(EditorList: TList);
|
||||
function AddPathToBuildModes(aPath, CurDirectory: string; IsIncludeFile: Boolean): Boolean;
|
||||
function CheckMainSrcLCLInterfaces(Silent: boolean): TModalResult;
|
||||
@ -1436,13 +1429,6 @@ begin
|
||||
inherited Destroy;
|
||||
end;
|
||||
|
||||
{$IFDEF EnableOldExtTools}
|
||||
function TLazSourceFileManager.ExternalTools: TExternalToolList;
|
||||
begin
|
||||
Result:=TExternalToolList(EnvironmentOptions.ExternalTools);
|
||||
end;
|
||||
{$ENDIF}
|
||||
|
||||
function TLazSourceFileManager.CheckMainSrcLCLInterfaces(Silent: boolean): TModalResult;
|
||||
var
|
||||
MainUnitInfo: TUnitInfo;
|
||||
@ -2010,11 +1996,7 @@ begin
|
||||
if EMacro <> nil then begin
|
||||
EMacro.SetFromSource(AEditor.SourceText);
|
||||
if EMacro.IsInvalid and (EMacro.ErrorMsg <> '') then
|
||||
{$IFNDEF EnableOldExtTools}
|
||||
IDEMessagesWindow.AddCustomMessage(mluError,EMacro.ErrorMsg);
|
||||
{$ELSE}
|
||||
MessagesView.AddMsg(EMacro.ErrorMsg, '', -1);
|
||||
{$ENDIF}
|
||||
end;
|
||||
MacroListViewer.UpdateDisplay;
|
||||
AnUnitInfo.ClearModifieds;
|
||||
@ -2888,17 +2870,11 @@ begin
|
||||
Tool.Title:=lisCommandAfterPublishingModule;
|
||||
Tool.WorkingDirectory:=DestDir;
|
||||
Tool.CmdLineParams:=CmdAfterParams;
|
||||
{$IFNDEF EnableOldExtTools}
|
||||
Tool.Executable:=CmdAfterExe;
|
||||
if RunExternalTool(Tool) then
|
||||
Result:=mrOk
|
||||
else
|
||||
Result:=mrCancel;
|
||||
{$ELSE}
|
||||
Tool.Filename:=CmdAfterExe;
|
||||
Result:=ExternalTools.Run(Tool,GlobalMacroList,false);
|
||||
if Result<>mrOk then exit;
|
||||
{$ENDIF}
|
||||
end else begin
|
||||
ShowErrorForCommandAfter;
|
||||
exit(mrCancel);
|
||||
|
@ -57,10 +57,7 @@ uses
|
||||
SynPluginTemplateEdit, SynPluginSyncroEdit, LazSynTextArea, SynEditHighlighter,
|
||||
SynEditHighlighterFoldBase, SynHighlighterPas, SynEditMarkupHighAll, SynEditKeyCmds,
|
||||
SynEditMarkupIfDef, SynEditMiscProcs,
|
||||
{$IFNDEF EnableOldExtTools}
|
||||
etSrcEditMarks,
|
||||
{$ENDIF}
|
||||
LazarusIDEStrConsts;
|
||||
etSrcEditMarks, LazarusIDEStrConsts;
|
||||
|
||||
type
|
||||
|
||||
@ -2012,16 +2009,12 @@ procedure TIDESynGutterLOvProviderIDEMarks.AdjustColorForMark(AMark: TSynEditMar
|
||||
var AColor: TColor; var APriority: Integer);
|
||||
var
|
||||
i: Integer;
|
||||
{$IFNDEF EnableOldExtTools}
|
||||
ETMark: TETMark;
|
||||
{$ENDIF}
|
||||
begin
|
||||
{$IFNDEF EnableOldExtTools}
|
||||
if (AMark is TETMark) then begin
|
||||
ETMark:=TETMark(AMark);
|
||||
AColor:=ETMark.SourceMarks.MarkStyles[ETMark.Urgency].Color;
|
||||
end else begin
|
||||
{$ENDIF}
|
||||
inc(APriority, 1);
|
||||
if not AMark.IsBookmark then begin
|
||||
//if (AMark.ImageList = SourceEditorMarks.ImgList) then begin
|
||||
@ -2046,9 +2039,7 @@ begin
|
||||
inc(APriority, 1);
|
||||
end;
|
||||
end;
|
||||
{$IFNDEF EnableOldExtTools}
|
||||
end;
|
||||
{$ENDIF}
|
||||
inherited AdjustColorForMark(AMark, AColor, APriority);
|
||||
end;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user