split the selection panel into one card per kind of selection

This commit is contained in:
2026-08-07 18:38:55 +02:00
parent cc0ef856e3
commit 2289277e12
60 changed files with 3014 additions and 1559 deletions

View File

@@ -0,0 +1,32 @@
#pragma once
#include "BufferedBuildingContent.h"
#include "SelectionContentFactory.h"
class QPushButton;
class RecipeSelectionControl;
class ShipLayoutPreview;
// The card for a Shipyard (REQ-UI-SELECTION-CONTENT): the schematic selection, the
// module layout preview and its Configure button (REQ-MOD-UI-PREVIEW), plus the buffers
// and production progress every buffered building shows.
//
// It is the one card whose cycle is not a recipe: a shipyard's materials and production
// time are its schematic's plus every placed module's (REQ-BLD-SHIPYARD).
class ShipyardContent : public BufferedBuildingContent
{
Q_OBJECT
public:
ShipyardContent(const SelectionContext& context, const SelectionRequest& request,
QWidget* parent = nullptr);
protected:
void refreshConfiguration() override;
CycleInfo getCycleInfo(const Building& building) const override;
private:
RecipeSelectionControl* m_schematicControl;
ShipLayoutPreview* m_layoutPreview;
QPushButton* m_configureButton;
};