Skip to content

Commit

Permalink
Merge pull request #691 from matty0ung/3.0.X
Browse files Browse the repository at this point in the history
Fix for #688
  • Loading branch information
mattiasmaahl committed Dec 10, 2022
2 parents 3a592ec + 6eedc15 commit c5e4354
Show file tree
Hide file tree
Showing 3 changed files with 111 additions and 115 deletions.
15 changes: 7 additions & 8 deletions src/MainWindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@ void MainWindow::init() {
this->setupDrops();

// Moved from Database class
Recipe::connectSignals();
Recipe::connectSignalsForAllRecipes();
qDebug() << Q_FUNC_INFO << "Recipe signals connected";
Mash::connectSignals();
qDebug() << Q_FUNC_INFO << "Mash signals connected";
Expand Down Expand Up @@ -896,7 +896,7 @@ void MainWindow::setupTriggers() {

// postgresql cannot backup or restore yet. I would like to find some way
// around this, but for now just disable
if ( Database::instance().dbType() == Database::PGSQL ) {
if ( Database::instance().dbType() == Database::DbType::PGSQL ) {
actionBackup_Database->setEnabled(false); // > File > Database > Backup
actionRestore_Database->setEnabled(false); // > File > Database > Restore
}
Expand Down Expand Up @@ -1803,10 +1803,9 @@ void MainWindow::updateRecipeBoilTime() {
Equipment* kit = recipeObs->equipment();
double boilTime = Measurement::qStringToSI(lineEdit_boilTime->text(), Measurement::PhysicalQuantity::Time).quantity;

// Here, we rely on a signal/slot connection to propagate the equipment
// changes to recipeObs->boilTime_min and maybe recipeObs->boilSize_l
// NOTE: This works because kit is the recipe's equipment, not the generic
// equipment in the recipe drop down.
// Here, we rely on a signal/slot connection to propagate the equipment changes to recipeObs->boilTime_min and maybe
// recipeObs->boilSize_l
// NOTE: This works because kit is the recipe's equipment, not the generic equipment in the recipe drop down.
if (kit) {
this->doOrRedoUpdate(*kit, PropertyNames::Equipment::boilTime_min, boilTime, tr("Change Boil Time"));
} else {
Expand Down Expand Up @@ -3084,8 +3083,8 @@ void MainWindow::exportSelected() {
bxml.toXml(equipments, *outFile);

outFile->close();
return;
}
return;
}

void MainWindow::redisplayLabel()
{
Expand Down
Loading

0 comments on commit c5e4354

Please sign in to comment.