Commit 0fbf1932cd18beeac363f311fd3a49f1e731d2ce
1 parent
10d2268c28
Exists in
master
and in
2 other branches
V1.5.0.2
요청 사항 반영 - OFF 문자열 표시가 잘리는 문제 수정 - 쿨다운 팝업에서 조작할 때도 상태 변경 알림이 나오도록 수정
Showing
4 changed files
with
31 additions
and
32 deletions
Show diff stats
app/gui/oven_control/cooldownpopup.cpp
| ... | ... | @@ -44,6 +44,8 @@ CooldownPopup::CooldownPopup(QWidget *parent, int target) : |
| 44 | 44 | if (needCookStarting) |
| 45 | 45 | oven->stopCooking(); |
| 46 | 46 | |
| 47 | + oven->setFan(expectingFanLevel); | |
| 48 | + | |
| 47 | 49 | connect(oven, SIGNAL(changed(Oven*)), SLOT(updateView())); |
| 48 | 50 | |
| 49 | 51 | cooldownStartTimer.setSingleShot(true); |
| ... | ... | @@ -272,10 +274,7 @@ void CooldownPopup::on_fanButton_clicked() |
| 272 | 274 | if (expectingFanLevel < oven->minFan()) |
| 273 | 275 | expectingFanLevel = oven->maxFan(); |
| 274 | 276 | |
| 275 | - if (oven->cooldown()) | |
| 276 | - oven->setFan(expectingFanLevel); | |
| 277 | - else | |
| 278 | - updateView(); | |
| 277 | + oven->setFan(expectingFanLevel); | |
| 279 | 278 | |
| 280 | 279 | if (cooldownStartTimer.isActive()) |
| 281 | 280 | cooldownStartTimer.start(); | ... | ... |
app/gui/oven_control/define.h
app/gui/oven_control/manualcookwindow.cpp
| ... | ... | @@ -487,6 +487,31 @@ QPushButton:focus { background-image: url(%2); }"); |
| 487 | 487 | int fan = oven->fan(); |
| 488 | 488 | if (fan != lastViewFan) |
| 489 | 489 | { |
| 490 | + if (lastViewFan != -1) | |
| 491 | + { | |
| 492 | + switch (fan) | |
| 493 | + { | |
| 494 | + case 1: | |
| 495 | + showInfoText("1", ":/images/manual_button/fan_1.png"); | |
| 496 | + break; | |
| 497 | + case 2: | |
| 498 | + showInfoText("2", ":/images/manual_button/fan_2.png"); | |
| 499 | + break; | |
| 500 | + case 3: | |
| 501 | + showInfoText("3", ":/images/manual_button/fan_3.png"); | |
| 502 | + break; | |
| 503 | + case 4: | |
| 504 | + showInfoText("4", ":/images/manual_button/fan_4.png"); | |
| 505 | + break; | |
| 506 | + case 5: | |
| 507 | + showInfoText("5", ":/images/manual_button/fan_5.png"); | |
| 508 | + break; | |
| 509 | + default: | |
| 510 | + showInfoText("6", ":/images/manual_button/fan_6.png"); | |
| 511 | + break; | |
| 512 | + } | |
| 513 | + } | |
| 514 | + | |
| 490 | 515 | lastViewFan = fan; |
| 491 | 516 | |
| 492 | 517 | switch (fan) |
| ... | ... | @@ -1034,31 +1059,6 @@ void ManualCookWindow::on_fanButton_clicked() |
| 1034 | 1059 | fan = oven->minFan(); |
| 1035 | 1060 | |
| 1036 | 1061 | oven->setFan(fan); |
| 1037 | - | |
| 1038 | - QString text = QString("%1").arg(fan); | |
| 1039 | - QString icon; | |
| 1040 | - switch (fan) | |
| 1041 | - { | |
| 1042 | - case 1: | |
| 1043 | - icon = ":/images/manual_button/fan_1.png"; | |
| 1044 | - break; | |
| 1045 | - case 2: | |
| 1046 | - icon = ":/images/manual_button/fan_2.png"; | |
| 1047 | - break; | |
| 1048 | - case 3: | |
| 1049 | - icon = ":/images/manual_button/fan_3.png"; | |
| 1050 | - break; | |
| 1051 | - case 4: | |
| 1052 | - icon = ":/images/manual_button/fan_4.png"; | |
| 1053 | - break; | |
| 1054 | - case 5: | |
| 1055 | - icon = ":/images/manual_button/fan_5.png"; | |
| 1056 | - break; | |
| 1057 | - default: | |
| 1058 | - break; | |
| 1059 | - } | |
| 1060 | - | |
| 1061 | - showInfoText(text, icon); | |
| 1062 | 1062 | } |
| 1063 | 1063 | |
| 1064 | 1064 | void ManualCookWindow::on_preheatButton_clicked() | ... | ... |
app/gui/oven_control/manualcookwindow.ui
| ... | ... | @@ -1322,10 +1322,10 @@ background-repeat: no-repeat; |
| 1322 | 1322 | background-position: center center; |
| 1323 | 1323 | border-radius: 40px; |
| 1324 | 1324 | color: rgba(255, 255, 255, 255); |
| 1325 | -margin: 200px 300px;</string> | |
| 1325 | +margin: 200px 200px;</string> | |
| 1326 | 1326 | </property> |
| 1327 | 1327 | <property name="text"> |
| 1328 | - <string><img src=":/images/manual_button/fan_1.png"/><span>1</span></string> | |
| 1328 | + <string><img src=":/images/manual_button/fan_1.png"/><span> OFF</span></string> | |
| 1329 | 1329 | </property> |
| 1330 | 1330 | <property name="alignment"> |
| 1331 | 1331 | <set>Qt::AlignCenter</set> | ... | ... |