imagewriter: Insert nascent HW filter

This commit is contained in:
Tom Dewey 2023-11-09 16:19:41 +00:00 committed by Tom Dewey
parent a25855c41a
commit b29ec3350c
2 changed files with 9 additions and 0 deletions

View file

@ -472,6 +472,12 @@ namespace {
} // namespace anonymous } // namespace anonymous
void ImageWriter::setHWFilterList(const QByteArray &json) {
QJsonDocument json_document = QJsonDocument::fromJson(json);
_deviceFilter = json_document.array();
}
void ImageWriter::handleNetworkRequestFinished(QNetworkReply *data) { void ImageWriter::handleNetworkRequestFinished(QNetworkReply *data) {
// Defer deletion // Defer deletion
data->deleteLater(); data->deleteLater();

View file

@ -85,6 +85,9 @@ public:
/** Begin the asynchronous fetch of the OS lists, and associated sublists. */ /** Begin the asynchronous fetch of the OS lists, and associated sublists. */
Q_INVOKABLE void beginOSListFetch(); Q_INVOKABLE void beginOSListFetch();
/** Set the HW filter, for a filtered view of the OS list */
Q_INVOKABLE void setHWFilterList(const QByteArray &json);
/* Set custom cache file */ /* Set custom cache file */
void setCustomCacheFile(const QString &cacheFile, const QByteArray &sha256); void setCustomCacheFile(const QString &cacheFile, const QByteArray &sha256);