fpspreadsheet: No "invalid index" error message when attempting to save a workbook without reader/writer unit in "uses"

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@7197 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz
2019-11-23 11:34:00 +00:00
parent 79a817cefd
commit f131c02f88

View File

@@ -1199,6 +1199,7 @@ begin
begin begin
// Bring the priority format to the top // Bring the priority format to the top
idx := IndexOf(APriorityFormat); idx := IndexOf(APriorityFormat);
if idx > -1 then
FList.Exchange(0, idx); FList.Exchange(0, idx);
end; end;
@@ -1224,6 +1225,7 @@ begin
if APriorityFormat <> sfidUnknown then if APriorityFormat <> sfidUnknown then
// Restore original order // Restore original order
if idx > -1 then
FList.Exchange(idx, 0); FList.Exchange(idx, 0);
end; end;