ide: show object inspector at IDE start only if no config is available. Issue #29829

git-svn-id: trunk@51928 -
This commit is contained in:
ondrej 2016-03-13 20:41:42 +00:00
parent 23f36140b5
commit fd66de43d7
3 changed files with 7 additions and 3 deletions

View File

@ -2233,7 +2233,8 @@ begin
end;
//automatically save active desktops
if AutoSaveActiveDesktop then
if AutoSaveActiveDesktop
and (Application.MainForm<>nil) and Application.MainForm.Visible then
begin
//save active desktop
Desktop.ImportSettingsFromIDE;

View File

@ -1357,6 +1357,7 @@ var
CfgCache: TFPCTargetConfigCache;
OldLazDir: String;
Note: string;
OI: TSimpleWindowLayout;
begin
{$IFDEF DebugSearchFPCSrcThread}
ShowSetupDialog:=true;
@ -1417,6 +1418,10 @@ begin
Application.Terminate;
exit;
end;
// show OI with empty configuration
OI := IDEWindowIntf.IDEWindowCreators.SimpleLayoutStorage.ItemByFormID(DefaultObjectInspectorName);
if OI<>nil then
OI.Visible := True;
EnvironmentOptions.Save(true);
if OldLazDir<>EnvironmentOptions.LazarusDirectory then begin
// fetch new translations

View File

@ -2153,7 +2153,6 @@ begin
// show form and select form
if NewUnitInfo.Component<>nil then begin
// show form
IDEWindowCreators.ShowForm(DefaultObjectInspectorName,false);
MainIDE.DoShowDesignerFormOfCurrentSrc(False);
end else begin
MainIDE.DisplayState:= dsSource;
@ -6068,7 +6067,6 @@ begin
MainIDE.DisplayState := dsForm;
GlobalDesignHook.LookupRoot := NewComponent;
TheControlSelection.AssignPersistent(NewComponent);
IDEWindowCreators.ShowForm(DefaultObjectInspectorName,false);
end;
// show new form