mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-11-23 16:59:29 +01:00
IDE: rename private method in TFileOpenClose: PrepareRevert -> CheckRevert.
git-svn-id: trunk@45682 -
This commit is contained in:
parent
f1c0a955c8
commit
f355ed2554
@ -81,7 +81,7 @@ type
|
|||||||
// Used by OpenEditorFile
|
// Used by OpenEditorFile
|
||||||
function OpenResource: TModalResult;
|
function OpenResource: TModalResult;
|
||||||
function PrepareInternalFile: TModalResult;
|
function PrepareInternalFile: TModalResult;
|
||||||
function PrepareRevert: TModalResult;
|
function CheckRevert: TModalResult;
|
||||||
public
|
public
|
||||||
constructor Create(AManager: TLazSourceFileManager);
|
constructor Create(AManager: TLazSourceFileManager);
|
||||||
destructor Destroy; override;
|
destructor Destroy; override;
|
||||||
@ -372,11 +372,11 @@ begin
|
|||||||
FNewUnitInfo.LoadedDesigner:=false;
|
FNewUnitInfo.LoadedDesigner:=false;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TFileOpenClose.PrepareRevert: TModalResult;
|
function TFileOpenClose.CheckRevert: TModalResult;
|
||||||
// revert: use source editor filename
|
// revert: use source editor filename
|
||||||
begin
|
begin
|
||||||
if (FPageIndex>=0) then begin
|
if (FPageIndex>=0) then begin
|
||||||
if FUseWindowID then // PrepareRevert must have a valid ID
|
if FUseWindowID then // Revert must have a valid ID
|
||||||
FWindowIndex := SourceEditorManager.IndexOfSourceWindowWithID(FWindowIndex);
|
FWindowIndex := SourceEditorManager.IndexOfSourceWindowWithID(FWindowIndex);
|
||||||
FUseWindowID := False;
|
FUseWindowID := False;
|
||||||
Assert((FWindowIndex >= 0) and (FWindowIndex < SourceEditorManager.SourceWindowCount), 'FWindowIndex for revert');
|
Assert((FWindowIndex >= 0) and (FWindowIndex < SourceEditorManager.SourceWindowCount), 'FWindowIndex for revert');
|
||||||
@ -472,7 +472,7 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
if (ofRevert in FFlags) then begin
|
if (ofRevert in FFlags) then begin
|
||||||
Result := PrepareRevert;
|
Result := CheckRevert;
|
||||||
if Result = mrIgnore then exit(mrOK);
|
if Result = mrIgnore then exit(mrOK);
|
||||||
Assert(Result = mrOK);
|
Assert(Result = mrOK);
|
||||||
end;
|
end;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user