mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-01-04 14:42:29 -06:00
Use QThreadPool for torrent creation
The change is in preparation for adding the possibility to create torrent files via the API. Rework TorrentCreatorThread to be a more lightweight QRunnable class. The parameters are now defined on construction time and are fixed throughout the lifecycle of the TorrentCreator. The lifecycle of the object is not bound to the one of QDialog anymore; it is now handled by the QThreadPool. This will enable easier queueing of multiple torrent creation jobs without risk of spawning many threads. PR #19500.
This commit is contained in:
@@ -35,7 +35,7 @@ add_library(qbt_base STATIC
|
||||
bittorrent/torrent.h
|
||||
bittorrent/torrentcontenthandler.h
|
||||
bittorrent/torrentcontentlayout.h
|
||||
bittorrent/torrentcreatorthread.h
|
||||
bittorrent/torrentcreator.h
|
||||
bittorrent/torrentdescriptor.h
|
||||
bittorrent/torrentimpl.h
|
||||
bittorrent/torrentinfo.h
|
||||
@@ -132,7 +132,7 @@ add_library(qbt_base STATIC
|
||||
bittorrent/speedmonitor.cpp
|
||||
bittorrent/torrent.cpp
|
||||
bittorrent/torrentcontenthandler.cpp
|
||||
bittorrent/torrentcreatorthread.cpp
|
||||
bittorrent/torrentcreator.cpp
|
||||
bittorrent/torrentdescriptor.cpp
|
||||
bittorrent/torrentimpl.cpp
|
||||
bittorrent/torrentinfo.cpp
|
||||
|
||||
Reference in New Issue
Block a user