mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-11-02 13:19:49 +01:00
Revert "ideintf: moved diff options back to ide"
This reverts commit 3cff2b6dc4.
This commit is contained in:
parent
3cff2b6dc4
commit
7a05fd5b85
@ -44,7 +44,7 @@ uses
|
||||
LazFileCache, LazFileUtils, LazLoggerBase, LazUTF8, AvgLvlTree, Laz2_XMLCfg,
|
||||
LazConfigStorage,
|
||||
// IdeConfig
|
||||
RecentListProcs, IdeXmlConfigProcs,
|
||||
LazConf, RecentListProcs, IdeXmlConfigProcs,
|
||||
// IdeIntf
|
||||
ProjectIntf, IDEDialogs;
|
||||
|
||||
@ -162,7 +162,8 @@ type
|
||||
FCleanOutputFileMask: string;
|
||||
FCleanSourcesFileMask: string;
|
||||
FFileDialogSettings: TFileDialogSettings;
|
||||
|
||||
FFilename: string;
|
||||
|
||||
// Find- and replace-history
|
||||
FFindHistory: TStringList;
|
||||
FFindInFilesSearchOptions: TLazFindInFileSearchOptions;
|
||||
@ -186,7 +187,6 @@ type
|
||||
|
||||
procedure SetFilename(const AValue: string);
|
||||
protected
|
||||
FFilename: string;
|
||||
procedure LoadSearchOptions(XMLConfig: TXMLConfig; const Path: string); virtual; abstract;
|
||||
procedure SaveSearchOptions(XMLConfig: TXMLConfig; const Path: string); virtual; abstract;
|
||||
public
|
||||
@ -296,6 +296,7 @@ implementation
|
||||
|
||||
|
||||
const
|
||||
DefaultHistoryFile = 'inputhistory.xml';
|
||||
InputHistoryVersion = 1;
|
||||
|
||||
function CompareIHIgnoreItems(Item1, Item2: Pointer): integer;
|
||||
@ -507,7 +508,12 @@ begin
|
||||
end;
|
||||
|
||||
procedure TInputHistories.SetLazarusDefaultFilename;
|
||||
var
|
||||
ConfFileName: string;
|
||||
begin
|
||||
ConfFileName:=AppendPathDelim(GetPrimaryConfigPath)+DefaultHistoryFile;
|
||||
CopySecondaryConfigFile(DefaultHistoryFile);
|
||||
FFilename:=ConfFilename;
|
||||
end;
|
||||
|
||||
procedure TInputHistories.Load;
|
||||
|
||||
@ -47,10 +47,9 @@ uses
|
||||
// SynEdit
|
||||
SynEdit, SynHighlighterDiff,
|
||||
// IdeIntf
|
||||
IDEWindowIntf, IDEHelpIntf, IDEImagesIntf,
|
||||
IDEWindowIntf, IDEHelpIntf, IDEImagesIntf, InputHistory,
|
||||
// IDE
|
||||
LazarusIDEStrConsts, EditorOptions, DiffPatch, SourceEditor,
|
||||
InputhistoryWithSearchOpt, EnvironmentOpts;
|
||||
LazarusIDEStrConsts, EditorOptions, DiffPatch, SourceEditor, EnvironmentOpts;
|
||||
|
||||
type
|
||||
|
||||
@ -441,7 +440,7 @@ begin
|
||||
|
||||
// get recent Text 2
|
||||
i:=0;
|
||||
LastText2Name:=InputHistoriesSO.DiffText2;
|
||||
LastText2Name:=InputHistories.DiffText2;
|
||||
if LastText2Name<>'' then
|
||||
i:=fAvailableFiles.IndexOfName(LastText2Name);
|
||||
if i<0 then i:=0;
|
||||
@ -449,7 +448,7 @@ begin
|
||||
fSelectedFile2.SetIndex(i);
|
||||
|
||||
// set recent options
|
||||
SetDiffOptions(InputHistoriesSO.DiffFlags);
|
||||
SetDiffOptions(InputHistories.DiffFlags);
|
||||
|
||||
// and action ...
|
||||
UpdateDiff;
|
||||
@ -482,13 +481,13 @@ end;
|
||||
|
||||
procedure TDiffDlg.SaveSettings;
|
||||
begin
|
||||
InputHistoriesSO.DiffFlags:=GetDiffOptions;
|
||||
InputHistories.DiffFlags:=GetDiffOptions;
|
||||
if (fSelectedFile2<>nil) and (fSelectedFile2.fFile<>nil) then begin
|
||||
InputHistoriesSO.DiffText2:=fSelectedFile2.fFile.Name;
|
||||
InputHistoriesSO.DiffText2OnlySelection:=Text2OnlySelectionCheckBox.Checked;
|
||||
InputHistories.DiffText2:=fSelectedFile2.fFile.Name;
|
||||
InputHistories.DiffText2OnlySelection:=Text2OnlySelectionCheckBox.Checked;
|
||||
end else begin
|
||||
InputHistoriesSO.DiffText2:='';
|
||||
InputHistoriesSO.DiffText2OnlySelection:=false;
|
||||
InputHistories.DiffText2:='';
|
||||
InputHistories.DiffText2OnlySelection:=false;
|
||||
end;
|
||||
IDEDialogLayoutList.SaveLayout(Self);
|
||||
end;
|
||||
|
||||
@ -30,11 +30,11 @@ interface
|
||||
|
||||
uses
|
||||
// LazUtils
|
||||
Laz2_XMLCfg, LazFileUtils,
|
||||
Laz2_XMLCfg,
|
||||
// SynEdit
|
||||
SynEditTypes,
|
||||
// IDE
|
||||
LazConf, InputHistory, DiffPatch;
|
||||
InputHistory, DiffPatch;
|
||||
|
||||
type
|
||||
|
||||
@ -65,8 +65,6 @@ type
|
||||
constructor Create;
|
||||
destructor Destroy; override;
|
||||
procedure Clear; override;
|
||||
procedure SetLazarusDefaultFilename; override;
|
||||
|
||||
property FindOptions[const ASelAvail: Boolean]: TSynSearchOptions read GetFindOptions write SetFindOptions;
|
||||
procedure LoadFromXMLConfig(XMLConfig: TXMLConfig; const Path: string); override;
|
||||
procedure SaveToXMLConfig(XMLConfig: TXMLConfig; const Path: string); override;
|
||||
@ -101,7 +99,6 @@ var
|
||||
implementation
|
||||
|
||||
const
|
||||
DefaultHistoryFile = 'inputhistory.xml';
|
||||
DefaultDiffFlags = [tdfIgnoreCase,tdfIgnoreEmptyLineChanges,
|
||||
tdfIgnoreLineEnds,tdfIgnoreTrailingSpaces];
|
||||
|
||||
@ -126,16 +123,6 @@ begin
|
||||
FDiffText2OnlySelection:=false;
|
||||
end;
|
||||
|
||||
procedure TInputHistoriesWithSearchOpt.SetLazarusDefaultFilename;
|
||||
var
|
||||
ConfFileName: string;
|
||||
begin
|
||||
ConfFileName:=AppendPathDelim(GetPrimaryConfigPath)+DefaultHistoryFile;
|
||||
CopySecondaryConfigFile(DefaultHistoryFile);
|
||||
FFilename:=ConfFilename;
|
||||
inherited SetLazarusDefaultFilename;
|
||||
end;
|
||||
|
||||
procedure TInputHistoriesWithSearchOpt.LoadFromXMLConfig(XMLConfig: TXMLConfig;
|
||||
const Path: string);
|
||||
var
|
||||
|
||||
Loading…
Reference in New Issue
Block a user