forked from amazingfate/loongoffice
Commit 0c96119895b347f8eb5bb89f393351bd3c02b9f1 (tdf#159565 prerequisite: make hidden sections have zero-height frames, 2024-02-14) made hidden sections have frames. This removes the need to unhide them to get their frames, which happened in SwDocUpdateField::MakeFieldList_. Commit 6db63bb533a5c7436793eab86e83f92322b37044 (tdf#166210: invalidate parent's size when hiding section, 2025-04-28) started to invalidate the section frame's parent size on section hidden state change. This created a loop, where a calculation of the condition, that made a section hidden, caused the section to unhide then hide, invalidating parent frame; that caused repagination, and then another recalculation (because the number of pages may affect the conditions). This change drops the code in SwDocUpdateField::MakeFieldList_, that did the work to unhide then hide sections again, as obsolete. Change-Id: Ia144835548defaa38d53f03520ac0cc550bdfc23 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/186108 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Jenkins (cherry picked from commit ca3e88728f29422ad9e4bd7f9bec08b59cdf4192) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/186124 Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>