From bcbae4f21b644a3b0c8d6963dd38a628788ecd8e Mon Sep 17 00:00:00 2001 From: mattias Date: Mon, 25 Mar 2024 19:31:12 +0100 Subject: [PATCH] ide: fixed using default subtarget by default --- ide/frames/compiler_config_target.pas | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ide/frames/compiler_config_target.pas b/ide/frames/compiler_config_target.pas index 50d2809b6e..5274310507 100644 --- a/ide/frames/compiler_config_target.pas +++ b/ide/frames/compiler_config_target.pas @@ -272,6 +272,8 @@ begin sl:=TStringListUTF8Fast.Create; try sl.Assign(InputHistories.HistoryLists.GetList('Subtarget',true,rltCaseInsensitive)); + if sl.IndexOf('')<0 then + sl.Add(''); // always have the default target // search for possible subtargets // fpc searches subtarget configs in the same directories it searches for normal configs @@ -320,7 +322,7 @@ begin with SubtargetComboBox do begin Items.BeginUpdate; Items.Assign(sl); - SetComboBoxText(SubtargetComboBox,Subtarget,cstCaseInsensitive); + SetComboBoxText(SubtargetComboBox,'',cstCaseInsensitive); Items.EndUpdate; end; finally