mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-15 02:19:50 +02:00
IDE: Rename dialog CustomDefines -> DefinesGui.
git-svn-id: trunk@49156 -
This commit is contained in:
parent
ca887263f1
commit
0be07e4e24
4
.gitattributes
vendored
4
.gitattributes
vendored
@ -5603,10 +5603,10 @@ ide/componentpalette.pas svneol=native#text/pascal
|
|||||||
ide/compoptsmodes.pas svneol=native#text/plain
|
ide/compoptsmodes.pas svneol=native#text/plain
|
||||||
ide/comppagespopup.lfm svneol=native#text/plain
|
ide/comppagespopup.lfm svneol=native#text/plain
|
||||||
ide/comppagespopup.pas svneol=native#text/pascal
|
ide/comppagespopup.pas svneol=native#text/pascal
|
||||||
ide/customdefines.lfm svneol=native#text/plain
|
|
||||||
ide/customdefines.pas svneol=native#text/pascal
|
|
||||||
ide/customformeditor.pp svneol=native#text/pascal
|
ide/customformeditor.pp svneol=native#text/pascal
|
||||||
ide/debugmanager.pas svneol=native#text/pascal
|
ide/debugmanager.pas svneol=native#text/pascal
|
||||||
|
ide/definesgui.lfm svneol=native#text/plain
|
||||||
|
ide/definesgui.pas svneol=native#text/pascal
|
||||||
ide/dialogprocs.pas svneol=native#text/pascal
|
ide/dialogprocs.pas svneol=native#text/pascal
|
||||||
ide/diffdialog.lfm svneol=native#text/plain
|
ide/diffdialog.lfm svneol=native#text/plain
|
||||||
ide/diffdialog.pas svneol=native#text/pascal
|
ide/diffdialog.pas svneol=native#text/pascal
|
||||||
|
@ -1,35 +1,35 @@
|
|||||||
object CustomDefinesForm: TCustomDefinesForm
|
object DefinesGuiForm: TDefinesGuiForm
|
||||||
Left = 305
|
Left = 305
|
||||||
Height = 326
|
Height = 326
|
||||||
Top = 265
|
Top = 265
|
||||||
Width = 341
|
Width = 341
|
||||||
BorderIcons = [biSystemMenu]
|
BorderIcons = [biSystemMenu]
|
||||||
Caption = 'Conditional Defines'
|
Caption = 'Defines'
|
||||||
ClientHeight = 326
|
ClientHeight = 326
|
||||||
ClientWidth = 341
|
ClientWidth = 341
|
||||||
OnCreate = FormCreate
|
OnCreate = FormCreate
|
||||||
OnDestroy = FormDestroy
|
OnDestroy = FormDestroy
|
||||||
OnShow = FormShow
|
OnShow = FormShow
|
||||||
Position = poScreenCenter
|
Position = poScreenCenter
|
||||||
LCLVersion = '1.1'
|
LCLVersion = '1.5'
|
||||||
object gbNewDefine: TGroupBox
|
object gbNewDefine: TGroupBox
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 79
|
Height = 73
|
||||||
Top = 6
|
Top = 6
|
||||||
Width = 329
|
Width = 329
|
||||||
Align = alTop
|
Align = alTop
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
BorderSpacing.Around = 6
|
BorderSpacing.Around = 6
|
||||||
Caption = 'gbNewDefine'
|
Caption = 'gbNewDefine'
|
||||||
ClientHeight = 60
|
ClientHeight = 57
|
||||||
ClientWidth = 325
|
ClientWidth = 327
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
object AddBtn: TBitBtn
|
object AddBtn: TBitBtn
|
||||||
AnchorSideTop.Control = RemoveBtn
|
AnchorSideTop.Control = RemoveBtn
|
||||||
AnchorSideRight.Control = RemoveBtn
|
AnchorSideRight.Control = RemoveBtn
|
||||||
Left = 163
|
Left = 165
|
||||||
Height = 26
|
Height = 27
|
||||||
Top = 31
|
Top = 27
|
||||||
Width = 75
|
Width = 75
|
||||||
Anchors = [akTop, akRight]
|
Anchors = [akTop, akRight]
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
@ -46,9 +46,9 @@ object CustomDefinesForm: TCustomDefinesForm
|
|||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
AnchorSideRight.Control = edDefine
|
AnchorSideRight.Control = edDefine
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 244
|
Left = 246
|
||||||
Height = 26
|
Height = 27
|
||||||
Top = 31
|
Top = 27
|
||||||
Width = 75
|
Width = 75
|
||||||
Anchors = [akTop, akRight]
|
Anchors = [akTop, akRight]
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
@ -63,9 +63,9 @@ object CustomDefinesForm: TCustomDefinesForm
|
|||||||
object edDefine: TEdit
|
object edDefine: TEdit
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 25
|
Height = 21
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 313
|
Width = 315
|
||||||
Align = alTop
|
Align = alTop
|
||||||
BorderSpacing.Left = 6
|
BorderSpacing.Left = 6
|
||||||
BorderSpacing.Right = 6
|
BorderSpacing.Right = 6
|
||||||
@ -76,8 +76,8 @@ object CustomDefinesForm: TCustomDefinesForm
|
|||||||
end
|
end
|
||||||
object DefinesCheckList: TCheckListBox
|
object DefinesCheckList: TCheckListBox
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 182
|
Height = 187
|
||||||
Top = 91
|
Top = 85
|
||||||
Width = 329
|
Width = 329
|
||||||
Align = alClient
|
Align = alClient
|
||||||
Anchors = [akTop, akBottom]
|
Anchors = [akTop, akBottom]
|
||||||
@ -87,11 +87,12 @@ object CustomDefinesForm: TCustomDefinesForm
|
|||||||
OnDblClick = DefinesCheckListDblClick
|
OnDblClick = DefinesCheckListDblClick
|
||||||
OnKeyDown = DefinesCheckListKeyDown
|
OnKeyDown = DefinesCheckListKeyDown
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
|
TopIndex = -1
|
||||||
end
|
end
|
||||||
object ButtonPanel: TButtonPanel
|
object ButtonPanel: TButtonPanel
|
||||||
Left = 6
|
Left = 6
|
||||||
Height = 41
|
Height = 42
|
||||||
Top = 279
|
Top = 278
|
||||||
Width = 329
|
Width = 329
|
||||||
OKButton.Name = 'OKButton'
|
OKButton.Name = 'OKButton'
|
||||||
OKButton.DefaultCaption = True
|
OKButton.DefaultCaption = True
|
@ -18,7 +18,7 @@
|
|||||||
* *
|
* *
|
||||||
***************************************************************************
|
***************************************************************************
|
||||||
}
|
}
|
||||||
unit CustomDefines;
|
unit DefinesGui;
|
||||||
|
|
||||||
{$mode objfpc}{$H+}
|
{$mode objfpc}{$H+}
|
||||||
|
|
||||||
@ -30,9 +30,9 @@ uses
|
|||||||
|
|
||||||
type
|
type
|
||||||
|
|
||||||
{ TCustomDefinesForm }
|
{ TDefinesGuiForm }
|
||||||
|
|
||||||
TCustomDefinesForm = class(TForm)
|
TDefinesGuiForm = class(TForm)
|
||||||
AddBtn: TBitBtn;
|
AddBtn: TBitBtn;
|
||||||
ButtonPanel: TButtonPanel;
|
ButtonPanel: TButtonPanel;
|
||||||
DefinesCheckList: TCheckListBox;
|
DefinesCheckList: TCheckListBox;
|
||||||
@ -75,9 +75,9 @@ implementation
|
|||||||
|
|
||||||
{$R *.lfm}
|
{$R *.lfm}
|
||||||
|
|
||||||
{ TCustomDefinesForm }
|
{ TDefinesGuiForm }
|
||||||
|
|
||||||
procedure TCustomDefinesForm.FormCreate(Sender: TObject);
|
procedure TDefinesGuiForm.FormCreate(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
Caption := lisLazBuildDefines;
|
Caption := lisLazBuildDefines;
|
||||||
gbNewDefine.Caption := lisCodeToolsDefsDefine;
|
gbNewDefine.Caption := lisCodeToolsDefsDefine;
|
||||||
@ -87,36 +87,36 @@ begin
|
|||||||
RemoveBtn.LoadGlyphFromResourceName(HInstance, 'laz_delete');
|
RemoveBtn.LoadGlyphFromResourceName(HInstance, 'laz_delete');
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomDefinesForm.FormShow(Sender: TObject);
|
procedure TDefinesGuiForm.FormShow(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
DefinesCheckListClick(Nil);
|
DefinesCheckListClick(Nil);
|
||||||
ActiveControl := DefinesCheckList;
|
ActiveControl := DefinesCheckList;
|
||||||
IdleConnected := True;
|
IdleConnected := True;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomDefinesForm.FormDestroy(Sender: TObject);
|
procedure TDefinesGuiForm.FormDestroy(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomDefinesForm.AddBtnClick(Sender: TObject);
|
procedure TDefinesGuiForm.AddBtnClick(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
DefinesCheckList.Items.Add(edDefine.Text);
|
DefinesCheckList.Items.Add(edDefine.Text);
|
||||||
DefinesCheckList.ItemIndex := DefinesCheckList.Items.Count-1;
|
DefinesCheckList.ItemIndex := DefinesCheckList.Items.Count-1;
|
||||||
UpdateButtons;
|
UpdateButtons;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomDefinesForm.EditChange(Sender: TObject);
|
procedure TDefinesGuiForm.EditChange(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
UpdateButtons;
|
UpdateButtons;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomDefinesForm.HelpButtonClick(Sender: TObject);
|
procedure TDefinesGuiForm.HelpButtonClick(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
LazarusHelp.ShowHelpForIDEControl(Self);
|
LazarusHelp.ShowHelpForIDEControl(Self);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomDefinesForm.DefinesCheckListClick(Sender: TObject);
|
procedure TDefinesGuiForm.DefinesCheckListClick(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
with DefinesCheckList do
|
with DefinesCheckList do
|
||||||
if ItemIndex > -1 then
|
if ItemIndex > -1 then
|
||||||
@ -124,17 +124,17 @@ begin
|
|||||||
UpdateButtons;
|
UpdateButtons;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomDefinesForm.DefinesCheckListDblClick(Sender: TObject);
|
procedure TDefinesGuiForm.DefinesCheckListDblClick(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
//ModalResult := mrOK;
|
//ModalResult := mrOK;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomDefinesForm.RemoveBtnClick(Sender: TObject);
|
procedure TDefinesGuiForm.RemoveBtnClick(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
DeleteSelected;
|
DeleteSelected;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomDefinesForm.DefinesCheckListKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState);
|
procedure TDefinesGuiForm.DefinesCheckListKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState);
|
||||||
begin
|
begin
|
||||||
if Key = VK_DELETE then
|
if Key = VK_DELETE then
|
||||||
begin
|
begin
|
||||||
@ -143,7 +143,7 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomDefinesForm.SetIdleConnected(AValue: Boolean);
|
procedure TDefinesGuiForm.SetIdleConnected(AValue: Boolean);
|
||||||
begin
|
begin
|
||||||
if FIdleConnected = AValue then exit;
|
if FIdleConnected = AValue then exit;
|
||||||
FIdleConnected := AValue;
|
FIdleConnected := AValue;
|
||||||
@ -153,7 +153,7 @@ begin
|
|||||||
Application.RemoveOnIdleHandler(@OnIdle);
|
Application.RemoveOnIdleHandler(@OnIdle);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomDefinesForm.OnIdle(Sender: TObject; var Done: Boolean);
|
procedure TDefinesGuiForm.OnIdle(Sender: TObject; var Done: Boolean);
|
||||||
var
|
var
|
||||||
s: String;
|
s: String;
|
||||||
i, ListInd: Integer;
|
i, ListInd: Integer;
|
||||||
@ -181,7 +181,7 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomDefinesForm.DeleteSelected;
|
procedure TDefinesGuiForm.DeleteSelected;
|
||||||
var
|
var
|
||||||
i: Integer;
|
i: Integer;
|
||||||
begin
|
begin
|
||||||
@ -194,14 +194,14 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomDefinesForm.UpdateButtons;
|
procedure TDefinesGuiForm.UpdateButtons;
|
||||||
begin
|
begin
|
||||||
AddBtn.Enabled := (edDefine.Text <> '')
|
AddBtn.Enabled := (edDefine.Text <> '')
|
||||||
and (DefinesCheckList.Items.IndexOf(edDefine.Text) = -1);
|
and (DefinesCheckList.Items.IndexOf(edDefine.Text) = -1);
|
||||||
RemoveBtn.Enabled := DefinesCheckList.SelCount > 0;
|
RemoveBtn.Enabled := DefinesCheckList.SelCount > 0;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TCustomDefinesForm.ToCustomOptions(aStrings: TStrings): TModalResult;
|
function TDefinesGuiForm.ToCustomOptions(aStrings: TStrings): TModalResult;
|
||||||
var
|
var
|
||||||
i: Integer;
|
i: Integer;
|
||||||
begin
|
begin
|
@ -18,15 +18,15 @@ object CompilerOtherOptionsFrame: TCompilerOtherOptionsFrame
|
|||||||
Align = alClient
|
Align = alClient
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
Caption = 'grpConditionals'
|
Caption = 'grpConditionals'
|
||||||
ClientHeight = 141
|
ClientHeight = 150
|
||||||
ClientWidth = 517
|
ClientWidth = 519
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
inline CondSynEdit: TSynEdit
|
inline CondSynEdit: TSynEdit
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 113
|
Height = 133
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 517
|
Width = 519
|
||||||
Align = alClient
|
Align = alClient
|
||||||
Font.Height = 9
|
Font.Height = 9
|
||||||
Font.Name = '-misc-dejavu sans mono-*-*-*-*-*-*-*-*-*-*-iso10646-1'
|
Font.Name = '-misc-dejavu sans mono-*-*-*-*-*-*-*-*-*-*-iso10646-1'
|
||||||
@ -552,7 +552,6 @@ object CompilerOtherOptionsFrame: TCompilerOtherOptionsFrame
|
|||||||
'CondSynEdit'
|
'CondSynEdit'
|
||||||
)
|
)
|
||||||
VisibleSpecialChars = [vscSpace, vscTabAtLast]
|
VisibleSpecialChars = [vscSpace, vscTabAtLast]
|
||||||
SelectedColor.FrameEdges = sfeAround
|
|
||||||
SelectedColor.BackPriority = 50
|
SelectedColor.BackPriority = 50
|
||||||
SelectedColor.ForePriority = 50
|
SelectedColor.ForePriority = 50
|
||||||
SelectedColor.FramePriority = 50
|
SelectedColor.FramePriority = 50
|
||||||
@ -560,23 +559,17 @@ object CompilerOtherOptionsFrame: TCompilerOtherOptionsFrame
|
|||||||
SelectedColor.ItalicPriority = 50
|
SelectedColor.ItalicPriority = 50
|
||||||
SelectedColor.UnderlinePriority = 50
|
SelectedColor.UnderlinePriority = 50
|
||||||
SelectedColor.StrikeOutPriority = 50
|
SelectedColor.StrikeOutPriority = 50
|
||||||
IncrementColor.FrameEdges = sfeAround
|
|
||||||
HighlightAllColor.FrameEdges = sfeAround
|
|
||||||
BracketHighlightStyle = sbhsBoth
|
BracketHighlightStyle = sbhsBoth
|
||||||
BracketMatchColor.Background = clNone
|
BracketMatchColor.Background = clNone
|
||||||
BracketMatchColor.Foreground = clNone
|
BracketMatchColor.Foreground = clNone
|
||||||
BracketMatchColor.FrameEdges = sfeAround
|
|
||||||
BracketMatchColor.Style = [fsBold]
|
BracketMatchColor.Style = [fsBold]
|
||||||
FoldedCodeColor.Background = clNone
|
FoldedCodeColor.Background = clNone
|
||||||
FoldedCodeColor.Foreground = clGray
|
FoldedCodeColor.Foreground = clGray
|
||||||
FoldedCodeColor.FrameColor = clGray
|
FoldedCodeColor.FrameColor = clGray
|
||||||
FoldedCodeColor.FrameEdges = sfeAround
|
|
||||||
MouseLinkColor.Background = clNone
|
MouseLinkColor.Background = clNone
|
||||||
MouseLinkColor.Foreground = clBlue
|
MouseLinkColor.Foreground = clBlue
|
||||||
MouseLinkColor.FrameEdges = sfeAround
|
|
||||||
LineHighlightColor.Background = clNone
|
LineHighlightColor.Background = clNone
|
||||||
LineHighlightColor.Foreground = clNone
|
LineHighlightColor.Foreground = clNone
|
||||||
LineHighlightColor.FrameEdges = sfeAround
|
|
||||||
OnChange = CondSynEditChange
|
OnChange = CondSynEditChange
|
||||||
OnProcessUserCommand = CondSynEditProcessUserCommand
|
OnProcessUserCommand = CondSynEditProcessUserCommand
|
||||||
inline SynLeftGutterPartList1: TSynGutterPartList
|
inline SynLeftGutterPartList1: TSynGutterPartList
|
||||||
@ -589,7 +582,6 @@ object CompilerOtherOptionsFrame: TCompilerOtherOptionsFrame
|
|||||||
MouseActions = <>
|
MouseActions = <>
|
||||||
MarkupInfo.Background = clBtnFace
|
MarkupInfo.Background = clBtnFace
|
||||||
MarkupInfo.Foreground = clNone
|
MarkupInfo.Foreground = clNone
|
||||||
MarkupInfo.FrameEdges = sfeAround
|
|
||||||
DigitCount = 2
|
DigitCount = 2
|
||||||
ShowOnlyLineNumbersMultiplesOf = 1
|
ShowOnlyLineNumbersMultiplesOf = 1
|
||||||
ZeroStart = False
|
ZeroStart = False
|
||||||
@ -606,7 +598,6 @@ object CompilerOtherOptionsFrame: TCompilerOtherOptionsFrame
|
|||||||
MouseActions = <>
|
MouseActions = <>
|
||||||
MarkupInfo.Background = clWhite
|
MarkupInfo.Background = clWhite
|
||||||
MarkupInfo.Foreground = clGray
|
MarkupInfo.Foreground = clGray
|
||||||
MarkupInfo.FrameEdges = sfeAround
|
|
||||||
end
|
end
|
||||||
object SynGutterCodeFolding1: TSynGutterCodeFolding
|
object SynGutterCodeFolding1: TSynGutterCodeFolding
|
||||||
MouseActions = <
|
MouseActions = <
|
||||||
@ -637,7 +628,6 @@ object CompilerOtherOptionsFrame: TCompilerOtherOptionsFrame
|
|||||||
end>
|
end>
|
||||||
MarkupInfo.Background = clNone
|
MarkupInfo.Background = clNone
|
||||||
MarkupInfo.Foreground = clGray
|
MarkupInfo.Foreground = clGray
|
||||||
MarkupInfo.FrameEdges = sfeAround
|
|
||||||
MouseActionsExpanded = <
|
MouseActionsExpanded = <
|
||||||
item
|
item
|
||||||
ClickCount = ccAny
|
ClickCount = ccAny
|
||||||
@ -664,9 +654,9 @@ object CompilerOtherOptionsFrame: TCompilerOtherOptionsFrame
|
|||||||
end
|
end
|
||||||
object CondStatusbar: TStatusBar
|
object CondStatusbar: TStatusBar
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 28
|
Height = 17
|
||||||
Top = 113
|
Top = 133
|
||||||
Width = 517
|
Width = 519
|
||||||
Panels = <
|
Panels = <
|
||||||
item
|
item
|
||||||
Width = 80
|
Width = 80
|
||||||
@ -697,17 +687,17 @@ object CompilerOtherOptionsFrame: TCompilerOtherOptionsFrame
|
|||||||
Width = 521
|
Width = 521
|
||||||
Align = alBottom
|
Align = alBottom
|
||||||
Caption = 'grpCustomOptions'
|
Caption = 'grpCustomOptions'
|
||||||
ClientHeight = 177
|
ClientHeight = 186
|
||||||
ClientWidth = 517
|
ClientWidth = 519
|
||||||
TabOrder = 2
|
TabOrder = 2
|
||||||
object memoCustomOptions: TMemo
|
object memoCustomOptions: TMemo
|
||||||
AnchorSideLeft.Control = grpCustomOptions
|
AnchorSideLeft.Control = grpCustomOptions
|
||||||
AnchorSideBottom.Control = grpCustomOptions
|
AnchorSideBottom.Control = grpCustomOptions
|
||||||
AnchorSideBottom.Side = asrBottom
|
AnchorSideBottom.Side = asrBottom
|
||||||
Left = 0
|
Left = 0
|
||||||
Height = 173
|
Height = 182
|
||||||
Top = 4
|
Top = 4
|
||||||
Width = 361
|
Width = 363
|
||||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||||
BorderSpacing.Right = 6
|
BorderSpacing.Right = 6
|
||||||
ParentShowHint = False
|
ParentShowHint = False
|
||||||
@ -721,8 +711,8 @@ object CompilerOtherOptionsFrame: TCompilerOtherOptionsFrame
|
|||||||
AnchorSideLeft.Side = asrBottom
|
AnchorSideLeft.Side = asrBottom
|
||||||
AnchorSideRight.Control = btnDefines
|
AnchorSideRight.Control = btnDefines
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 367
|
Left = 369
|
||||||
Height = 30
|
Height = 27
|
||||||
Top = 4
|
Top = 4
|
||||||
Width = 150
|
Width = 150
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
@ -736,9 +726,9 @@ object CompilerOtherOptionsFrame: TCompilerOtherOptionsFrame
|
|||||||
AnchorSideTop.Control = btnAllOptions
|
AnchorSideTop.Control = btnAllOptions
|
||||||
AnchorSideTop.Side = asrBottom
|
AnchorSideTop.Side = asrBottom
|
||||||
AnchorSideRight.Side = asrBottom
|
AnchorSideRight.Side = asrBottom
|
||||||
Left = 367
|
Left = 369
|
||||||
Height = 30
|
Height = 27
|
||||||
Top = 40
|
Top = 37
|
||||||
Width = 150
|
Width = 150
|
||||||
Anchors = [akTop, akLeft, akRight]
|
Anchors = [akTop, akLeft, akRight]
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
|
@ -32,7 +32,7 @@ uses
|
|||||||
Dialogs, StdCtrls, ComCtrls, ExtCtrls, Buttons, LCLType, LazUTF8,
|
Dialogs, StdCtrls, ComCtrls, ExtCtrls, Buttons, LCLType, LazUTF8,
|
||||||
CodeToolsCfgScript, KeywordFuncLists, LazarusIDEStrConsts,
|
CodeToolsCfgScript, KeywordFuncLists, LazarusIDEStrConsts,
|
||||||
IDEOptionsIntf, CompOptsIntf, IDECommands, LazIDEIntf, Project, PackageDefs,
|
IDEOptionsIntf, CompOptsIntf, IDECommands, LazIDEIntf, Project, PackageDefs,
|
||||||
CompilerOptions, Compiler, AllCompilerOptions, CustomDefines,
|
CompilerOptions, Compiler, AllCompilerOptions, DefinesGui,
|
||||||
EditorOptions, SynEdit, SynEditKeyCmds, SynCompletion, SourceSynEditor;
|
EditorOptions, SynEdit, SynEditKeyCmds, SynCompletion, SourceSynEditor;
|
||||||
|
|
||||||
type
|
type
|
||||||
@ -147,19 +147,19 @@ end;
|
|||||||
|
|
||||||
procedure TCompilerOtherOptionsFrame.btnDefinesClick(Sender: TObject);
|
procedure TCompilerOtherOptionsFrame.btnDefinesClick(Sender: TObject);
|
||||||
var
|
var
|
||||||
EditForm: TCustomDefinesForm;
|
EditForm: TDefinesGuiForm;
|
||||||
begin
|
begin
|
||||||
EditForm := TCustomDefinesForm.Create(Nil);
|
EditForm := TDefinesGuiForm.Create(Nil);
|
||||||
try
|
try
|
||||||
try
|
try
|
||||||
EditForm.OptionsReader := FOptionsReader;
|
EditForm.OptionsReader := FOptionsReader;
|
||||||
EditForm.OptionsThread := FOptionsThread;
|
EditForm.OptionsThread := FOptionsThread;
|
||||||
EditForm.CustomOptions := memoCustomOptions.Lines;
|
EditForm.CustomOptions := memoCustomOptions.Lines;
|
||||||
EditForm.DefinesCheckList.Items.Assign(Project1.CustomDefines);
|
EditForm.DefinesCheckList.Items.Assign(Project1.OtherDefines);
|
||||||
EditForm.UseComments := FUseComments;
|
EditForm.UseComments := FUseComments;
|
||||||
if EditForm.ShowModal = mrOK then
|
if EditForm.ShowModal = mrOK then
|
||||||
begin
|
begin
|
||||||
Project1.CustomDefines.Assign(EditForm.DefinesCheckList.Items);
|
Project1.OtherDefines.Assign(EditForm.DefinesCheckList.Items);
|
||||||
// Synchronize with custom options memo
|
// Synchronize with custom options memo
|
||||||
EditForm.ToCustomOptions(memoCustomOptions.Lines);
|
EditForm.ToCustomOptions(memoCustomOptions.Lines);
|
||||||
memoCustomOptions.Invalidate;
|
memoCustomOptions.Invalidate;
|
||||||
|
@ -434,6 +434,7 @@
|
|||||||
<ComponentName Value="CompilerOtherOptionsFrame"/>
|
<ComponentName Value="CompilerOtherOptionsFrame"/>
|
||||||
<HasResources Value="True"/>
|
<HasResources Value="True"/>
|
||||||
<ResourceBaseClass Value="Frame"/>
|
<ResourceBaseClass Value="Frame"/>
|
||||||
|
<UnitName Value="Compiler_Other_Options"/>
|
||||||
</Unit59>
|
</Unit59>
|
||||||
<Unit60>
|
<Unit60>
|
||||||
<Filename Value="frames/compiler_compilation_options.pas"/>
|
<Filename Value="frames/compiler_compilation_options.pas"/>
|
||||||
@ -604,6 +605,7 @@
|
|||||||
<ComponentName Value="EditorOptionsForm"/>
|
<ComponentName Value="EditorOptionsForm"/>
|
||||||
<HasResources Value="True"/>
|
<HasResources Value="True"/>
|
||||||
<ResourceBaseClass Value="Form"/>
|
<ResourceBaseClass Value="Form"/>
|
||||||
|
<UnitName Value="EditorOptions"/>
|
||||||
</Unit88>
|
</Unit88>
|
||||||
<Unit89>
|
<Unit89>
|
||||||
<Filename Value="../packager/cleanpkgdeps.pas"/>
|
<Filename Value="../packager/cleanpkgdeps.pas"/>
|
||||||
@ -633,6 +635,7 @@
|
|||||||
<Unit93>
|
<Unit93>
|
||||||
<Filename Value="../converter/convertdelphi.pas"/>
|
<Filename Value="../converter/convertdelphi.pas"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
|
<UnitName Value="ConvertDelphi"/>
|
||||||
</Unit93>
|
</Unit93>
|
||||||
<Unit94>
|
<Unit94>
|
||||||
<Filename Value="etfpcmsgparser.pas"/>
|
<Filename Value="etfpcmsgparser.pas"/>
|
||||||
@ -778,6 +781,7 @@
|
|||||||
<Unit123>
|
<Unit123>
|
||||||
<Filename Value="lazarusidestrconsts.pas"/>
|
<Filename Value="lazarusidestrconsts.pas"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
|
<UnitName Value="LazarusIDEStrConsts"/>
|
||||||
</Unit123>
|
</Unit123>
|
||||||
<Unit124>
|
<Unit124>
|
||||||
<Filename Value="codetemplatesdlg.pas"/>
|
<Filename Value="codetemplatesdlg.pas"/>
|
||||||
@ -1269,66 +1273,69 @@
|
|||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
</Unit228>
|
</Unit228>
|
||||||
<Unit229>
|
<Unit229>
|
||||||
<Filename Value="customdefines.pas"/>
|
<Filename Value="examplemanager.pas"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<HasResources Value="True"/>
|
<HasResources Value="True"/>
|
||||||
</Unit229>
|
</Unit229>
|
||||||
<Unit230>
|
<Unit230>
|
||||||
<Filename Value="examplemanager.pas"/>
|
<Filename Value="formeditor.pp"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<HasResources Value="True"/>
|
|
||||||
</Unit230>
|
</Unit230>
|
||||||
<Unit231>
|
<Unit231>
|
||||||
<Filename Value="formeditor.pp"/>
|
<Filename Value="revision.inc"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
</Unit231>
|
</Unit231>
|
||||||
<Unit232>
|
<Unit232>
|
||||||
<Filename Value="revision.inc"/>
|
<Filename Value="objectlists.pas"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
</Unit232>
|
</Unit232>
|
||||||
<Unit233>
|
<Unit233>
|
||||||
<Filename Value="objectlists.pas"/>
|
|
||||||
<IsPartOfProject Value="True"/>
|
|
||||||
</Unit233>
|
|
||||||
<Unit234>
|
|
||||||
<Filename Value="mouseactiondialog.pas"/>
|
<Filename Value="mouseactiondialog.pas"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<HasResources Value="True"/>
|
<HasResources Value="True"/>
|
||||||
</Unit234>
|
</Unit233>
|
||||||
<Unit235>
|
<Unit234>
|
||||||
<Filename Value="basedebugmanager.pas"/>
|
<Filename Value="basedebugmanager.pas"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
</Unit235>
|
</Unit234>
|
||||||
<Unit236>
|
<Unit235>
|
||||||
<Filename Value="imexportcompileropts.pas"/>
|
<Filename Value="imexportcompileropts.pas"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ComponentName Value="ImExportCompOptsDlg"/>
|
<ComponentName Value="ImExportCompOptsDlg"/>
|
||||||
<HasResources Value="True"/>
|
<HasResources Value="True"/>
|
||||||
<ResourceBaseClass Value="Form"/>
|
<ResourceBaseClass Value="Form"/>
|
||||||
</Unit236>
|
</Unit235>
|
||||||
<Unit237>
|
<Unit236>
|
||||||
<Filename Value="initialsetupproc.pas"/>
|
<Filename Value="initialsetupproc.pas"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
</Unit237>
|
</Unit236>
|
||||||
<Unit238>
|
<Unit237>
|
||||||
<Filename Value="qfinitlocalvardlg.pas"/>
|
<Filename Value="qfinitlocalvardlg.pas"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ComponentName Value="QFInitLocalVarDialog"/>
|
<ComponentName Value="QFInitLocalVarDialog"/>
|
||||||
<HasResources Value="True"/>
|
<HasResources Value="True"/>
|
||||||
<ResourceBaseClass Value="Form"/>
|
<ResourceBaseClass Value="Form"/>
|
||||||
</Unit238>
|
</Unit237>
|
||||||
<Unit239>
|
<Unit238>
|
||||||
<Filename Value="../packager/interpkgconflictfiles.pas"/>
|
<Filename Value="../packager/interpkgconflictfiles.pas"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<HasResources Value="True"/>
|
<HasResources Value="True"/>
|
||||||
</Unit239>
|
</Unit238>
|
||||||
<Unit240>
|
<Unit239>
|
||||||
<Filename Value="encloseifdef.pas"/>
|
<Filename Value="encloseifdef.pas"/>
|
||||||
<IsPartOfProject Value="True"/>
|
<IsPartOfProject Value="True"/>
|
||||||
<ComponentName Value="EncloseIfDefForm"/>
|
<ComponentName Value="EncloseIfDefForm"/>
|
||||||
<HasResources Value="True"/>
|
<HasResources Value="True"/>
|
||||||
<ResourceBaseClass Value="Form"/>
|
<ResourceBaseClass Value="Form"/>
|
||||||
<UnitName Value="EncloseIfDef"/>
|
<UnitName Value="EncloseIfDef"/>
|
||||||
|
</Unit239>
|
||||||
|
<Unit240>
|
||||||
|
<Filename Value="definesgui.pas"/>
|
||||||
|
<IsPartOfProject Value="True"/>
|
||||||
|
<ComponentName Value="DefinesGuiForm"/>
|
||||||
|
<HasResources Value="True"/>
|
||||||
|
<ResourceBaseClass Value="Form"/>
|
||||||
|
<UnitName Value="DefinesGui"/>
|
||||||
</Unit240>
|
</Unit240>
|
||||||
</Units>
|
</Units>
|
||||||
</ProjectOptions>
|
</ProjectOptions>
|
||||||
|
@ -770,7 +770,7 @@ type
|
|||||||
FStateFlags: TLazProjectStateFlags;
|
FStateFlags: TLazProjectStateFlags;
|
||||||
FStorePathDelim: TPathDelimSwitch;
|
FStorePathDelim: TPathDelimSwitch;
|
||||||
FUnitList: TFPList; // list of _all_ units (TUnitInfo)
|
FUnitList: TFPList; // list of _all_ units (TUnitInfo)
|
||||||
FCustomDefines: TStrings; // list of user selectable defines for custom options
|
FOtherDefines: TStrings; // list of user selectable defines for custom options
|
||||||
FUpdateLock: integer;
|
FUpdateLock: integer;
|
||||||
FUseAsDefault: Boolean;
|
FUseAsDefault: Boolean;
|
||||||
// Variables used by ReadProject / WriteProject
|
// Variables used by ReadProject / WriteProject
|
||||||
@ -836,7 +836,7 @@ type
|
|||||||
// Methods for ReadProject
|
// Methods for ReadProject
|
||||||
function LoadOldProjectType(const Path: string): TOldProjectType;
|
function LoadOldProjectType(const Path: string): TOldProjectType;
|
||||||
procedure LoadFlags(const Path: string);
|
procedure LoadFlags(const Path: string);
|
||||||
procedure LoadCustomDefines(const Path: string);
|
procedure LoadOtherDefines(const Path: string);
|
||||||
procedure LoadSessionInfo(const Path: string; Merge: boolean);
|
procedure LoadSessionInfo(const Path: string; Merge: boolean);
|
||||||
procedure LoadFromLPI;
|
procedure LoadFromLPI;
|
||||||
procedure LoadFromSession;
|
procedure LoadFromSession;
|
||||||
@ -845,7 +845,7 @@ type
|
|||||||
// Methods for WriteProject
|
// Methods for WriteProject
|
||||||
procedure SaveFlags(const Path: string);
|
procedure SaveFlags(const Path: string);
|
||||||
procedure SaveUnits(const Path: string; SaveSession: boolean);
|
procedure SaveUnits(const Path: string; SaveSession: boolean);
|
||||||
procedure SaveCustomDefines(const Path: string);
|
procedure SaveOtherDefines(const Path: string);
|
||||||
procedure SaveSessionInfo(const Path: string);
|
procedure SaveSessionInfo(const Path: string);
|
||||||
procedure SaveToLPI;
|
procedure SaveToLPI;
|
||||||
procedure SaveToSession;
|
procedure SaveToSession;
|
||||||
@ -1111,7 +1111,7 @@ type
|
|||||||
property StorePathDelim: TPathDelimSwitch read FStorePathDelim write SetStorePathDelim;
|
property StorePathDelim: TPathDelimSwitch read FStorePathDelim write SetStorePathDelim;
|
||||||
property TargetFilename: string read GetTargetFilename write SetTargetFilename;
|
property TargetFilename: string read GetTargetFilename write SetTargetFilename;
|
||||||
property Units[Index: integer]: TUnitInfo read GetUnits;
|
property Units[Index: integer]: TUnitInfo read GetUnits;
|
||||||
property CustomDefines: TStrings read FCustomDefines;
|
property OtherDefines: TStrings read FOtherDefines;
|
||||||
property UpdateLock: integer read FUpdateLock;
|
property UpdateLock: integer read FUpdateLock;
|
||||||
property UseAsDefault: Boolean read FUseAsDefault write FUseAsDefault; // for dialog only (used to store options once)
|
property UseAsDefault: Boolean read FUseAsDefault write FUseAsDefault; // for dialog only (used to store options once)
|
||||||
end;
|
end;
|
||||||
@ -2680,7 +2680,7 @@ begin
|
|||||||
FRunParameters:=TRunParamsOptions.Create;
|
FRunParameters:=TRunParamsOptions.Create;
|
||||||
Title := '';
|
Title := '';
|
||||||
FUnitList := TFPList.Create; // list of TUnitInfo
|
FUnitList := TFPList.Create; // list of TUnitInfo
|
||||||
FCustomDefines := TStringList.Create;
|
FOtherDefines := TStringList.Create;
|
||||||
|
|
||||||
FResources := TProjectResources.Create(Self);
|
FResources := TProjectResources.Create(Self);
|
||||||
ProjResources.OnModified := @EmbeddedObjectModified;
|
ProjResources.OnModified := @EmbeddedObjectModified;
|
||||||
@ -2703,7 +2703,7 @@ begin
|
|||||||
FreeAndNil(FAllEditorsInfoList);
|
FreeAndNil(FAllEditorsInfoList);
|
||||||
FreeThenNil(FResources);
|
FreeThenNil(FResources);
|
||||||
FreeThenNil(FBookmarks);
|
FreeThenNil(FBookmarks);
|
||||||
FreeThenNil(FCustomDefines);
|
FreeThenNil(FOtherDefines);
|
||||||
FreeThenNil(FUnitList);
|
FreeThenNil(FUnitList);
|
||||||
FreeThenNil(FJumpHistory);
|
FreeThenNil(FJumpHistory);
|
||||||
FreeThenNil(FSourceDirectories);
|
FreeThenNil(FSourceDirectories);
|
||||||
@ -2764,17 +2764,20 @@ begin
|
|||||||
Flags:=Flags-[pfUseDefaultCompilerOptions];
|
Flags:=Flags-[pfUseDefaultCompilerOptions];
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TProject.LoadCustomDefines(const Path: string);
|
procedure TProject.LoadOtherDefines(const Path: string);
|
||||||
var
|
var
|
||||||
Cnt, i: Integer;
|
Cnt, i: Integer;
|
||||||
s: String;
|
SubPath, s: String;
|
||||||
begin
|
begin
|
||||||
Cnt := FXMLConfig.GetValue(Path+'CustomDefines/Count', 0);
|
SubPath := 'OtherDefines/';
|
||||||
|
if not FXMLConfig.HasPath(Path+SubPath, False) then
|
||||||
|
SubPath := 'CustomDefines/'; // Load from the old path name.
|
||||||
|
Cnt := FXMLConfig.GetValue(Path+SubPath+'Count', 0);
|
||||||
for i := 0 to Cnt-1 do
|
for i := 0 to Cnt-1 do
|
||||||
begin
|
begin
|
||||||
s := FXMLConfig.GetValue(Path+'CustomDefines/Define'+IntToStr(i)+'/Value', '');
|
s := FXMLConfig.GetValue(Path+SubPath+'Define'+IntToStr(i)+'/Value', '');
|
||||||
if s <> '' then
|
if s <> '' then
|
||||||
CustomDefines.Add(s);
|
OtherDefines.Add(s);
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
@ -2894,8 +2897,8 @@ begin
|
|||||||
RunParameterOptions.Load(FXMLConfig,Path,fPathDelimChanged);
|
RunParameterOptions.Load(FXMLConfig,Path,fPathDelimChanged);
|
||||||
// load the Publish Options
|
// load the Publish Options
|
||||||
PublishOptions.LoadFromXMLConfig(FXMLConfig,Path+'PublishOptions/',fPathDelimChanged);
|
PublishOptions.LoadFromXMLConfig(FXMLConfig,Path+'PublishOptions/',fPathDelimChanged);
|
||||||
// load custom defines
|
// load defines used for custom options
|
||||||
LoadCustomDefines(Path);
|
LoadOtherDefines(Path);
|
||||||
// load session info
|
// load session info
|
||||||
LoadSessionInfo(Path,false);
|
LoadSessionInfo(Path,false);
|
||||||
// call hooks to read their info (e.g. DebugBoss)
|
// call hooks to read their info (e.g. DebugBoss)
|
||||||
@ -2919,8 +2922,8 @@ begin
|
|||||||
// load MacroValues and compiler options
|
// load MacroValues and compiler options
|
||||||
BuildModes.LoadSessionFromXMLConfig(FXMLConfig, Path, FLoadParts);
|
BuildModes.LoadSessionFromXMLConfig(FXMLConfig, Path, FLoadParts);
|
||||||
|
|
||||||
// load custom defines
|
// load defines used for custom options
|
||||||
LoadCustomDefines(Path);
|
LoadOtherDefines(Path);
|
||||||
// load session info
|
// load session info
|
||||||
LoadSessionInfo(Path,true);
|
LoadSessionInfo(Path,true);
|
||||||
|
|
||||||
@ -3096,15 +3099,14 @@ begin
|
|||||||
FXMLConfig.SetDeleteValue(Path+'Units/Count',SaveUnitCount,0);
|
FXMLConfig.SetDeleteValue(Path+'Units/Count',SaveUnitCount,0);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TProject.SaveCustomDefines(const Path: string);
|
procedure TProject.SaveOtherDefines(const Path: string);
|
||||||
var
|
var
|
||||||
i: integer;
|
i: integer;
|
||||||
begin
|
begin
|
||||||
for i:=0 to FCustomDefines.Count-1 do begin
|
for i:=0 to FOtherDefines.Count-1 do
|
||||||
FXMLConfig.SetDeleteValue(Path+'CustomDefines/Define'+IntToStr(i)+'/Value',
|
FXMLConfig.SetDeleteValue(Path+'OtherDefines/Define'+IntToStr(i)+'/Value',
|
||||||
FCustomDefines[i],'');
|
FOtherDefines[i],'');
|
||||||
end;
|
FXMLConfig.SetDeleteValue(Path+'OtherDefines/Count',FOtherDefines.Count,0);
|
||||||
FXMLConfig.SetDeleteValue(Path+'CustomDefines/Count',FCustomDefines.Count,0);
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TProject.SaveSessionInfo(const Path: string);
|
procedure TProject.SaveSessionInfo(const Path: string);
|
||||||
@ -3185,8 +3187,8 @@ begin
|
|||||||
SaveUnits(Path,FSaveSessionInLPI);
|
SaveUnits(Path,FSaveSessionInLPI);
|
||||||
|
|
||||||
if FSaveSessionInLPI then begin
|
if FSaveSessionInLPI then begin
|
||||||
// save custom defines
|
// save defines used for custom options
|
||||||
SaveCustomDefines(Path);
|
SaveOtherDefines(Path);
|
||||||
// save session info
|
// save session info
|
||||||
SaveSessionInfo(Path);
|
SaveSessionInfo(Path);
|
||||||
end;
|
end;
|
||||||
@ -3221,8 +3223,8 @@ begin
|
|||||||
BuildModes.SaveSessionData(Path);
|
BuildModes.SaveSessionData(Path);
|
||||||
// save all units
|
// save all units
|
||||||
SaveUnits(Path,true);
|
SaveUnits(Path,true);
|
||||||
// save custom defines
|
// save defines used for custom options
|
||||||
SaveCustomDefines(Path);
|
SaveOtherDefines(Path);
|
||||||
// save session info
|
// save session info
|
||||||
SaveSessionInfo(Path);
|
SaveSessionInfo(Path);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user