--- a/src/MainWindow.cpp Sat Feb 26 16:34:20 2022 +0100 +++ b/src/MainWindow.cpp Sun Feb 27 20:45:41 2022 +0100 @@ -22,6 +22,7 @@ #include "InventoryYeasts.h" #include "InventoryMiscs.h" #include "InventoryWaters.h" +#include "InventoryEquipments.h" #include "Setup.h" #include "../ui/ui_MainWindow.h" #include "config.h" @@ -164,6 +165,24 @@ } +void MainWindow::fromInventoryEquipments() +{ + qDebug() << Q_FUNC_INFO; + delete InventoryEquipmentsWindow; + this->show(); +} + + +void MainWindow::on_actionEquipments_triggered() +{ + qDebug() << Q_FUNC_INFO; + InventoryEquipmentsWindow = new InventoryEquipments(this); + QObject::connect(InventoryEquipmentsWindow, SIGNAL(firstWindow()), this, SLOT(fromInventoryEquipments())); + this->hide(); // Close the main window + InventoryEquipmentsWindow->show(); // Show a second window +} + + void MainWindow::fromSetup() { qDebug() << Q_FUNC_INFO;