Malte Langkabel 53af44db04 Fix shipyard layout preview/button not showing until re-selection
Selecting a ship schematic in the shipyard left the layout preview and
Configure Layout button hidden until the building was deselected and
re-selected.

The recipe change is applied via a queued command that only drains on a
later frame, so the immediate rebuild() in onSelectRecipeClicked() still
saw the old (empty) recipe and hid both widgets. The per-tick
refreshBuffers() path then updated the preview's data but never set its
visibility -- that was only ever done in buildSingle() -- so the widgets
stayed hidden until a re-selection re-ran buildSingle().

Extract the shipyard preview/button show-hide-and-populate logic into
updateShipyardLayoutWidgets() and call it from both buildSingle() and
refreshBuffers(), so the per-tick refresh becomes authoritative for
visibility and the widgets appear on the first tick after the command
drains.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DyCu8vwChKMbLJQ3xosYEN
2026-07-08 20:36:41 +02:00
2026-04-19 10:19:27 +02:00
2026-04-19 10:19:27 +02:00
2026-04-19 13:40:37 +02:00
Description
No description provided
20 MiB
Languages
C++ 96%
CMake 2.2%
Python 1.2%
C 0.6%