17 #include "MainWindow.h" |
17 #include "MainWindow.h" |
18 #include "AboutDialog.h" |
18 #include "AboutDialog.h" |
19 #include "InventorySuppliers.h" |
19 #include "InventorySuppliers.h" |
20 #include "InventoryFermentables.h" |
20 #include "InventoryFermentables.h" |
21 #include "InventoryHops.h" |
21 #include "InventoryHops.h" |
|
22 #include "InventoryYeasts.h" |
22 #include "Setup.h" |
23 #include "Setup.h" |
23 #include "../ui/ui_MainWindow.h" |
24 #include "../ui/ui_MainWindow.h" |
24 #include "config.h" |
25 #include "config.h" |
25 |
26 |
26 #include <QApplication> |
27 #include <QApplication> |
105 this->hide(); // Close the main window |
106 this->hide(); // Close the main window |
106 InventoryHopsWindow->show(); // Show a second window |
107 InventoryHopsWindow->show(); // Show a second window |
107 } |
108 } |
108 |
109 |
109 |
110 |
|
111 void MainWindow::fromInventoryYeasts() |
|
112 { |
|
113 qDebug() << Q_FUNC_INFO; |
|
114 delete InventoryYeastsWindow; |
|
115 this->show(); |
|
116 } |
|
117 |
|
118 |
|
119 void MainWindow::on_actionYeasts_triggered() |
|
120 { |
|
121 qDebug() << Q_FUNC_INFO; |
|
122 InventoryYeastsWindow = new InventoryYeasts(this); |
|
123 QObject::connect(InventoryYeastsWindow, SIGNAL(firstWindow()), this, SLOT(fromInventoryYeasts())); |
|
124 this->hide(); // Close the main window |
|
125 InventoryYeastsWindow->show(); // Show a second window |
|
126 } |
|
127 |
|
128 |
110 void MainWindow::fromSetup() |
129 void MainWindow::fromSetup() |
111 { |
130 { |
112 qDebug() << Q_FUNC_INFO; |
131 qDebug() << Q_FUNC_INFO; |
113 delete SetupWindow; |
132 delete SetupWindow; |
114 this->show(); |
133 this->show(); |