combine the two rpc delete data methods

This commit is contained in:
Mitchell Livingston 2013-03-04 04:18:21 +00:00
parent b5be6e86b6
commit 0a5024adc9
2 changed files with 5 additions and 11 deletions

View File

@ -275,8 +275,7 @@ typedef enum
- (void) rpcCallback: (tr_rpc_callback_type) type forTorrentStruct: (struct tr_torrent *) torrentStruct;
- (void) rpcAddTorrentStruct: (struct tr_torrent *) torrentStruct;
- (void) rpcRemoveTorrent: (Torrent *) torrent;
- (void) rpcRemoveTorrentDeleteData: (Torrent *) torrent;
- (void) rpcRemoveTorrent: (Torrent *) torrent deleteData: (BOOL) deleteData;
- (void) rpcStartedStoppedTorrent: (Torrent *) torrent;
- (void) rpcChangedTorrent: (Torrent *) torrent;
- (void) rpcMovedTorrent: (Torrent *) torrent;

View File

@ -4771,11 +4771,11 @@ static void sleepCallback(void * controller, io_service_t y, natural_t messageTy
break;
case TR_RPC_TORRENT_REMOVING:
[self rpcRemoveTorrent: torrent];
[self rpcRemoveTorrent: torrent deleteData: NO];
break;
case TR_RPC_TORRENT_TRASHING:
[self rpcRemoveTorrentDeleteData: torrent];
[self rpcRemoveTorrent: torrent deleteData: YES];
break;
case TR_RPC_TORRENT_CHANGED:
@ -4832,14 +4832,9 @@ static void sleepCallback(void * controller, io_service_t y, natural_t messageTy
[self fullUpdateUI];
}
- (void) rpcRemoveTorrent: (Torrent *) torrent
- (void) rpcRemoveTorrent: (Torrent *) torrent deleteData: (BOOL) deleteData
{
[self confirmRemoveTorrents: @[ torrent ] deleteData: NO];
}
- (void) rpcRemoveTorrentDeleteData: (Torrent *) torrent
{
[self confirmRemoveTorrents: @[ torrent ] deleteData: YES];
[self confirmRemoveTorrents: @[ torrent ] deleteData: deleteData];
}
- (void) rpcStartedStoppedTorrent: (Torrent *) torrent