Commit c6dd03260e3c9a7fce9ba677a147c051f223c89e

Authored by 김태훈
1 parent b2ddac079a
Exists in master and in 2 other branches fhd, fhd-demo

요리 시작/종료 관련 음향 효과 수정 & 추가

- 수동 요리 시작 효과를 시간이 0보다 클 때만 출력
- 자동 요리 시작/종료 효과 추가
- 자동 요리 후속 공정 중 바삭함 주기 시작/종료에 요리 시작/종료 효과 추가
app/gui/oven_control/autocook.cpp
1 #include "autocook.h" 1 #include "autocook.h"
  2 +#include "soundplayer.h"
2 3
3 AutoCook::AutoCook() : currentStepIndex(0), done_(false), doorOpened(false), checkingCoreTemp(false) 4 AutoCook::AutoCook() : currentStepIndex(0), done_(false), doorOpened(false), checkingCoreTemp(false)
4 { 5 {
@@ -314,6 +315,8 @@ bool AutoCook::advance() @@ -314,6 +315,8 @@ bool AutoCook::advance()
314 { 315 {
315 done_ = true; 316 done_ = true;
316 317
  318 + SoundPlayer::playStop();
  319 +
317 if (currentStep.dehumidification) 320 if (currentStep.dehumidification)
318 { 321 {
319 if (currentStep.dehumidificationRepeatDelay) 322 if (currentStep.dehumidificationRepeatDelay)
@@ -357,6 +360,8 @@ bool AutoCook::advance() @@ -357,6 +360,8 @@ bool AutoCook::advance()
357 { 360 {
358 done_ = true; 361 done_ = true;
359 362
  363 + SoundPlayer::playStop();
  364 +
360 if (currentStep.dehumidification) 365 if (currentStep.dehumidification)
361 { 366 {
362 if (currentStep.dehumidificationRepeatDelay) 367 if (currentStep.dehumidificationRepeatDelay)
app/gui/oven_control/autocookwindow.cpp
@@ -64,6 +64,8 @@ AutoCookWindow::AutoCookWindow(QWidget *parent, Cook cook) : @@ -64,6 +64,8 @@ AutoCookWindow::AutoCookWindow(QWidget *parent, Cook cook) :
64 64
65 connect(&updateViewTimer, SIGNAL(timeout()), SLOT(updateView())); 65 connect(&updateViewTimer, SIGNAL(timeout()), SLOT(updateView()));
66 updateViewTimer.start(100); 66 updateViewTimer.start(100);
  67 +
  68 + SoundPlayer::playStart();
67 } 69 }
68 70
69 AutoCookWindow::~AutoCookWindow() 71 AutoCookWindow::~AutoCookWindow()
@@ -601,6 +603,9 @@ void AutoCookWindow::startProcess(int process) @@ -601,6 +603,9 @@ void AutoCookWindow::startProcess(int process)
601 oven->startCooking(); 603 oven->startCooking();
602 604
603 checkProcessTimer.start(100); 605 checkProcessTimer.start(100);
  606 +
  607 + SoundPlayer::playStart();
  608 +
604 break; 609 break;
605 } 610 }
606 case Define::KeepWarm: 611 case Define::KeepWarm:
@@ -630,6 +635,7 @@ void AutoCookWindow::checkProcess() @@ -630,6 +635,7 @@ void AutoCookWindow::checkProcess()
630 Oven *oven = Oven::getInstance(); 635 Oven *oven = Oven::getInstance();
631 if (oven->currentTemp() >= oven->temp()) 636 if (oven->currentTemp() >= oven->temp())
632 { 637 {
  638 + SoundPlayer::playStop();
633 oven->stopCooking(); 639 oven->stopCooking();
634 checkProcessTimer.stop(); 640 checkProcessTimer.stop();
635 processSelected = false; 641 processSelected = false;
app/gui/oven_control/manualcookwindow.cpp
@@ -351,10 +351,10 @@ void ManualCookWindow::start() @@ -351,10 +351,10 @@ void ManualCookWindow::start()
351 if (oven->cooking()) 351 if (oven->cooking())
352 return; 352 return;
353 353
354 - SoundPlayer::playStart();  
355 -  
356 if (oven->time() > 0) 354 if (oven->time() > 0)
357 { 355 {
  356 + SoundPlayer::playStart();
  357 +
358 if (startCookingTimer.isActive()) 358 if (startCookingTimer.isActive())
359 startCookingTimer.stop(); 359 startCookingTimer.stop();
360 360