Updates current unit in memory, settings and emits displayUnitChanged(newUnit) signal */
| 461 | |
| 462 | /** Updates current unit in memory, settings and emits displayUnitChanged(newUnit) signal */ |
| 463 | void OptionsModel::setDisplayUnit(const QVariant &value) |
| 464 | { |
| 465 | if (!value.isNull()) |
| 466 | { |
| 467 | QSettings settings; |
| 468 | nDisplayUnit = value.toInt(); |
| 469 | settings.setValue("nDisplayUnit", nDisplayUnit); |
| 470 | Q_EMIT displayUnitChanged(nDisplayUnit); |
| 471 | } |
| 472 | } |
| 473 | |
| 474 | bool OptionsModel::getProxySettings(QNetworkProxy& proxy) const |
| 475 | { |
no test coverage detected