mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2024-12-21 08:09:35 +08:00
Allow to retry fetching RSS feeds
This commit is contained in:
parent
73ef69526d
commit
cf6e721b00
@ -125,11 +125,13 @@ void Feed::markAsRead()
|
|||||||
|
|
||||||
void Feed::refresh()
|
void Feed::refresh()
|
||||||
{
|
{
|
||||||
if (isLoading()) return;
|
if (isLoading())
|
||||||
|
m_downloadHandler->cancel();
|
||||||
|
|
||||||
// NOTE: Should we allow manually refreshing for disabled session?
|
// NOTE: Should we allow manually refreshing for disabled session?
|
||||||
|
|
||||||
Net::DownloadManager::instance()->download(m_url, this, &Feed::handleDownloadFinished);
|
m_downloadHandler = Net::DownloadManager::instance()->download(m_url);
|
||||||
|
connect(m_downloadHandler, &Net::DownloadHandler::finished, this, &Feed::handleDownloadFinished);
|
||||||
|
|
||||||
m_isLoading = true;
|
m_isLoading = true;
|
||||||
emit stateChanged(this);
|
emit stateChanged(this);
|
||||||
|
@ -41,6 +41,7 @@ class AsyncFileStorage;
|
|||||||
|
|
||||||
namespace Net
|
namespace Net
|
||||||
{
|
{
|
||||||
|
class DownloadHandler;
|
||||||
struct DownloadResult;
|
struct DownloadResult;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -125,5 +126,6 @@ namespace RSS
|
|||||||
QString m_dataFileName;
|
QString m_dataFileName;
|
||||||
QBasicTimer m_savingTimer;
|
QBasicTimer m_savingTimer;
|
||||||
bool m_dirty = false;
|
bool m_dirty = false;
|
||||||
|
Net::DownloadHandler *m_downloadHandler = nullptr;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user