rename methods

This commit is contained in:
RickyRister 2025-07-05 19:47:27 -07:00
parent d5590929b1
commit 592d4e1be5
4 changed files with 8 additions and 7 deletions

View file

@ -36,8 +36,9 @@ PictureLoader::PictureLoader() : QObject(nullptr)
mainWindow->statusBar()->addPermanentWidget(statusBar); mainWindow->statusBar()->addPermanentWidget(statusBar);
} }
connect(worker, &PictureLoaderWorker::imageLoadQueued, statusBar, &PictureLoaderStatusBar::addQueuedImageLoad); connect(worker, &PictureLoaderWorker::imageRequestQueued, statusBar, &PictureLoaderStatusBar::addQueuedImageLoad);
connect(worker, &PictureLoaderWorker::requestSucceeded, statusBar, &PictureLoaderStatusBar::addSuccessfulImageLoad); connect(worker, &PictureLoaderWorker::imageRequestSucceeded, statusBar,
&PictureLoaderStatusBar::addSuccessfulImageLoad);
} }
PictureLoader::~PictureLoader() PictureLoader::~PictureLoader()

View file

@ -72,7 +72,7 @@ void PictureLoaderWorker::queueRequest(const QUrl &url, PictureLoaderWorkerWork
makeRequest(url, worker); makeRequest(url, worker);
} else { } else {
requestLoadQueue.append(qMakePair(url, worker)); requestLoadQueue.append(qMakePair(url, worker));
emit imageLoadQueued(url, worker->cardToDownload.getCard(), worker->cardToDownload.getSetName()); emit imageRequestQueued(url, worker->cardToDownload.getCard(), worker->cardToDownload.getSetName());
processQueuedRequests(); processQueuedRequests();
} }
} }
@ -82,7 +82,7 @@ QNetworkReply *PictureLoaderWorker::makeRequest(const QUrl &url, PictureLoaderWo
// Check for cached redirects // Check for cached redirects
QUrl cachedRedirect = getCachedRedirect(url); QUrl cachedRedirect = getCachedRedirect(url);
if (!cachedRedirect.isEmpty()) { if (!cachedRedirect.isEmpty()) {
emit requestSucceeded(url); emit imageRequestSucceeded(url);
return makeRequest(cachedRedirect, worker); return makeRequest(cachedRedirect, worker);
} }

View file

@ -71,8 +71,8 @@ private slots:
signals: signals:
void imageLoadEnqueued(const CardInfoPtr &card); void imageLoadEnqueued(const CardInfoPtr &card);
void imageLoaded(CardInfoPtr card, const QImage &image); void imageLoaded(CardInfoPtr card, const QImage &image);
void imageLoadQueued(const QUrl &url, const CardInfoPtr &card, const QString &setName); void imageRequestQueued(const QUrl &url, const CardInfoPtr &card, const QString &setName);
void requestSucceeded(const QUrl &url); void imageRequestSucceeded(const QUrl &url);
}; };
#endif // PICTURE_LOADER_WORKER_H #endif // PICTURE_LOADER_WORKER_H

View file

@ -23,7 +23,7 @@ PictureLoaderWorkerWork::PictureLoaderWorkerWork(const PictureLoaderWorker *work
connect(this, &PictureLoaderWorkerWork::urlRedirected, worker, &PictureLoaderWorker::cacheRedirect); connect(this, &PictureLoaderWorkerWork::urlRedirected, worker, &PictureLoaderWorker::cacheRedirect);
connect(this, &PictureLoaderWorkerWork::cachedUrlInvalidated, worker, &PictureLoaderWorker::removedCachedUrl); connect(this, &PictureLoaderWorkerWork::cachedUrlInvalidated, worker, &PictureLoaderWorker::removedCachedUrl);
connect(this, &PictureLoaderWorkerWork::imageLoaded, worker, &PictureLoaderWorker::handleImageLoaded); connect(this, &PictureLoaderWorkerWork::imageLoaded, worker, &PictureLoaderWorker::handleImageLoaded);
connect(this, &PictureLoaderWorkerWork::requestSucceeded, worker, &PictureLoaderWorker::requestSucceeded); connect(this, &PictureLoaderWorkerWork::requestSucceeded, worker, &PictureLoaderWorker::imageRequestSucceeded);
// Hook up signals to settings // Hook up signals to settings
connect(&SettingsCache::instance(), SIGNAL(picDownloadChanged()), this, SLOT(picDownloadChanged())); connect(&SettingsCache::instance(), SIGNAL(picDownloadChanged()), this, SLOT(picDownloadChanged()));