mirror of
https://github.com/ciphervance/supercell-wx.git
synced 2025-10-30 23:10:05 +00:00
Download manager implementation
This commit is contained in:
parent
94726631cb
commit
4ac2626b65
5 changed files with 351 additions and 2 deletions
36
scwx-qt/source/scwx/qt/manager/download_manager.hpp
Normal file
36
scwx-qt/source/scwx/qt/manager/download_manager.hpp
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
#pragma once
|
||||
|
||||
#include <scwx/qt/request/download_request.hpp>
|
||||
|
||||
#include <memory>
|
||||
#include <string>
|
||||
|
||||
#include <QObject>
|
||||
|
||||
namespace scwx
|
||||
{
|
||||
namespace qt
|
||||
{
|
||||
namespace manager
|
||||
{
|
||||
|
||||
class DownloadManager : public QObject
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit DownloadManager();
|
||||
~DownloadManager();
|
||||
|
||||
void Download(const std::shared_ptr<request::DownloadRequest>& request);
|
||||
|
||||
static std::shared_ptr<DownloadManager> Instance();
|
||||
|
||||
private:
|
||||
class Impl;
|
||||
std::unique_ptr<Impl> p;
|
||||
};
|
||||
|
||||
} // namespace manager
|
||||
} // namespace qt
|
||||
} // namespace scwx
|
||||
Loading…
Add table
Add a link
Reference in a new issue