mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-12-12 19:04:05 +00:00
d3e6018401
* fix: wikipedia open blank page in edge browser * [autofix.ci] apply automated fixes --------- Co-authored-by: YiFang Xiao <yifang.xiao@noreply.com> Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
33 lines
653 B
C++
33 lines
653 B
C++
#ifndef WEBMULTIMEDIADOWNLOAD_HH
|
|
#define WEBMULTIMEDIADOWNLOAD_HH
|
|
|
|
#include "dict/dictionary.hh"
|
|
#include <QtNetwork>
|
|
|
|
namespace Dictionary {
|
|
|
|
/// Downloads data from the web, wrapped as a dictionary's DataRequest. This
|
|
/// is useful for multimedia files, like sounds and pronunciations.
|
|
class WebMultimediaDownload: public DataRequest
|
|
{
|
|
Q_OBJECT
|
|
|
|
QNetworkReply * reply;
|
|
QNetworkAccessManager & mgr;
|
|
int redirectCount;
|
|
|
|
public:
|
|
|
|
WebMultimediaDownload( QUrl const &, QNetworkAccessManager & );
|
|
|
|
virtual void cancel();
|
|
|
|
private slots:
|
|
|
|
void replyFinished( QNetworkReply * );
|
|
};
|
|
|
|
} // namespace Dictionary
|
|
|
|
#endif // WEBMULTIMEDIADOWNLOAD_HH
|