Review comments

This commit is contained in:
jpirnay
2026-05-04 13:59:28 +02:00
parent 6eae99362d
commit 444be74249
3 changed files with 7 additions and 9 deletions
@@ -1001,6 +1001,8 @@ void MdReaderActivity::onButtonAction(const CrossPointSettings::BUTTON_ACTION ac
SETTINGS.orientation = nextOrientation;
SETTINGS.saveToFile();
ReaderUtils::applyOrientation(renderer, SETTINGS.orientation);
initialized = false;
initializeReader();
requestUpdate();
break;
}
@@ -839,6 +839,8 @@ void TxtReaderActivity::onButtonAction(const CrossPointSettings::BUTTON_ACTION a
SETTINGS.orientation = nextOrientation;
SETTINGS.saveToFile();
ReaderUtils::applyOrientation(renderer, SETTINGS.orientation);
initialized = false;
initializeReader();
requestUpdate();
break;
}
+3 -9
View File
@@ -82,9 +82,7 @@ bool HttpDownloader::fetchUrl(const std::string& url, Stream& outContent, const
if (httpCode != HTTP_CODE_OK) {
LOG_ERR("HTTP", "Fetch failed: %d", httpCode);
http.end();
if (client) {
client->stop();
}
client->stop();
return false;
}
@@ -142,9 +140,7 @@ HttpDownloader::DownloadError HttpDownloader::downloadToFile(const std::string&
if (httpCode != HTTP_CODE_OK) {
LOG_ERR("HTTP", "Download failed: %d", httpCode);
http.end();
if (client) {
client->stop();
}
client->stop();
return HTTP_ERROR;
}
@@ -221,9 +217,7 @@ HttpDownloader::DownloadError HttpDownloader::downloadToFile(const std::string&
file.flush();
file.close();
http.end();
if (client) {
client->stop();
}
client->stop();
if (writeResult < 0) {
LOG_ERR("HTTP", "writeToStream error: %d", writeResult);