fix more runtime error due to fix for #307

+ mixed indent dialog could be shown during tab switch, w/o doc visible yet
This commit is contained in:
Basile Burg 2018-04-28 09:03:58 +02:00
parent dc9f2fed64
commit 15c9325c0e
3 changed files with 8 additions and 7 deletions

View File

@ -84,5 +84,5 @@ object CurrentProject: TCENativeProject
'cesetup.d' 'cesetup.d'
) )
ConfigurationIndex = 2 ConfigurationIndex = 2
version = '3.6.10' version = '3.6.11'
end end

View File

@ -1 +1 @@
v3.6.10 v3.6.11

View File

@ -1137,8 +1137,9 @@ end;
procedure TCESynMemo.handleModalBeginning(sender: TObject); procedure TCESynMemo.handleModalBeginning(sender: TObject);
begin begin
// AV can happens in TCustomSynEdit.UpdateCursor // AV can happens in TCustomSynEdit.UpdateCursor
if assigned(FTextArea) and (eoAutoHideCursor in Options2) then if (self <> nil) and (Pcardinal(@FTextArea)^ <> $f0f0f0f0) and (Pcardinal(@FTextArea)^ <> $0f0f0f0f)
MouseMove([], 0, 0); and assigned(FTextArea) and (eoAutoHideCursor in Options2) then
MouseMove([], 0, 0);
end; end;
procedure TCESynMemo.setFocus; procedure TCESynMemo.setFocus;
@ -1146,7 +1147,6 @@ begin
inherited; inherited;
highlightCurrentIdentifier; highlightCurrentIdentifier;
subjDocFocused(TCEMultiDocSubject(fMultiDocSubject), self); subjDocFocused(TCEMultiDocSubject(fMultiDocSubject), self);
tryToPatchMixedIndentation;
end; end;
procedure TCESynMemo.showPage; procedure TCESynMemo.showPage;
@ -1162,6 +1162,7 @@ begin
subjDocFocused(TCEMultiDocSubject(fMultiDocSubject), self); subjDocFocused(TCEMultiDocSubject(fMultiDocSubject), self);
fFocusForInput := true; fFocusForInput := true;
fScrollMemo.Visible:=false; fScrollMemo.Visible:=false;
tryToPatchMixedIndentation;
end; end;
procedure TCESynMemo.DoExit; procedure TCESynMemo.DoExit;
@ -3588,8 +3589,8 @@ begin
Options:= Options + [eoTabsToSpaces]; Options:= Options + [eoTabsToSpaces];
imMixed: imMixed:
if (isDSource or alwaysAdvancedFeatures) and if (isDSource or alwaysAdvancedFeatures) and
(dlgYesNo('Mixed indentation style detected, ' + (dlgYesNo('Mixed indentation style detected in, "' + fFilename +
'do you wish to convert to a single mode ?') = mrYes) then '", do you wish to convert to a single mode ?') = mrYes) then
with TMixedIndentationDialog.construct() do with TMixedIndentationDialog.construct() do
try try
case ShowModal of case ShowModal of