diff options
| author | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2012-03-20 21:42:09 +0900 |
|---|---|---|
| committer | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2012-03-20 21:42:09 +0900 |
| commit | f4e2c7f0603fdb0609bf163ee5ea683a44b98d69 (patch) | |
| tree | 18227134780ec9417ecc7b24969f35725a377e04 /src/DefaultPieceStorage.cc | |
| parent | f16511012e28d1303e300e695b310d01b6200c2c (diff) | |
Added JSON-RPC over WebSocket.
Wslay library must be placed under deps/wslay.
Diffstat (limited to 'src/DefaultPieceStorage.cc')
| -rw-r--r-- | src/DefaultPieceStorage.cc | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/DefaultPieceStorage.cc b/src/DefaultPieceStorage.cc index a338b6bd..ff0cc1bb 100644 --- a/src/DefaultPieceStorage.cc +++ b/src/DefaultPieceStorage.cc @@ -63,6 +63,8 @@ #include "PieceStatMan.h" #include "wallclock.h" #include "bitfield.h" +#include "SingletonHolder.h" +#include "Notifier.h" #ifdef ENABLE_BITTORRENT # include "bittorrent_helper.h" #endif // ENABLE_BITTORRENT @@ -479,6 +481,9 @@ void DefaultPieceStorage::completePiece(const SharedHandle<Piece>& piece) if(!torrentAttrs->metadata.empty()) { util::executeHookByOptName(downloadContext_->getOwnerRequestGroup(), option_, PREF_ON_BT_DOWNLOAD_COMPLETE); + SingletonHolder<Notifier>::instance()-> + notifyDownloadEvent(Notifier::ON_BT_DOWNLOAD_COMPLETE, + downloadContext_->getOwnerRequestGroup()); } } #endif // ENABLE_BITTORRENT |
