void HaliteDialog::OnRemove(UINT, int, HWND) { if (hal::torrent_details_ptr torrent = hal::bittorrent().torrentDetails().focused_torrent()) { hal::bittorrent().remove_torrent(torrent->uuid()); torrentsList().erase_torrent_name(torrent->uuid()); } }
void Reciever::success() { std::cout << "Operation \'" << operation(session->tag()) << "\', result: \'" << session->result().toAscii().data() << "\'\n"; switch(session->tag()) { case GetTorrentsList: std::cout << "torrents count: \'" << session->torrentsCount() << "\'\n"; std::cout << "Torrents:\n"; torrentsList(); break; /* case StopTorrents: break; case StartTorrents: break;*/ defaults: std::cout << "Unknown tag.\n"; } emit term(); };