# HG changeset patch # User Michiel Broek # Date 1651043561 -7200 # Node ID 47ee0d1b47e9d865d1bc28eacf7d6277c1ecb462 # Parent 6cccd340ea8cc52efbc8c18488e7d84e5b6f7c68 Fixed dry-hop days setting. diff -r 6cccd340ea8c -r 47ee0d1b47e9 src/EditRecipeTab3.cpp --- a/src/EditRecipeTab3.cpp Wed Apr 27 08:54:17 2022 +0200 +++ b/src/EditRecipeTab3.cpp Wed Apr 27 09:12:41 2022 +0200 @@ -290,13 +290,15 @@ qDebug() << "hop_time_changed()" << recipe->hops_row << val; - recipe->hops[recipe->hops_row].h_time = val; if (recipe->hops.at(recipe->hops_row).h_useat == 2 || recipe->hops.at(recipe->hops_row).h_useat == 4) { // Boil or whirlpool item = new QTableWidgetItem(QString("%1 min.").arg(val, 1, 'f', 0, '0')); + recipe->hops[recipe->hops_row].h_time = val; } else if (recipe->hops.at(recipe->hops_row).h_useat == 5) { // Dry-hop - item = new QTableWidgetItem(QString("%1 days.").arg(val / 1440, 1, 'f', 0, '0')); + item = new QTableWidgetItem(QString("%1 days.").arg(val, 1, 'f', 0, '0')); + recipe->hops[recipe->hops_row].h_time = val * 1440; } else { item = new QTableWidgetItem(QString("")); + recipe->hops[recipe->hops_row].h_time = val; } item->setTextAlignment(Qt::AlignRight|Qt::AlignVCenter); ui->hopsTable->setItem(recipe->hops_row, 6, item);