Improved handling of late initialisation for component objects

This commit is contained in:
Nav
2021-12-31 19:45:15 +00:00
parent d24587b992
commit 49383eb448
9 changed files with 109 additions and 72 deletions

View File

@@ -27,7 +27,17 @@ using Bloom::Targets::TargetPackage;
using Bloom::Targets::TargetPinDescriptor;
using Bloom::Targets::TargetMemoryType;
InsightWindow::InsightWindow(InsightWorker& insightWorker): QMainWindow(nullptr), insightWorker(insightWorker) {
InsightWindow::InsightWindow(
InsightWorker& insightWorker,
const EnvironmentConfig& environmentConfig,
const InsightConfig& insightConfig
):
QMainWindow(nullptr),
insightWorker(insightWorker),
environmentConfig(environmentConfig),
targetConfig(environmentConfig.targetConfig),
insightConfig(insightConfig)
{
this->setObjectName("main-window");
this->setWindowTitle("Bloom Insight");
this->setMinimumSize(1000, 500);

View File

@@ -30,7 +30,11 @@ namespace Bloom
Q_OBJECT
public:
InsightWindow(InsightWorker& insightWorker);
InsightWindow(
InsightWorker& insightWorker,
const EnvironmentConfig& environmentConfig,
const InsightConfig& insightConfig
);
void setEnvironmentConfig(const EnvironmentConfig& environmentConfig) {
this->environmentConfig = environmentConfig;