Browse Source

Fix relative mode, really this time.

Neal Wilson 11 years ago
parent
commit
58ce7f0b70
1 changed files with 4 additions and 4 deletions
  1. 4
    4
      src/typica.w

+ 4
- 4
src/typica.w View File

@@ -7030,8 +7030,8 @@ void TemperatureDisplay::setValue(Measurement temperature)
7030 7030
 					arg(number.setNum(temperature.toCelsius().temperature(), 'f',
7031 7031
 									2)));
7032 7032
 			} else {
7033
-				display(QString("%1'C").
7034
-					arg(number.setNum(temperature.temperature() * (5/9), 'f', 2)));
7033
+				number.setNum(temperature.temperature() * (5.0/9.0), 'f', 2);
7034
+				display(QString("%1'C").arg(number));
7035 7035
 			}
7036 7036
 			break;
7037 7037
 		case Units::Kelvin:
@@ -7040,8 +7040,8 @@ void TemperatureDisplay::setValue(Measurement temperature)
7040 7040
 					arg(number.setNum(temperature.toKelvin().temperature(), 'f',
7041 7041
 									2)));
7042 7042
 			} else {
7043
-				display(QString("%1").
7044
-					arg(number.setNum(temperature.temperature() * (5/9), 'f', 2)));
7043
+				number.setNum(temperature.temperature() * (5.0/9.0), 'f', 2);
7044
+				display(QString("%1").arg(number));
7045 7045
 			}
7046 7046
 			break;
7047 7047
 		case Units::Rankine:

Loading…
Cancel
Save