From b13e23ee416cf9e273e7eaef57859fbd6ad99660 Mon Sep 17 00:00:00 2001 From: victor Date: Tue, 25 Apr 2017 11:56:38 +0900 Subject: [PATCH] =?UTF-8?q?=EC=9E=90=EB=8F=99=20=EC=9A=94=EB=A6=AC=20?= =?UTF-8?q?=EC=88=98=EC=A0=95=20=20-=20=EC=9A=94=EB=A6=AC=20=EC=8B=9C?= =?UTF-8?q?=EC=9E=91=20=EC=8B=9C=20=EC=9D=B4=EB=AF=B8=20=EC=B2=AB=20?= =?UTF-8?q?=EB=B2=88=EC=A7=B8=20=EB=8B=A8=EA=B3=84=20=EB=AA=A9=ED=91=9C?= =?UTF-8?q?=EA=B0=80=20=EC=B6=A9=EC=A1=B1=EB=90=98=EC=96=B4=20=EB=8B=A4?= =?UTF-8?q?=EC=9D=8C=20=EB=8B=A8=EA=B3=84=EB=A1=9C=20=EB=84=98=EC=96=B4?= =?UTF-8?q?=EA=B0=94=EC=9D=84=20=EB=95=8C=20=ED=99=94=EB=A9=B4=EC=97=90=20?= =?UTF-8?q?=EB=B0=98=EC=98=81=EB=90=98=EC=A7=80=20=EC=95=8A=EB=8A=94=20?= =?UTF-8?q?=EB=AC=B8=EC=A0=9C=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/gui/oven_control/autocookwindow.cpp | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/app/gui/oven_control/autocookwindow.cpp b/app/gui/oven_control/autocookwindow.cpp index ffd8d30..7ee4385 100644 --- a/app/gui/oven_control/autocookwindow.cpp +++ b/app/gui/oven_control/autocookwindow.cpp @@ -320,6 +320,14 @@ void AutoCookWindow::updateView() ui->preheatGauge->hide(); } + if (selectedStepIndex != autocook.currentStepIndex) + { + if (!returnToCurrentStepTimer.isActive()) + { + selectedStepIndex = autocook.currentStepIndex; + } + } + if (selectedStepIndex != lastViewStepIndex) { lastViewStepIndex = selectedStepIndex; @@ -667,22 +675,22 @@ void AutoCookWindow::on_backButton_clicked() void AutoCookWindow::on_showPrevStepButton_clicked() { + returnToCurrentStepTimer.start(); + if (selectedStepIndex > 0) { selectedStepIndex--; updateView(); } - - returnToCurrentStepTimer.start(); } void AutoCookWindow::on_showNextStepButton_clicked() { + returnToCurrentStepTimer.start(); + if (selectedStepIndex + 1 < autocook.cook.steps.size()) { selectedStepIndex++; updateView(); } - - returnToCurrentStepTimer.start(); } -- 2.1.4