mirror of
https://github.com/storytold/gridcraft.git
synced 2026-11-07 02:51:33 +00:00
without_controls dropped a whole child of a kept <controls> element as soon as one control in it was modelled, so an mc:AlternateContent holding a scroll bar (modelled) and a list box (left to pass-through) lost the list box's worksheet entry on save, while its VML shape and properties part stayed. The controls are now taken out one by one, in the Choice and the Fallback branches alike, by the shapeId the control reader reads (an attribute, in either quote style); the wrapper stays while a control remains and goes only when it is empty, and a child with none of ours is kept unchanged. strip_shapes already works per shape, so the kept control's shape stays, and its properties part follows its relationship as before. Test: an_unsupported_control_beside_a_modelled_one_in_one_alternate_content_is_kept (after open and save the scroll bar is written once, the list box is still in <controls> in both branches with its VML shape and its properties part, and the file reads back with one modelled control and the kept one).