- Fixed TfrmEditAccount.RegionDeleted to check, if the region is known (to prevent index out of bounds errors)
- Fixed UfrmMain to be compatible with newer versions of FPC - Added a slider to frmRegionControl - Added buttons to add and delete regions to frmRegionControl - Fixed unsaved regions not being removed in TfrmRegionControl - Extracted TfrmRegionControl.CheckUnsaved
This commit is contained in:
@@ -143,8 +143,12 @@ begin
|
||||
end;
|
||||
|
||||
procedure TfrmEditAccount.RegionDeleted(ARegionName: string);
|
||||
var
|
||||
index: Integer;
|
||||
begin
|
||||
cbRegions.Items.Delete(cbRegions.Items.IndexOf(ARegionName));
|
||||
index := cbRegions.Items.IndexOf(ARegionName);
|
||||
if index > -1 then
|
||||
cbRegions.Items.Delete(index);
|
||||
end;
|
||||
|
||||
procedure TfrmEditAccount.RegionList;
|
||||
|
||||
Reference in New Issue
Block a user