Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

IDE: prevent crash when Object Inspector is not assigned and project …

…is compiled. Caused by r39082

git-svn-id: http://svn.freepascal.org/svn/lazarus/trunk@39091 4005530d-fff6-0310-9dd1-cebe43e6787f
  • Loading branch information...
commit 1aecf799ad9b405c87cc506a412ac243504c2bb7 1 parent 5db48cc
juha authored
Showing with 4 additions and 2 deletions.
  1. +4 −2 ide/main.pp
View
6 ide/main.pp
@@ -3068,7 +3068,8 @@ procedure TMainIDE.OnProcessIDECommand(Sender: TObject;
ecSave:
begin
- ObjectInspector1.GetActivePropertyGrid.SaveChanges;
+ if Assigned(ObjectInspector1) then
+ ObjectInspector1.GetActivePropertyGrid.SaveChanges;
if (Sender is TDesigner) or (Sender is TObjectInspectorDlg) then begin
if (Sender is TDesigner) then
GetDesignerUnit(TDesigner(Sender),ASrcEdit,AnUnitInfo)
@@ -8192,7 +8193,8 @@ function TMainIDE.PrepareForCompile: TModalResult;
end;
// Save the property editor value in Object Inspector
- ObjectInspector1.GetActivePropertyGrid.SaveChanges;
+ if Assigned(ObjectInspector1) then
+ ObjectInspector1.GetActivePropertyGrid.SaveChanges;
if MainBuildBoss.CompilerOnDiskChanged then
MainBuildBoss.RescanCompilerDefines(false,false,false,false);
Please sign in to comment.
Something went wrong with that request. Please try again.